Class BoundCodeableConceptDt<T extends Enum<?>>
- java.lang.Object
-
- ca.uhn.fhir.model.api.BaseElement
-
- ca.uhn.fhir.model.api.BaseIdentifiableElement
-
- ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt
-
- ca.uhn.fhir.model.dstu2.composite.BoundCodeableConceptDt<T>
-
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IBoundCodeableConcept,ca.uhn.fhir.model.api.ICompositeDatatype,ca.uhn.fhir.model.api.ICompositeElement,ca.uhn.fhir.model.api.IDatatype,ca.uhn.fhir.model.api.IElement,ca.uhn.fhir.model.api.IIdentifiableElement,ca.uhn.fhir.model.api.ISupportsUndeclaredExtensions,Serializable,org.hl7.fhir.instance.model.api.IBase,org.hl7.fhir.instance.model.api.IBaseDatatype,org.hl7.fhir.instance.model.api.ICompositeType
public class BoundCodeableConceptDt<T extends Enum<?>> extends CodeableConceptDt implements ca.uhn.fhir.model.api.IBoundCodeableConcept
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description BoundCodeableConceptDt()Deprecated.This constructor is provided only for serialization support.BoundCodeableConceptDt(ca.uhn.fhir.model.api.IValueSetEnumBinder<T> theBinder)ConstructorBoundCodeableConceptDt(ca.uhn.fhir.model.api.IValueSetEnumBinder<T> theBinder, Collection<T> theValues)ConstructorBoundCodeableConceptDt(ca.uhn.fhir.model.api.IValueSetEnumBinder<T> theBinder, T theValue)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Set<T>getValueAsEnum()Loops through thecodingsin this codeable concept and returns the first bound enumerated type that matches.voidsetValueAsEnum(Collection<T> theValues)Sets theCodeableConceptDt.getCoding()to contain a coding with the code and system defined by the given enumerated types, AND clearing any existing codings first.voidsetValueAsEnum(T theValue)Sets theCodeableConceptDt.getCoding()to contain a coding with the code and system defined by the given enumerated type, AND clearing any existing codings first.-
Methods inherited from class ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt
addCoding, addCoding, getAllPopulatedChildElementsOfType, getCoding, getCodingFirstRep, getText, getTextElement, isEmpty, setCoding, setText, setText
-
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
-
-
-
-
Constructor Detail
-
BoundCodeableConceptDt
@Deprecated public BoundCodeableConceptDt()
Deprecated.This constructor is provided only for serialization support. Do not call it directly!
-
BoundCodeableConceptDt
public BoundCodeableConceptDt(ca.uhn.fhir.model.api.IValueSetEnumBinder<T> theBinder)
Constructor
-
BoundCodeableConceptDt
public BoundCodeableConceptDt(ca.uhn.fhir.model.api.IValueSetEnumBinder<T> theBinder, T theValue)
Constructor
-
BoundCodeableConceptDt
public BoundCodeableConceptDt(ca.uhn.fhir.model.api.IValueSetEnumBinder<T> theBinder, Collection<T> theValues)
Constructor
-
-
Method Detail
-
setValueAsEnum
public void setValueAsEnum(Collection<T> theValues)
Sets theCodeableConceptDt.getCoding()to contain a coding with the code and system defined by the given enumerated types, AND clearing any existing codings first. If theValue is null, existing codings are cleared and no codings are added.- Parameters:
theValues- The value to add, ornull
-
setValueAsEnum
public void setValueAsEnum(T theValue)
Sets theCodeableConceptDt.getCoding()to contain a coding with the code and system defined by the given enumerated type, AND clearing any existing codings first. If theValue is null, existing codings are cleared and no codings are added.- Parameters:
theValue- The value to add, ornull
-
getValueAsEnum
public Set<T> getValueAsEnum()
Loops through thecodingsin this codeable concept and returns the first bound enumerated type that matches. Use caution using this method, see the return description for more information.- Returns:
- Returns the bound enumerated type, or
nullif none are found. Note that a null return value doesn't neccesarily imply that this Codeable Concept has no codes, only that it has no codes that match the enum.
-
-