Package org.gluu.oxtrust.model.scim2
Class BaseScimResource
java.lang.Object
org.gluu.oxtrust.model.scim2.BaseScimResource
- Direct Known Subclasses:
Fido2DeviceResource
,FidoDeviceResource
,GroupResource
,ResourceType
,SchemaResource
,ServiceProviderConfig
,UserResource
This class represents the root hierarchy of SCIM resources. All of them: user, group, etc. are subclasses of this class.
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs a basic SCIM resource with all its attributes unassigned -
Method Summary
Modifier and TypeMethodDescriptionvoid
addCustomAttributes
(String uri, Map<String, Object> map) Replaces the custom attributes belonging to the resource extension identified by theuri
passed as parameter with the attribute/value pairs supplied in theMap
.void
addCustomAttributes
(CustomAttributes customAttributes) Adds the custom attributes contained in theCustomAttributes
instance passed to this method.Retrieves all custom attributes found in this resource object.Retrieves the custom attributes found in this resource object associated to theuri
supplied.getId()
getMeta()
void
setExternalId
(String externalId) void
void
void
setSchemas
(Set<String> schemas)
-
Constructor Details
-
BaseScimResource
public BaseScimResource()Constructs a basic SCIM resource with all its attributes unassigned
-
-
Method Details
-
addCustomAttributes
Replaces the custom attributes belonging to the resource extension identified by theuri
passed as parameter with the attribute/value pairs supplied in theMap
. Developers are highly encouraged not to use this method butaddCustomAttributes(CustomAttributes)
instead which adds type-safety.Note that this method does not apply any sort of validation. Whether the
uri
and attributes are recognized or the values are consistent with data types registered in Gluu Server, is something that is performed only when the resource is passed in a service method invocation.- Parameters:
uri
- A string with URI that identifies an extensionmap
- A Map holding attribute names (Strings) and values (Objects).
-
addCustomAttributes
Adds the custom attributes contained in theCustomAttributes
instance passed to this method. All previously added attributes are replaced if they are linked to the sameuri
thatcustomAttributes
parameter is associated to.Note that this method does not apply any sort of validation. Whether the
uri
and attributes are recognized or the values are consistent with data types registered in Gluu Server, is something that is performed only when the resource is passed in a service method invocation.- Parameters:
customAttributes
- An object that comprised of attribute/value pairs
-
getCustomAttributes
Retrieves all custom attributes found in this resource object. The attributes are structured hierarchically in aMap
where they can be looked up using theuri
to which the attributes belong to.Developers are highly encouraged not to use this method but
getCustomAttributes(String)
instead which adds type-safety.- Returns:
- A Map with all custom attributes
-
getCustomAttributes
Retrieves the custom attributes found in this resource object associated to theuri
supplied.- Parameters:
uri
- A String value representing a URI- Returns:
- A
CustomAttributes
instance that allows developers to inspect attributes and values in a type-safe manner.
-
getId
-
setId
-
getExternalId
-
setExternalId
-
getMeta
-
setMeta
-
getSchemas
-
setSchemas
-