当前位置: 首页>>代码示例>>Java>>正文


Java AccountType类代码示例

本文整理汇总了Java中org.isisaddons.module.security.dom.user.AccountType的典型用法代码示例。如果您正苦于以下问题:Java AccountType类的具体用法?Java AccountType怎么用?Java AccountType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


AccountType类属于org.isisaddons.module.security.dom.user包,在下文中一共展示了AccountType类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: DomainAppAdminUser

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public DomainAppAdminUser() {
    super(USER_NAME, PASSWORD, null,
            DomainAppAdminUserTenancy.TENANCY_PATH, AccountType.LOCAL,
            Arrays.asList(IsisModuleSecurityAdminRoleAndPermissions.ROLE_NAME,
                          TogglzModuleAdminRole.ROLE_NAME,
                          AuditModuleRoleAndPermissions.ROLE_NAME,
                          CommandModuleRoleAndPermissions.ROLE_NAME,
                          SessionLoggerModuleRoleAndPermissions.ROLE_NAME,
                          SettingsModuleRoleAndPermissions.ROLE_NAME,
                          PublishingModuleRoleAndPermissions.ROLE_NAME,
                          DevUtilsModuleRoleAndPermissions.ROLE_NAME,
                          DomainAppRegularRoleAndPermissions.ROLE_NAME,
                          DomainAppFixtureServiceRoleAndPermissions.ROLE_NAME,
                          TranslationServicePoMenuRoleAndPermissions.ROLE_NAME
                    ));
}
 
开发者ID:isisaddons-legacy,项目名称:isis-app-quickstart,代码行数:17,代码来源:DomainAppAdminUser.java

示例2: ToDoAppAdminUser

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public ToDoAppAdminUser() {
    super(USER_NAME, PASSWORD, null,
            ToDoAppAdminUserTenancy.TENANCY_PATH, AccountType.LOCAL,
            Arrays.asList(IsisModuleSecurityAdminRoleAndPermissions.ROLE_NAME,

                          AuditModuleRoleAndPermissions.ROLE_NAME,
                          CommandModuleRoleAndPermissions.ROLE_NAME,
                          PublishingModuleRoleAndPermissions.ROLE_NAME,
                          SessionLoggerModuleRoleAndPermissions.ROLE_NAME,
                          SettingsModuleRoleAndPermissions.ROLE_NAME,
                          TogglzModuleAdminRole.ROLE_NAME,

                          ToDoAppRegularRoleAndPermissions.ROLE_NAME,
                          ToDoAppFixtureServiceRoleAndPermissions.ROLE_NAME,

                          ApacheIsisTranslationServicePoMenuRoleAndPermissions.ROLE_NAME,
                          ApacheIsisApplibDtoRoleAndPermissions.ROLE_NAME,
                          ApacheIsisMetadataMenuRoleAndPermissions.ROLE_NAME,
                          ApacheIsisPersistableMixinsRoleAndPermissions.ROLE_NAME,
                          ApacheIsisApplibMixinsRoleAndPermissions.ROLE_NAME,

                          ApacheIsisViewerWicketMixinsRoleAndPermissions.ROLE_NAME
                    ));
}
 
开发者ID:isisaddons,项目名称:isis-app-todoapp,代码行数:25,代码来源:ToDoAppAdminUser.java

示例3: create

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
protected ApplicationUser create(
    final String name,
    final String emailAddress,
    final AccountType accountType,
    final String tenancyPath,
    final ExecutionContext executionContext) {

    final ApplicationUser applicationUser;
    if(accountType == AccountType.DELEGATED) {
        applicationUser = applicationUserRepository.newDelegateUser(name, null, null);
    } else {
        final String passwordStr = Util.coalesce(executionContext.getParameter("password"), getPassword(), "12345678a");
        final Password password = new Password(passwordStr);
        applicationUser = applicationUserRepository.newLocalUser(name, password, password, null, null, emailAddress);
    }

    applicationUser.setAtPath(tenancyPath);

    executionContext.addResult(this, name, applicationUser);
    return applicationUser;
}
 
开发者ID:isisaddons-legacy,项目名称:isis-module-security,代码行数:22,代码来源:AbstractUserFixtureScript.java

示例4: MaryHostessFixtureScript

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public MaryHostessFixtureScript() {
    super(
            USER_NAME,
            PASSWORD,
            EMAIL_ADDRESS,
            AT_PATH,
            AccountType.LOCAL,
            Arrays.asList(HostessRoleAndPermissions.ROLE_NAME));
}
 
开发者ID:incodehq,项目名称:ecpcrm,代码行数:10,代码来源:MaryHostessFixtureScript.java

示例5: EcpCrmAdminUser

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public EcpCrmAdminUser() {
    super(USER_NAME, PASSWORD, null,
            TENANCY_PATH, AccountType.LOCAL,
            Arrays.asList(IsisModuleSecurityAdminRoleAndPermissions.ROLE_NAME,
                          AuditModuleRoleAndPermissions.ROLE_NAME,
                          CommandModuleRoleAndPermissions.ROLE_NAME,
                          SessionLoggerModuleRoleAndPermissions.ROLE_NAME,
                          SettingsModuleRoleAndPermissions.ROLE_NAME,
                          PublishingModuleRoleAndPermissions.ROLE_NAME,
                          DevUtilsModuleRoleAndPermissions.ROLE_NAME,
                          EcpCrmRegularRoleAndPermissions.ROLE_NAME,
                          EcpCrmFixtureServiceRoleAndPermissions.ROLE_NAME,
                          TranslationServicePoMenuRoleAndPermissions.ROLE_NAME
                    ));
}
 
开发者ID:incodehq,项目名称:ecpcrm,代码行数:16,代码来源:EcpCrmAdminUser.java

示例6: execute

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
@Override
    protected void execute(FixtureScript.ExecutionContext ec) {

        // required
        final String username = todoapp.fixture.util.Util.coalesce(ec.getParameter("username"), getUsername());
        if (username == null) {
            throw new IllegalArgumentException("username is required");
        }

        // optional
        final String emailAddress = todoapp.fixture.util.Util.coalesce(ec.getParameter("emailAddress"), getEmailAddress());
        final AccountType accountType = todoapp.fixture.util.Util.coalesce(ec.getParameterAsEnum("accountType", AccountType.class), getAccountType(), AccountType.LOCAL);
//        final String tenancyPath = todoapp.fixture.util.Util.coalesce(ec.getParameter("atPath"), getAtPath(), GlobalTenancy.TENANCY_PATH + username);
        final String password = todoapp.fixture.util.Util.coalesce(ec.getParameter("password"), getPassword(), "pass");
        final ApplicationRole initialRole = todoapp.fixture.util.Util.coalesce(findRoleByName(ec.getParameter("initialRole")), getInitialRole(), findRoleByName(getInitialRoleName()));
        boolean enabled = todoapp.fixture.util.Util.coalesce(ec.getParameterAsBoolean("enabled"), getEnabled(), Boolean.TRUE);

        //
        // execute
        //
        final ApplicationUser applicationUser;
        if (accountType == AccountType.DELEGATED) {
            applicationUser = wrap(applicationUserMenu).newDelegateUser(username, initialRole, enabled);
        } else {
            final Password passwordValue = new Password(password);
            applicationUser = wrap(applicationUserMenu).newLocalUser(username, passwordValue, passwordValue, initialRole, enabled, emailAddress);
        }

        // no longer required, performed automatically by subscriber...
//        final ApplicationTenancy applicationTenancy = applicationTenancyRepository.findTenancyByPath(tenancyPath);
//        if (applicationTenancy == null) {
//            final ApplicationTenancy rootTenancy = applicationTenancyRepository.findTenancyByPath(GlobalTenancy.TENANCY_PATH);
//            applicationTenancyRepository.newTenancy(username, tenancyPath, rootTenancy);
//        }
//        applicationUser.setTenancy(applicationTenancy);

        ec.addResult(this, username, applicationUser);

        setApplicationUser(applicationUser);
    }
 
开发者ID:isisaddons,项目名称:isis-app-todoapp,代码行数:41,代码来源:CreateUserFixtureScript.java

示例7: execute

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
@Override
protected void execute(ExecutionContext executionContext) {
    final ApplicationUser applicationUser = create(USER_NAME, AccountType.LOCAL, ItalyTenancy.TENANCY_PATH, executionContext);
    applicationUser.updateName("Tenant", "Bertrand", "Bert");
    applicationUser.updatePassword("pass");
    applicationUser.unlock();
}
 
开发者ID:isisaddons-legacy,项目名称:isis-module-security,代码行数:8,代码来源:BertTenantedUser.java

示例8: execute

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
@Override
protected void execute(ExecutionContext executionContext) {
    final ApplicationUser applicationUser = create(USER_NAME, AccountType.LOCAL, null, executionContext);
    applicationUser.updateName("Non-tenant", "William", "Bill");
    applicationUser.updatePassword("pass");
    applicationUser.unlock();
}
 
开发者ID:isisaddons-legacy,项目名称:isis-module-security,代码行数:8,代码来源:BillNonTenantedUser.java

示例9: AbstractUserAndRolesFixtureScript

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public AbstractUserAndRolesFixtureScript(
        final String username,
        final String password,
        final AccountType accountType, 
        final List<String> roleNames) {
    this(username, password, null, null, accountType, roleNames);
}
 
开发者ID:isisaddons-legacy,项目名称:isis-module-security,代码行数:8,代码来源:AbstractUserAndRolesFixtureScript.java

示例10: from

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public static PrincipalForApplicationUser from(ApplicationUser applicationUser) {
    if(applicationUser == null) {
        return null;
    }
    final String username = applicationUser.getName();
    final String encryptedPassword = applicationUser.getEncryptedPassword();
    final AccountType accountType = applicationUser.getAccountType();
    final Set<String> roles = Sets.newTreeSet(Lists.newArrayList(Iterables.transform(applicationUser.getRoles(), ApplicationRole.Functions.GET_NAME)));
    final ApplicationPermissionValueSet permissionSet = applicationUser.getPermissionSet();
    return new PrincipalForApplicationUser(username, encryptedPassword, accountType, applicationUser.getStatus(), roles, permissionSet);
}
 
开发者ID:isisaddons-legacy,项目名称:isis-module-security,代码行数:12,代码来源:PrincipalForApplicationUser.java

示例11: PrincipalForApplicationUser

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
PrincipalForApplicationUser(
        final String username,
        final String encryptedPassword,
        final AccountType accountType,
        final ApplicationUserStatus status,
        final Set<String> roles,
        final ApplicationPermissionValueSet applicationPermissionValueSet) {
    this.username = username;
    this.encryptedPassword = encryptedPassword;
    this.accountType = accountType;
    this.roles = roles;
    this.status = status;
    this.permissionSet = applicationPermissionValueSet;
}
 
开发者ID:isisaddons-legacy,项目名称:isis-module-security,代码行数:15,代码来源:PrincipalForApplicationUser.java

示例12: EstatioUserInFrance

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public EstatioUserInFrance() {
    super(
            USER_NAME,
            PASSWORD,
            EMAIL_ADDRESS,
            AT_PATH,
            AccountType.LOCAL,
            Arrays.asList(EstatioUserRoleAndPermissions.ROLE_NAME));
}
 
开发者ID:estatio,项目名称:estatio,代码行数:10,代码来源:EstatioUserInFrance.java

示例13: EstatioUserInSweden

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public EstatioUserInSweden() {
    super(
            USER_NAME,
            PASSWORD,
            EMAIL_ADDRESS,
            AT_PATH,
            AccountType.LOCAL,
            Arrays.asList(EstatioUserRoleAndPermissions.ROLE_NAME));
}
 
开发者ID:estatio,项目名称:estatio,代码行数:10,代码来源:EstatioUserInSweden.java

示例14: EstatioUserInItaly

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public EstatioUserInItaly() {
    super(
            USER_NAME,
            PASSWORD,
            EMAIL_ADDRESS,
            AT_PATH,
            AccountType.LOCAL,
            Arrays.asList(EstatioUserRoleAndPermissions.ROLE_NAME));
}
 
开发者ID:estatio,项目名称:estatio,代码行数:10,代码来源:EstatioUserInItaly.java

示例15: EstatioUser

import org.isisaddons.module.security.dom.user.AccountType; //导入依赖的package包/类
public EstatioUser() {
    super(
            USER_NAME,
            PASSWORD,
            EMAIL_ADDRESS,
            AT_PATH,
            AccountType.LOCAL,
            Arrays.asList(EstatioUserRoleAndPermissions.ROLE_NAME));
}
 
开发者ID:estatio,项目名称:estatio,代码行数:10,代码来源:EstatioUser.java


注:本文中的org.isisaddons.module.security.dom.user.AccountType类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。