Class DataContractSchemaProperty
java.lang.Object
org.odpi.openmetadata.frameworks.integration.bitol.odcs.DataContractSchemaElement
org.odpi.openmetadata.frameworks.integration.bitol.odcs.DataContractSchemaProperty
This class represents a property (typically a column or field) of a schema object in an Open Data Contract
Standard (ODCS) data contract. Properties may be nested: a property with logicalType object has its own list
of properties, and a property with logicalType array describes its element type in the items property. This
class is used for both schema properties and array item properties since the standard gives them the same
shape.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanCompare the values of the supplied object with those stored in the current object.Return the data classification of the property, for example public, restricted or confidential.Return whether the property is a critical data element.Return the name of the property that holds the encrypted version of this property's values.Return the enumeration of allowed values for this property (the enum array in the document).Return the list of example values.getItems()Return the description of the items (when the logical type is array).Return the logical (platform independent) type of the property.Return the options that refine the logical type.getMap()Return the key and value definitions when the logical type is map.Return whether the property is a partition key.Return the position of the property in the partition key (starting from 1; -1 if not a partition key).Return whether the property is part of the primary key.Return the position of the property in the primary key (starting from 1; -1 if not part of the key).Return the nested properties (when the logical type is object).Return the list of data quality checks for this property.Return the list of relationships from this property to other properties.Return whether a value is required for the property (not nullable).Return the semantic role of the property: column (the default), measure or dimension.Return the description in business terms of the transformation that produces the property.Return the logic (for example SQL) of the transformation that produces the property.Return the list of source objects used in the transformation that produces the property.Return whether the values of the property are unique.inthashCode()Return hash code based on properties.voidsetClassification(String classification) Set up the data classification of the property, for example public, restricted or confidential.voidsetCriticalDataElement(Boolean criticalDataElement) Set up whether the property is a critical data element.voidsetEncryptedName(String encryptedName) Set up the name of the property that holds the encrypted version of this property's values.voidsetEnumValues(List<DataContractEnumValue> enumValues) Set up the enumeration of allowed values for this property (the enum array in the document).voidsetExamples(List<Object> examples) Set up the list of example values.voidSet up the description of the items (when the logical type is array).voidsetLogicalType(String logicalType) Set up the logical (platform independent) type of the property.voidsetLogicalTypeOptions(DataContractLogicalTypeOptions logicalTypeOptions) Set up the options that refine the logical type.voidSet up the key and value definitions when the logical type is map.voidsetPartitioned(Boolean partitioned) Set up whether the property is a partition key.voidsetPartitionKeyPosition(Integer partitionKeyPosition) Set up the position of the property in the partition key (starting from 1; -1 if not a partition key).voidsetPrimaryKey(Boolean primaryKey) Set up whether the property is part of the primary key.voidsetPrimaryKeyPosition(Integer primaryKeyPosition) Set up the position of the property in the primary key (starting from 1; -1 if not part of the key).voidsetProperties(List<DataContractSchemaProperty> properties) Set up the nested properties (when the logical type is object).voidsetQuality(List<DataContractQualityRule> quality) Set up the list of data quality checks for this property.voidsetRelationships(List<DataContractRelationship> relationships) Set up the list of relationships from this property to other properties.voidsetRequired(Boolean required) Set up whether a value is required for the property (not nullable).voidsetSemanticType(String semanticType) Set up the semantic role of the property: column (the default), measure or dimension.voidsetTransformDescription(String transformDescription) Set up the description in business terms of the transformation that produces the property.voidsetTransformLogic(String transformLogic) Set up the logic (for example SQL) of the transformation that produces the property.voidsetTransformSourceObjects(List<String> transformSourceObjects) Set up the list of source objects used in the transformation that produces the property.voidSet up whether the values of the property are unique.toString()Standard toString method.Methods inherited from class org.odpi.openmetadata.frameworks.integration.bitol.odcs.DataContractSchemaElement
getAuthoritativeDefinitions, getBusinessName, getCustomProperties, getDeprecated, getDescription, getId, getName, getPhysicalName, getPhysicalType, getSynonyms, getTags, setAuthoritativeDefinitions, setBusinessName, setCustomProperties, setDeprecated, setDescription, setId, setName, setPhysicalName, setPhysicalType, setSynonyms, setTags
-
Constructor Details
-
DataContractSchemaProperty
public DataContractSchemaProperty()Default constructor
-
-
Method Details
-
getLogicalType
Return the logical (platform independent) type of the property. Standard values are defined in DataContractLogicalType.- Returns:
- string type name
-
setLogicalType
Set up the logical (platform independent) type of the property. Standard values are defined in DataContractLogicalType.- Parameters:
logicalType- string type name
-
getLogicalTypeOptions
Return the options that refine the logical type.- Returns:
- logical type options
-
setLogicalTypeOptions
Set up the options that refine the logical type.- Parameters:
logicalTypeOptions- logical type options
-
getPrimaryKey
Return whether the property is part of the primary key.- Returns:
- boolean flag or null if not specified
-
setPrimaryKey
Set up whether the property is part of the primary key.- Parameters:
primaryKey- boolean flag or null if not specified
-
getPrimaryKeyPosition
Return the position of the property in the primary key (starting from 1; -1 if not part of the key).- Returns:
- integer value or null if not specified
-
setPrimaryKeyPosition
Set up the position of the property in the primary key (starting from 1; -1 if not part of the key).- Parameters:
primaryKeyPosition- integer value or null if not specified
-
getRequired
Return whether a value is required for the property (not nullable).- Returns:
- boolean flag or null if not specified
-
setRequired
Set up whether a value is required for the property (not nullable).- Parameters:
required- boolean flag or null if not specified
-
getUnique
Return whether the values of the property are unique.- Returns:
- boolean flag or null if not specified
-
setUnique
Set up whether the values of the property are unique.- Parameters:
unique- boolean flag or null if not specified
-
getPartitioned
Return whether the property is a partition key.- Returns:
- boolean flag or null if not specified
-
setPartitioned
Set up whether the property is a partition key.- Parameters:
partitioned- boolean flag or null if not specified
-
getPartitionKeyPosition
Return the position of the property in the partition key (starting from 1; -1 if not a partition key).- Returns:
- integer value or null if not specified
-
setPartitionKeyPosition
Set up the position of the property in the partition key (starting from 1; -1 if not a partition key).- Parameters:
partitionKeyPosition- integer value or null if not specified
-
getClassification
Return the data classification of the property, for example public, restricted or confidential.- Returns:
- string classification
-
setClassification
Set up the data classification of the property, for example public, restricted or confidential.- Parameters:
classification- string classification
-
getEncryptedName
Return the name of the property that holds the encrypted version of this property's values.- Returns:
- string name
-
setEncryptedName
Set up the name of the property that holds the encrypted version of this property's values.- Parameters:
encryptedName- string name
-
getTransformSourceObjects
Return the list of source objects used in the transformation that produces the property.- Returns:
- list of object names
-
setTransformSourceObjects
Set up the list of source objects used in the transformation that produces the property.- Parameters:
transformSourceObjects- list of object names
-
getTransformLogic
Return the logic (for example SQL) of the transformation that produces the property.- Returns:
- string logic
-
setTransformLogic
Set up the logic (for example SQL) of the transformation that produces the property.- Parameters:
transformLogic- string logic
-
getTransformDescription
Return the description in business terms of the transformation that produces the property.- Returns:
- string description
-
setTransformDescription
Set up the description in business terms of the transformation that produces the property.- Parameters:
transformDescription- string description
-
getExamples
Return the list of example values.- Returns:
- list of values
-
setExamples
Set up the list of example values.- Parameters:
examples- list of values
-
getCriticalDataElement
Return whether the property is a critical data element.- Returns:
- boolean flag or null if not specified
-
setCriticalDataElement
Set up whether the property is a critical data element.- Parameters:
criticalDataElement- boolean flag or null if not specified
-
getRelationships
Return the list of relationships from this property to other properties.- Returns:
- list of relationships
-
setRelationships
Set up the list of relationships from this property to other properties.- Parameters:
relationships- list of relationships
-
getQuality
Return the list of data quality checks for this property.- Returns:
- list of quality rules
-
setQuality
Set up the list of data quality checks for this property.- Parameters:
quality- list of quality rules
-
getProperties
Return the nested properties (when the logical type is object).- Returns:
- list of nested properties
-
setProperties
Set up the nested properties (when the logical type is object).- Parameters:
properties- list of nested properties
-
getItems
Return the description of the items (when the logical type is array).- Returns:
- item property description
-
setItems
Set up the description of the items (when the logical type is array).- Parameters:
items- item property description
-
getEnumValues
Return the enumeration of allowed values for this property (the enum array in the document).- Returns:
- List
-
setEnumValues
Set up the enumeration of allowed values for this property (the enum array in the document).- Parameters:
enumValues- List
-
getMap
Return the key and value definitions when the logical type is map.- Returns:
- DataContractSchemaMap
-
setMap
Set up the key and value definitions when the logical type is map.- Parameters:
map- DataContractSchemaMap
-
getSemanticType
Return the semantic role of the property: column (the default), measure or dimension.- Returns:
- String
-
setSemanticType
Set up the semantic role of the property: column (the default), measure or dimension.- Parameters:
semanticType- String
-
toString
Standard toString method.- Overrides:
toStringin classDataContractSchemaElement- Returns:
- print out of variables in a JSON-style
-
equals
Compare the values of the supplied object with those stored in the current object.- Overrides:
equalsin classDataContractSchemaElement- Parameters:
objectToCompare- supplied object- Returns:
- boolean result of comparison
-
hashCode
public int hashCode()Return hash code based on properties.- Overrides:
hashCodein classDataContractSchemaElement- Returns:
- int
-