Package com.vonage.client.users
Class User
java.lang.Object
com.vonage.client.JsonableBaseObject
com.vonage.client.users.BaseUser
com.vonage.client.users.User
- All Implemented Interfaces:
Jsonable
Represents a Vonage User (both request and response).
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic User.Builderbuilder()Entry point for creating an instance of this class.static UserConstructs a user from the JSON payload.The communication channels available to the user.Custom key/value pairs to associate with the user.A string to be displayed as username.An image URL to associate with the user.Methods inherited from class com.vonage.client.JsonableBaseObject
createJsonObjectMapper, equals, hashCode, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.vonage.client.Jsonable
toJson, updateFromJson
-
Constructor Details
-
User
protected User() -
User
-
-
Method Details
-
getDisplayName
A string to be displayed as username. It does not need to be unique.- Returns:
- The user's friendly name.
-
getImageUrl
An image URL to associate with the user.- Returns:
- The image URL, or
nullif not specified.
-
getCustomData
Custom key/value pairs to associate with the user.- Returns:
- The custom data as a Map, or
nullif not specified.
-
getChannels
The communication channels available to the user.- Returns:
- The channels object, or
nullif unknown.
-
fromJson
Constructs a user from the JSON payload.- Parameters:
json- The JSON structure containing the fields of this class.- Returns:
- A new User instance.
-
builder
Entry point for creating an instance of this class.- Returns:
- A new Builder.
-