Package io.revealbi.core
Class RVUserContext
java.lang.Object
io.revealbi.core.RVUserContext
- All Implemented Interfaces:
IRequestContext,IRVUserContext
Default implementation of the IRVUserContext interface.
-
Constructor Summary
ConstructorsConstructorDescriptionRVUserContext(String userId) Creates a newRVUserContextwith the given user ID and no additional properties.RVUserContext(String userId, Map<String, Object> properties) Creates a newRVUserContextwith the given user ID and a map of additional properties. -
Method Summary
Modifier and TypeMethodDescriptionReturns the map of additional properties associated with this user context.getProperty(String name) Returns the value for the given property ornullif no property with that name is found.Returns the userId for this context.
-
Constructor Details
-
RVUserContext
Creates a newRVUserContextwith the given user ID and no additional properties.- Parameters:
userId- A string that uniquely identifies the user.
-
RVUserContext
Creates a newRVUserContextwith the given user ID and a map of additional properties.- Parameters:
userId- A string that uniquely identifies the user.properties- An optional map of additional properties associated with the user.
-
-
Method Details
-
getUserId
Returns the userId for this context.- Specified by:
getUserIdin interfaceIRequestContext- Returns:
- Returns the userId for this context.
-
getProperty
Returns the value for the given property ornullif no property with that name is found.- Parameters:
name- Name of the property to return the value for.- Returns:
- Property for the given key name.
-
getProperties
Returns the map of additional properties associated with this user context.- Specified by:
getPropertiesin interfaceIRequestContext- Returns:
- Returns the map of additional properties associated with this user context.
-