Class ResourceType
- java.lang.Object
-
- com.fasterxml.jackson.databind.JsonSerializable.Base
-
- com.fasterxml.jackson.databind.JsonNode
-
- com.fasterxml.jackson.databind.node.BaseJsonNode
-
- com.fasterxml.jackson.databind.node.ContainerNode<com.fasterxml.jackson.databind.node.ObjectNode>
-
- com.fasterxml.jackson.databind.node.ObjectNode
-
- de.captaingoldfish.scim.sdk.common.resources.base.ScimObjectNode
-
- de.captaingoldfish.scim.sdk.common.resources.AbstractSchemasHolder
-
- de.captaingoldfish.scim.sdk.common.resources.ResourceNode
-
- de.captaingoldfish.scim.sdk.server.schemas.ResourceType
-
- All Implemented Interfaces:
com.fasterxml.jackson.core.TreeNode,com.fasterxml.jackson.databind.JsonSerializable,com.fasterxml.jackson.databind.node.JsonNodeCreator,ScimNode,Serializable,Iterable<com.fasterxml.jackson.databind.JsonNode>
public class ResourceType extends ResourceNode
author Pascal Knueppel
created at: 03.10.2019 - 19:36
represents a resource type in SCIM. A resource type defines an endpoint definition that can be used by clients.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classResourceType.ResourceSchemarepresents the schema descriptions of this resource typeclassResourceType.SchemaExtensiona schema extension representation
-
Constructor Summary
Constructors Modifier Constructor Description protectedResourceType(SchemaFactory schemaFactory, com.fasterxml.jackson.databind.JsonNode resourceTypeDocument)protectedResourceType(SchemaFactory schemaFactory, String resourceDocument)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<Schema>getAllSchemas()this method will extract allSchemadefinitions that belong to this resource type.Optional<String>getDescription()The resource type's human-readable description.StringgetEndpoint()The resource type's HTTP-addressable endpoint relative to the Base URL of the service provider, e.g., "Users".ResourceTypeFeaturesgetFeatures()SchemagetMainSchema()StringgetName()The resource type name.List<Schema>getNotRequiredResourceSchemaExtensions()List<Schema>getRequiredResourceSchemaExtensions()ResourceType.ResourceSchemagetResourceSchema(com.fasterxml.jackson.databind.JsonNode resourceDocument)will find the meta resource schema and its extensions of this resource type that apply to the given documentStringgetSchema()The resource type's primary/base schema URI, e.g., "urn:ietf:params:scim:schemas:core:2.0:User".List<ResourceType.SchemaExtension>getSchemaExtensions()A list of URIs of the resource type's schema extensions.booleanisDisabled()voidsetDisabled(Boolean disabled)disables or enables this resourcetypevoidsetFeatures(ResourceTypeFeatures filterExtension)voidsetId(String id)-
Methods inherited from class de.captaingoldfish.scim.sdk.common.resources.ResourceNode
getExternalId, getId, getMeta, getSortingAttribute, setExternalId, setMeta
-
Methods inherited from class de.captaingoldfish.scim.sdk.common.resources.AbstractSchemasHolder
addSchema, getSchemas, removeSchema, setSchemas, setSchemas
-
Methods inherited from class de.captaingoldfish.scim.sdk.common.resources.base.ScimObjectNode
addAttribute, getArrayAttribute, getBooleanAttribute, getDateTimeAttribute, getDoubleAttribute, getIntegerAttribute, getLongAttribute, getObjectAttribute, getSchemaAttribute, getSimpleArrayAttribute, getSimpleArrayAttribute, getSimpleArrayAttributeSet, getSimpleArrayAttributeSet, getStringAttribute, getStringAttribute, isEmpty, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttributeList, setDateTimeAttribute, setDateTimeAttribute, setDateTimeAttribute, setDateTimeAttribute, setStringAttributeList, setStringAttributeList, toPrettyString, toString
-
Methods inherited from class com.fasterxml.jackson.databind.node.ObjectNode
_at, _childrenEqual, _put, asToken, deepCopy, elements, equals, equals, fieldNames, fields, findParent, findParents, findValue, findValues, findValuesAsText, get, get, getNodeType, hashCode, isEmpty, isObject, path, path, put, put, put, put, put, put, put, put, put, put, put, put, put, put, put, put, put, putAll, putAll, putArray, putNull, putObject, putPOJO, putRawValue, remove, remove, removeAll, replace, required, retain, retain, serialize, serializeWithType, set, setAll, setAll, size, with, withArray, without, without
-
Methods inherited from class com.fasterxml.jackson.databind.node.ContainerNode
arrayNode, arrayNode, asText, binaryNode, binaryNode, booleanNode, missingNode, nullNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, numberNode, objectNode, pojoNode, rawValueNode, textNode
-
Methods inherited from class com.fasterxml.jackson.databind.node.BaseJsonNode
findPath, numberType, required, traverse, traverse
-
Methods inherited from class com.fasterxml.jackson.databind.JsonNode
_reportRequiredViolation, _this, asBoolean, asBoolean, asDouble, asDouble, asInt, asInt, asLong, asLong, asText, at, at, bigIntegerValue, binaryValue, booleanValue, canConvertToInt, canConvertToLong, decimalValue, doubleValue, findParents, findValues, findValuesAsText, floatValue, has, has, hasNonNull, hasNonNull, intValue, isArray, isBigDecimal, isBigInteger, isBinary, isBoolean, isContainerNode, isDouble, isFloat, isFloatingPointNumber, isInt, isIntegralNumber, isLong, isMissingNode, isNull, isNumber, isPojo, isShort, isTextual, isValueNode, iterator, longValue, numberValue, require, requiredAt, requiredAt, requireNonNull, shortValue, textValue
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Methods inherited from interface de.captaingoldfish.scim.sdk.common.resources.base.ScimNode
getAttributeDescription, getAttributeName, getCanonicalValues, getMutability, getReferenceTypes, getReturned, getScimNodeName, getUniqueness, getValueType, isCaseExact, isMultiValued, isRequired
-
-
-
-
Constructor Detail
-
ResourceType
protected ResourceType(SchemaFactory schemaFactory, String resourceDocument)
-
ResourceType
protected ResourceType(SchemaFactory schemaFactory, com.fasterxml.jackson.databind.JsonNode resourceTypeDocument)
-
-
Method Detail
-
getMainSchema
public Schema getMainSchema()
- Returns:
- the main schema that represents this resource type
-
getRequiredResourceSchemaExtensions
public List<Schema> getRequiredResourceSchemaExtensions()
- Returns:
- the required resource schema extensions that represents this resource type
-
getNotRequiredResourceSchemaExtensions
public List<Schema> getNotRequiredResourceSchemaExtensions()
- Returns:
- the not required resource schema extensions that represents this resource type
-
getAllSchemas
public List<Schema> getAllSchemas()
this method will extract allSchemadefinitions that belong to this resource type. The first entry in the list will always be the mainSchemareferenced in the attributegetSchema(). All otherSchemas in the list will be the extensions of this resource- Returns:
- a list of all
Schemadefinitions that describe this resource type
-
getResourceSchema
public ResourceType.ResourceSchema getResourceSchema(com.fasterxml.jackson.databind.JsonNode resourceDocument)
will find the meta resource schema and its extensions of this resource type that apply to the given document- Parameters:
resourceDocument- a document that should be validated against its schemas- Returns:
- a holder object that contains the meta schemata that can be used to validate the given document
-
setId
public void setId(String id)
- Overrides:
setIdin classResourceNode
-
getEndpoint
public String getEndpoint()
The resource type's HTTP-addressable endpoint relative to the Base URL of the service provider, e.g., "Users". REQUIRED.
-
getName
public String getName()
The resource type name. When applicable, service providers MUST specify the name, e.g., "User" or "Group". This name is referenced by the "meta.resourceType" attribute in all resources. REQUIRED.
-
getDescription
public Optional<String> getDescription()
The resource type's human-readable description. When applicable, service providers MUST specify the description. OPTIONAL.
-
getSchema
public String getSchema()
The resource type's primary/base schema URI, e.g., "urn:ietf:params:scim:schemas:core:2.0:User". This MUST be equal to the "id" attribute of the associated "Schema" resource. REQUIRED.
-
getSchemaExtensions
public List<ResourceType.SchemaExtension> getSchemaExtensions()
A list of URIs of the resource type's schema extensions. OPTIONAL
-
getFeatures
public ResourceTypeFeatures getFeatures()
- See Also:
ResourceTypeFeatures
-
setFeatures
public void setFeatures(ResourceTypeFeatures filterExtension)
- See Also:
ResourceTypeFeatures
-
isDisabled
public boolean isDisabled()
- Returns:
- true if this resource type was disabled, false else
-
setDisabled
public void setDisabled(Boolean disabled)
disables or enables this resourcetype
-
-