Package org.hl7.fhir.r5.elementmodel
Class Element
java.lang.Object
org.hl7.fhir.r5.model.Base
org.hl7.fhir.r5.elementmodel.Element
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement,Serializable,org.hl7.fhir.instance.model.api.IBase
This class represents the underlying reference model of FHIR
A resource is nothing but a set of elements, where every element has a
name, maybe a stated type, maybe an id, and either a value or child elements
(one or the other, but not both or neither)
- Author:
- Grahame Grieve
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassclassstatic enum -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddMessage(org.hl7.fhir.utilities.validation.ValidationMessage vm) asType()voidclear()voidintcol()booleanequalsDeep(Base other) booleanequalsShallow(Base other) fhirType()getChildren(String name) getChildrenByName(String name) getChildValue(String name) getExtension(String url) getExtensionValue(String url) intgetIndex()List<org.hl7.fhir.utilities.validation.ValidationMessage>getName()getNamedChild(String name) voidgetNamedChildren(String name, List<Element> list) voidgetNamedChildrenWithWildcard(String string, List<Element> values) getNamedChildValue(String name) this is set by the instance validator.getPath()Base[]getProperty(int hash, String name, boolean checkValid) getType()String[]getTypesForProperty(int hash, String name) getValue()org.hl7.fhir.utilities.xhtml.XhtmlNodegetXhtml()return XHTML if this is an XHTML node, else nullbooleanbooleanbooleanhasChildren(String name) booleanbooleanhasDescendant(Element element) booleanbooleanhasExtension(String url) booleanhasIndex()booleanbooleanbooleanbooleanhasType()booleanhasValue()booleanbooleanbooleanisEmpty()booleanisList()booleanbooleanbooleanbooleanbooleanintline()protected voidlistChildren(List<Property> childProps) makeProperty(int hash, String name) markLocation(int line, int col) voidmarkValidation(StructureDefinition profile, ElementDefinition definition) voidvoidremoveChild(String name) voidsetChildValue(String name, String value) voidsetExplicitType(String explicitType) voidvoidsetIndex(int index) voidsetParentForValidator(Element parentForValidator) voidvoidsetProhibited(boolean prohibited) setProperty(int hash, String name, Base value) voidsetRequired(boolean required) voidvoidsetXhtml(org.hl7.fhir.utilities.xhtml.XhtmlNode xhtml) voidsort()toString()voidupdateProperty(Property property, Element.SpecialElement special, Property elementProperty) Methods inherited from class org.hl7.fhir.r5.model.Base
addChild, children, clearUserData, compareDeep, compareDeep, compareDeep, compareDeep, compareValues, compareValues, copyUserData, copyValues, dateTimeValue, equals, getChildByName, getFormatCommentsPost, getFormatCommentsPre, getNamedProperty, getNamedProperty, getUserData, getUserInt, getUserString, hasFormatComment, hasType, hasUserData, isDateTime, listChildrenByName, listChildrenByName, setProperty, setUserData, setUserDataINN
-
Constructor Details
-
Element
-
Element
-
Element
-
Element
-
-
Method Details
-
updateProperty
public void updateProperty(Property property, Element.SpecialElement special, Property elementProperty) -
getSpecial
-
getName
-
getType
-
getValue
-
hasChildren
-
getChildren
-
hasComments
-
getComments
-
getProperty
-
setValue
-
setType
-
hasValue
-
getChildrenByName
-
numberChildren
-
getIndex
-
hasIndex
-
setIndex
-
getChildValue
-
setChildValue
-
getChildren
-
hasType
-
fhirType
-
getProperty
public Base[] getProperty(int hash, String name, boolean checkValid) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
getPropertyin classBase- Throws:
org.hl7.fhir.exceptions.FHIRException
-
listChildren
- Overrides:
listChildrenin classBase
-
setProperty
public Base setProperty(int hash, String name, Base value) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
setPropertyin classBase- Throws:
org.hl7.fhir.exceptions.FHIRException
-
makeProperty
- Overrides:
makePropertyin classBase- Throws:
org.hl7.fhir.exceptions.FHIRException
-
isPrimitive
- Overrides:
isPrimitivein classBase
-
isBooleanPrimitive
- Overrides:
isBooleanPrimitivein classBase
-
isResource
- Overrides:
isResourcein classBase
-
hasPrimitiveValue
- Overrides:
hasPrimitiveValuein classBase
-
primitiveValue
- Overrides:
primitiveValuein classBase
-
line
-
col
-
markLocation
-
clearDecorations
-
markValidation
-
getNamedChild
-
getNamedChildren
-
getNamedChildValue
-
getNamedChildrenWithWildcard
-
getXhtml
Description copied from class:Basereturn XHTML if this is an XHTML node, else null -
setXhtml
-
isEmpty
-
getElementProperty
-
hasElementProperty
-
hasChild
-
hasChildren
-
toString
-
getIdBase
-
setIdBase
-
equalsDeep
- Overrides:
equalsDeepin classBase
-
equalsShallow
- Overrides:
equalsShallowin classBase
-
asType
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
isMetadataBased
- Overrides:
isMetadataBasedin classBase
-
isList
-
isBaseList
-
getTypesForProperty
public String[] getTypesForProperty(int hash, String name) throws org.hl7.fhir.exceptions.FHIRException - Overrides:
getTypesForPropertyin classBase- Throws:
org.hl7.fhir.exceptions.FHIRException
-
sort
-
getAsICoding
- Throws:
org.hl7.fhir.exceptions.FHIRException
-
getExplicitType
-
setExplicitType
-
hasDescendant
-
getExtension
-
getExtensionValue
-
hasExtension
-
getParentForValidator
this is set by the instance validator. There's no reason to maintain this when working with an element tree, and so it should be ignored outside the validator -
setParentForValidator
-
hasParentForValidator
-
clear
-
getPath
-
setPath
-
addMessage
-
hasMessages
-
getMessages
-
removeChild
-
isProhibited
-
setProhibited
-
isRequired
-
setRequired
-