
Package org.hl7.fhir.dstu2.model
Class PrimitiveType<T>
java.lang.Object
org.hl7.fhir.dstu2.model.Base
org.hl7.fhir.dstu2.model.Element
org.hl7.fhir.dstu2.model.Type
org.hl7.fhir.dstu2.model.PrimitiveType<T>
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement
,Serializable
,org.hl7.fhir.instance.model.api.IBase
,org.hl7.fhir.instance.model.api.IBaseDatatype
,org.hl7.fhir.instance.model.api.IBaseElement
,org.hl7.fhir.instance.model.api.IBaseHasExtensions
,org.hl7.fhir.instance.model.api.IPrimitiveType<T>
- Direct Known Subclasses:
Base64BinaryType
,BaseDateTimeType
,BooleanType
,DecimalType
,Enumeration
,IntegerType
,StringType
,TimeType
,UriType
public abstract class PrimitiveType<T>
extends Type
implements org.hl7.fhir.instance.model.api.IPrimitiveType<T>, org.hl7.fhir.instance.model.api.IBaseHasExtensions
- See Also:
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract Type
copy()
protected abstract String
Subclasses must override to convert a "coerced" value into an encoded one.boolean
equalsDeep
(Base obj) boolean
equalsShallow
(Base obj) void
fromStringValue
(String theValue) getValue()
int
hashCode()
boolean
hasValue()
boolean
isEmpty()
boolean
protected abstract T
Subclasses must override to convert an encoded representation of this datatype into a "coerced" onevoid
setValueAsString
(String theValue) toString()
protected Type
protected void
Methods inherited from class org.hl7.fhir.dstu2.model.Element
addChild, addExtension, addExtension, addExtension, copyValues, fhirType, getExtension, getExtensionByUrl, getExtensionsByUrl, getExtensionString, getId, getIdElement, hasExtension, hasExtension, hasId, hasIdElement, listChildren, setId, setIdElement, setProperty
Methods inherited from class org.hl7.fhir.dstu2.model.Base
castToAddress, castToAnnotation, castToAttachment, castToBase64Binary, castToBoolean, castToCode, castToCodeableConcept, castToCoding, castToContactPoint, castToDate, castToDateTime, castToDecimal, castToDuration, castToElementDefinition, castToExtension, castToHumanName, castToId, castToIdentifier, castToInstant, castToInteger, castToMarkdown, castToMeta, castToMoney, castToNarrative, castToOid, castToPeriod, castToPositiveInt, castToQuantity, castToRange, castToRatio, castToReference, castToResource, castToSampledData, castToSignature, castToSimpleQuantity, castToString, castToTime, castToTiming, castToUnsignedInt, castToUri, children, compareDeep, compareDeep, compareDeep, compareValues, compareValues, equals, getChildByName, getFormatCommentsPost, getFormatCommentsPre, getUserData, getUserInt, getUserString, hasFormatComment, hasType, hasUserData, isMetadataBased, listChildrenByName, setUserData, setUserDataINN
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.hl7.fhir.instance.model.api.IBase
fhirType, getFormatCommentsPost, getFormatCommentsPre, getUserData, hasFormatComment, setUserData
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseElement
getUserData, setUserData
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseHasExtensions
addExtension, getExtension, hasExtension
-
Constructor Details
-
PrimitiveType
public PrimitiveType()
-
-
Method Details
-
getValue
- Specified by:
getValue
in interfaceorg.hl7.fhir.instance.model.api.IPrimitiveType<T>
-
asStringValue
-
hashCode
-
setValue
- Specified by:
setValue
in interfaceorg.hl7.fhir.instance.model.api.IPrimitiveType<T>
-
updateStringValue
-
isEmpty
-
fromStringValue
-
parse
Subclasses must override to convert an encoded representation of this datatype into a "coerced" one- Parameters:
theValue
- Will not be null- Returns:
- May return null if the value does not correspond to anything
-
encode
Subclasses must override to convert a "coerced" value into an encoded one.- Parameters:
theValue
- Will not be null- Returns:
- May return null if the value does not correspond to anything
-
isPrimitive
- Overrides:
isPrimitive
in classBase
-
primitiveValue
- Overrides:
primitiveValue
in classBase
-
toString
-
hasValue
- Specified by:
hasValue
in interfaceorg.hl7.fhir.instance.model.api.IPrimitiveType<T>
-
getValueAsString
- Specified by:
getValueAsString
in interfaceorg.hl7.fhir.instance.model.api.IPrimitiveType<T>
-
setValueAsString
- Specified by:
setValueAsString
in interfaceorg.hl7.fhir.instance.model.api.IPrimitiveType<T>
-
typedCopy
-
copy
-
equalsDeep
- Overrides:
equalsDeep
in classElement
-
equalsShallow
- Overrides:
equalsShallow
in classElement
-