Package org.hisp.dhis.model
Class IdScheme
java.lang.Object
org.hisp.dhis.model.IdScheme
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic IdSchemecreateAttributeIdScheme(String attribute) Creates anIdSchemewith object property ATTRIBUTE for the given attribute ID (UID).static IdSchemecreateIdScheme(String idScheme) Creates anIdSchemebased on the given string.booleanorg.hisp.dhis.model.IdScheme.ObjectPropertyinthashCode()name()Returns a string representation of thisIdScheme.toString()Returns a string representation of thisIdScheme.
-
Field Details
-
UID
-
CODE
-
-
Constructor Details
-
IdScheme
-
-
Method Details
-
createAttributeIdScheme
Creates anIdSchemewith object property ATTRIBUTE for the given attribute ID (UID). The attribute must be a valid UID and cannot be null.- Parameters:
attribute- the attribute ID (UID).- Returns:
- an
IdScheme.
-
createIdScheme
Creates anIdSchemebased on the given string. The string can be on the following formats:- UID
- CODE
- ATTRIBUTE:{attribute-ID}
- Parameters:
idScheme- the ID scheme string.- Returns:
- an
IdScheme. - Throws:
IllegalArgumentException- if the ID scheme string is invalid.
-
getObjectProperty
public org.hisp.dhis.model.IdScheme.ObjectProperty getObjectProperty() -
getAttribute
-
hashCode
public int hashCode() -
equals
-
name
Returns a string representation of thisIdScheme. Alias fortoString().- Returns:
- a string representation of this
IdScheme.
-
toString
Returns a string representation of thisIdScheme.
-