Class ExtensionDt
- All Implemented Interfaces:
ICompositeDatatype
,ICompositeElement
,IDatatype
,IElement
,IIdentifiableElement
,ISupportsUndeclaredExtensions
,Serializable
,IBase
,IBaseDatatype
,IBaseExtension<ExtensionDt,
,IDatatype> ICompositeType
- See Also:
-
Constructor Summary
ConstructorDescriptionExtensionDt
(boolean theIsModifier) ExtensionDt
(boolean theIsModifier, String theUrl) ExtensionDt
(boolean theIsModifier, String theUrl, IBaseDatatype theValue) -
Method Summary
Modifier and TypeMethodDescriptiongetAllPopulatedChildElementsOfType
(Class<T> theType) Deprecated.getUrl()
Returns the URL for this extension.Retained for backward compatibilitygetValue()
Returns the value of this extension, if one exists.Returns the value of this extension, casted to a primitive datatype.boolean
isEmpty()
boolean
void
setModifier
(boolean theModifier) setValue
(IBaseDatatype theValue) toString()
Methods inherited from class ca.uhn.fhir.model.api.BaseIdentifiableElement
getElementSpecificId, getId, setElementSpecificId, setId, setId
Methods inherited from class ca.uhn.fhir.model.api.BaseElement
addUndeclaredExtension, addUndeclaredExtension, addUndeclaredExtension, getAllUndeclaredExtensions, getFormatCommentsPost, getFormatCommentsPre, getUndeclaredExtensions, getUndeclaredExtensionsByUrl, getUndeclaredModifierExtensions, getUserData, hasFormatComment, isBaseEmpty, setUserData
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.hl7.fhir.instance.model.api.IBase
fhirType, getFormatCommentsPost, getFormatCommentsPre, getUserData, hasFormatComment, setUserData
-
Constructor Details
-
ExtensionDt
public ExtensionDt() -
ExtensionDt
-
ExtensionDt
-
ExtensionDt
-
-
Method Details
-
getUrl
Returns the URL for this extension.Note that before HAPI 0.9 this method returned a
StringDt
but as of HAPI 0.9 this method returns a plain string. This was changed because it does not make sense to use a StringDt here since the URL itself can not contain extensions and it was therefore misleading.- Specified by:
getUrl
in interfaceIBaseExtension<ExtensionDt,
IDatatype>
-
getUrlAsString
Retained for backward compatibility- See Also:
-
getValue
Returns the value of this extension, if one exists.Note that if this extension contains extensions (instead of a datatype) then this method will return null. In that case, you must use
BaseElement.getUndeclaredExtensions()
andBaseElement.getUndeclaredModifierExtensions()
to retrieve the child extensions.- Specified by:
getValue
in interfaceIBaseExtension<ExtensionDt,
IDatatype>
-
getValueAsPrimitive
Returns the value of this extension, casted to a primitive datatype. This is a convenience method which should only be called if you are sure that the value for this particular extension will be a primitive.Note that if this extension contains extensions (instead of a datatype) then this method will return null. In that case, you must use
BaseElement.getUndeclaredExtensions()
andBaseElement.getUndeclaredModifierExtensions()
to retrieve the child extensions.- Throws:
ClassCastException
- If the value of this extension is not a primitive datatype
-
isEmpty
-
isModifier
-
setModifier
-
setUrl
- Specified by:
setUrl
in interfaceIBaseExtension<ExtensionDt,
IDatatype>
-
setUrl
-
setValue
- Specified by:
setValue
in interfaceIBaseExtension<ExtensionDt,
IDatatype>
-
getAllPopulatedChildElementsOfType
@Deprecated public <T extends IElement> List<T> getAllPopulatedChildElementsOfType(Class<T> theType) Deprecated.Description copied from interface:ICompositeElement
Returns a list containing all child elements matching a given type- Specified by:
getAllPopulatedChildElementsOfType
in interfaceICompositeElement
- Parameters:
theType
- The type to match. If set to null, all child elements will be returned
-
getExtension
- Specified by:
getExtension
in interfaceIBaseExtension<ExtensionDt,
IDatatype>
-
toString
-