Package org.exoplatform.services.organization

Examples of org.exoplatform.services.organization.UserProfile


   }

   public UserProfile removeUserProfile(String userName, boolean broadcast) throws Exception
   {
      UserProfile profile = getProfile(userName);

      if (profile != null)
      {
         try
         {
View Full Code Here


      if (foundUser == null)
      {
         return null;
      }

      UserProfile up = getProfile(userName);

      //
      if (up == null)
      {
         up = NOT_FOUND;
View Full Code Here

      if (filteredAttrs.isEmpty())
      {
         return null;
      }

      UserProfile profile = new UserProfileImpl(userName, filteredAttrs);

      return profile;

   }
View Full Code Here

   @SuppressWarnings("unused")
   public void onStartRequest(final Application app, final WebuiRequestContext context) throws Exception
   {
     String user = context.getRemoteUser();
     UserProfile userProfile = null;
     if (user != null)
     {
       ExoContainer exoContainer = app.getApplicationServiceContainer();
       if (exoContainer != null)
       {
View Full Code Here

        }

    }

    public UserProfile removeUserProfile(String userName, boolean broadcast) throws Exception {
        UserProfile profile = getProfile(userName);

        if (profile != null) {
            try {
                if (broadcast) {
                    preDelete(profile);
View Full Code Here

        if (foundUser == null) {
            return null;
        }

        UserProfile up = getProfile(userName);

        //
        if (up == null) {
            up = NOT_FOUND;
        }
View Full Code Here

        if (filteredAttrs.isEmpty()) {
            return null;
        }

        UserProfile profile = new UserProfileImpl(userName, filteredAttrs);

        return profile;

    }
View Full Code Here

        if (preferencesPortletContext == null) {
            return null;
        }

        // get the user profile cached in the prc during the start of the request
        UserProfile userProfile = (UserProfile) prc.getAttribute(UserProfileLifecycle.USER_PROFILE_ATTRIBUTE_NAME);

        // client context
        AbstractClientContext clientContext;
        Cookie[] cookies = servletRequest.getCookies();
        if (cookies != null) {
View Full Code Here

    public void setUserProfile(String user) throws Exception {
        user_ = user;
        if (user == null)
            return;
        OrganizationService service = getApplicationComponent(OrganizationService.class);
        UserProfile userProfile = service.getUserProfileHandler().findUserProfileByName(user);
        if (userProfile == null) {
            userProfile = service.getUserProfileHandler().createUserProfileInstance();
            userProfile.setUserName(user);
        }

        if (userProfile.getUserInfoMap() == null)
            return;
        for (UIComponent set : getChildren()) {
            UIFormInputSet inputSet = (UIFormInputSet) set;
            for (UIComponent uiComp : inputSet.getChildren()) {
                UIFormStringInput uiInput = (UIFormStringInput) uiComp;
                uiInput.setValue(userProfile.getAttribute(uiInput.getName()));
            }
        }
    }
View Full Code Here

    @SuppressWarnings("deprecation")
    public boolean save(OrganizationService service, String user, boolean isnewUser) throws Exception {
        user_ = user;
        UserProfileHandler hanlder = service.getUserProfileHandler();
        UserProfile userProfile = hanlder.findUserProfileByName(user_);

        if (userProfile == null) {
            userProfile = hanlder.createUserProfileInstance();
            userProfile.setUserName(user_);
        }

        for (UIComponent set : getChildren()) {
            UIFormInputSet inputSet = (UIFormInputSet) set;
            for (UIComponent uiComp : inputSet.getChildren()) {
                UIFormStringInput uiInput = (UIFormStringInput) uiComp;
                // if(uiInput.getValue() == null || uiInput.getValue().length() < 1)
                // continue;
                userProfile.getUserInfoMap().put(uiInput.getName(), uiInput.getValue());
            }
        }

        WebuiRequestContext context = WebuiRequestContext.getCurrentInstance();
        UIApplication uiApp = context.getUIApplication();
View Full Code Here

TOP

Related Classes of org.exoplatform.services.organization.UserProfile

Copyright © 2018 www.massapicom. 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.