Queues a user's nickname to be updated.

@param user The user whose nickname should be updated.
@param nickname The new nickname of the user.
@return The current instance in order to chain call methods.
496916
public ServerUpdater setNickname(User user, String nickname) {
        delegate.setNickname(user, nickname);
        return this;
    }
308408
@Programmatic
    public ApplicationUser findOrCreateUserByUsername(
            final String username) {
        // slightly unusual to cache a function that modifies state, but safe because this is idempotent
        return queryResultsCache.execute(new Callable<ApplicationUser>() {
            @Override
            public ApplicationUser call() throws Exception {
                final ApplicationUser applicationUser = findByUsername(username);
                if (applicationUser != null) {
                    return applicationUser;
                }
                return newDelegateUser(username, null, null);
            }
        }, ApplicationUserRepository.class, "findOrCreateUserByUsername", username);
    }
184119
public void updateUser(UserUpdate update) {
		getResourceFactory().getApiResource("/user/")
				.entity(update, MediaType.APPLICATION_JSON_TYPE).put();
	}
512034
@POST
  @Path("me/username")
  @RolesAllowed({"ROLE_ADMIN", "ROLE_USER"})
  public Response changeUsername(@Context HttpServletRequest request, UsernameRequest usernameRequest) {
    Long userId = (Long) request.getAttribute(OAuth2Filter.NAME_USER_ID);
    return changeUsername(userId, usernameRequest);
  }
1215119
public static BaasUser withUserName(String username) {
        BaasUser current = current();
        if (current != null && current.username.equals(username)) {
            return current;
        }
        return new BaasUser(username);
    }
898293
public static void setUser(Object user)
    {
        HttpSession session = WebContextFactory.get().getSession(true);
        session.setAttribute(USER, user);
    }
1111460
public User createUser(final User user) throws UnauthorizedException {
        User requestingUser = getCurrentUser();
        if (requestingUser != null && !requestingUser.isAdmin()) {
            throw new UnauthorizedException("Only admins can create new accounts!");
        }
        tt.execute(new TransactionCallbackWithoutResult() {
            public void doInTransactionWithoutResult(TransactionStatus status) {
                boolean success = false;
                try {
                    PasswordEncoder encoder = new ShaPasswordEncoder();
                    String hashedPass = encoder.encodePassword(user.getPassword(), null);
                    user.setId(insert(
                            "INSERT INTO Users (username, password, enabled) "
                            + "VALUES (?, ?, ?)", user.getName(),
                            hashedPass, user.isEnabled()));
                    addAuthority(user.getName(), ROLE_USER);
                    if (user.isAdmin()) {
                        addAuthority(user.getName(), ROLE_ADMIN);
                    }
                    success = true;
                } finally {
                    if (!success) {
                        status.setRollbackOnly();
                    }
                }
            }
        });
        return user;
    }
492423
def update_membership(self, nickname=None, **kwargs):
        
        return self.memberships.update(nickname=nickname, **kwargs)
183084
private void updateUser(CmsUser user) {

        setUserPasswordStatus(user, m_forceResetPassword.getValue().booleanValue());
        user.setDescription(m_description.getValue());
        user.setManaged(!m_selfmanagement.getValue().booleanValue());
        user.setEnabled(m_enabled.getValue().booleanValue());
        m_userdata.submit(user, m_cms, new Runnable() {

            public void run() {
                //
            }
        }, true);
    }
459005
public void addUser(User user){
		this.users.add(user);
		this.fireTableRowsInserted(this.users.size()-1, this.users.size()-1);
	}
867939
def add_user(
        self,
        name, 
        **attrs
        ):
        """"""
        if self.user_exists(name):
            raise KubeConfError("user with the given name already exists.")

        users = self.get_users()
        
        # Add parameters.
        new_user = {'name': name, 'user':{}}
        attrs_ = new_user['user']
        attrs_.update(attrs)
        users.append(new_user)
305440
public static base_response update(nitro_service client, aaauser resource) throws Exception {
		aaauser updateresource = new aaauser();
		updateresource.username = resource.username;
		updateresource.password = resource.password;
		return updateresource.update_resource(client);
	}
510417
public GitkitUser updateUser(GitkitUser user)
      throws GitkitClientException, GitkitServerException {
    try {
      return jsonToUser(rpcHelper.updateAccount(user));
    } catch (JSONException e) {
      throw new GitkitServerException(e);
    }
  }
708259
@POST
  @Path("me")
  @RolesAllowed({"ROLE_ADMIN", "ROLE_USER"})
  public Response updateMe(@Context HttpServletRequest request,
                           @Context UriInfo uriInfo,
                           @Context SecurityContext securityContext,
                           DUser user) {

    Long userId = (Long) request.getAttribute(OAuth2Filter.NAME_USER_ID);
    if (null == user.getId()) {
      user.setId(userId);
    } else if (!user.getId().equals(userId)) {
      throw new BadRequestRestException("User ids does not match");
    }

    return update(userId, uriInfo, securityContext, user);
  }
1293120
public ServiceFuture<UserInner> getPublishingUserAsync(final ServiceCallback<UserInner> serviceCallback) {
        return ServiceFuture.fromResponse(getPublishingUserWithServiceResponseAsync(), serviceCallback);
    }
691553
void updateUserInfo() {

        try {
            m_user = m_context.getCms().readUser(m_user.getId());
            displayResourceInfoDirectly(Collections.singletonList(CmsAccountsApp.getPrincipalInfo(m_user)));
        } catch (CmsException e) {
            LOG.error("Error updating user info.", e);
        }
    }
477818
private static ConsistencyLevel consistencyForUser(String username)
    {
        if (username.equals(DEFAULT_SUPERUSER_NAME))
            return ConsistencyLevel.QUORUM;
        else
            return ConsistencyLevel.LOCAL_ONE;
    }