Examples of NuxeoPrincipalImpl


Examples of org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl

            if (users.size() > 0) {
                userInfo.setLogin(users.get(0).getId());
                NuxeoPrincipal nxp = userManager.getPrincipal(users.get(0).getId());
                return sw.shouldRequestSubscription(nxp);
            } else {
                return StringUtils.isBlank(sw.getSubscriptionRequestStatus(new NuxeoPrincipalImpl(
                        userInfo.getLogin())));
            }
        } catch (ClientException e) {
            log.debug(e, e);
        }
View Full Code Here

Examples of org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl

        return memberCreated;
    }

    private void updatePrincipalGroups(Principal principal) {
        if (principal instanceof NuxeoPrincipalImpl) {
            NuxeoPrincipalImpl nuxeoPrincipal = (NuxeoPrincipalImpl) principal;
            ComputedGroupsService computedGroupsService = Framework.getLocalService(ComputedGroupsService.class);
            computedGroupsService.updateGroupsForUser(nuxeoPrincipal);
        }
    }
View Full Code Here

Examples of org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl

        socialWorkspaceDoc = socialWorkspace.getDocument();

        String membersGroup = socialWorkspace.getMembersGroupName();
        String administratorsGroup = socialWorkspace.getAdministratorsGroupName();

        notMember = new NuxeoPrincipalImpl("notMember");
        member = createUserWithGroup("member", membersGroup);
        assertTrue(member.getAllGroups().contains(membersGroup));
        administrator = createUserWithGroup("administratorOfSW",
                administratorsGroup);
    }
View Full Code Here

Examples of org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl

        return createSocialWorkspace(socialWorkspaceName, false);
    }

    protected static NuxeoPrincipal createUserWithGroup(String username,
            String... groups) throws ClientException {
        NuxeoPrincipalImpl user = new NuxeoPrincipalImpl(username);
        user.allGroups = Arrays.asList(groups);
        return user;
    }
View Full Code Here

Examples of org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl

    @Before
    public void setup() throws Exception {
        socialWorkspace = createSocialWorkspace("SocialWorkspace");
        socialWorkspaceDoc = socialWorkspace.getDocument();

        nobody = new NuxeoPrincipalImpl("nobody");
        applicationMember = createUserWithGroup("applicationMember",
                userManager.getDefaultGroup());
        swMember = createUserWithGroup("swMember",
                socialWorkspace.getMembersGroupName());
        swAdministrator = createUserWithGroup("swAdministrator",
View Full Code Here

Examples of org.nuxeo.ecm.platform.usermanager.NuxeoPrincipalImpl

    @Before
    public void setup() throws Exception {
        socialWorkspace = createSocialWorkspace("SocialWorkspace");
        socialWorkspaceDoc = socialWorkspace.getDocument();

        nobody = new NuxeoPrincipalImpl("nobody");
        applicationMember = createUserWithGroup("applicationMember",
                userManager.getDefaultGroup());
        swMember = createUserWithGroup("swMember",
                socialWorkspace.getMembersGroupName());
        swAdministrator = createUserWithGroup("swAdministrator",
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.