Examples of UserResponse


Examples of org.graylog2.restclient.models.api.responses.system.UserResponse

        if (username.equals(currentUser.getName())) {
            return currentUser;
        }
        // a different user was requested, go and fetch it from the server
        try {
            final UserResponse response = api.path(resource.get(username), UserResponse.class).execute();
            // TODO this user is not cached locally for now. we should be tracking REST requests.
            // TODO we cache the user for this request, but only for checking permissions. this needs to be cleaned up after 0.20.0
            final User user = userFactory.fromResponse(response, null);
            Http.Context.current().args.put("perRequestUsersCache:" + user.getName(), user);
            return user;
View Full Code Here

Examples of org.graylog2.restclient.models.api.responses.system.UserResponse

        return null;
    }

    public User retrieveUserWithSessionId(String userName, String sessionId) {
        try {
            UserResponse response = api.path(resource.get(userName), UserResponse.class)
                    .session(sessionId)
                    .execute();

            User currentUser = userFactory.fromResponse(response, sessionId);
            currentUser.setSubject(new Subject.Builder()
View Full Code Here

Examples of pl.smsapi.api.response.UserResponse

  //@Ignore
  public void userAddTest() throws ClientException {

    UserFactory smsApi = new UserFactory(client());

    UserResponse item;
    BaseAction action = smsApi.actionAdd()
        .setUsername(userTest)
        .setPassword(Client.MD5Digest("100costma100"))
        .setPasswordApi(Client.MD5Digest("200costam200"))
        .setActive(true)
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.