Package org.hl7.fhir.r4.model
Class CodeType
-
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement,Externalizable,Serializable,Comparable<CodeType>,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<String>,ICoding
public class CodeType extends StringType implements Comparable<CodeType>, ICoding
Primitive type "code" in FHIR, when not bound to an enumerated list of codes- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(CodeType theCode)CodeTypecopy()protected Stringencode(String theValue)Subclasses must override to convert a "coerced" value into an encoded one.StringfhirType()StringgetCode()StringgetDisplay()StringgetSystem()StringgetVersion()booleanhasCode()booleanhasDisplay()booleanhasSystem()booleanhasVersion()protected Stringparse(String theValue)Subclasses must override to convert an encoded representation of this datatype into a "coerced" oneCodeTypesetSystem(String system)booleansupportsDisplay()booleansupportsVersion()-
Methods inherited from class org.hl7.fhir.r4.model.StringType
getTranslation, getValueNotNull, toString
-
Methods inherited from class org.hl7.fhir.r4.model.PrimitiveType
asStringValue, equalsDeep, equalsShallow, forceStringValue, fromStringValue, getProperty, getTypesForProperty, getValue, getValueAsString, hashCode, hasPrimitiveValue, hasValue, isEmpty, isPrimitive, makeProperty, primitiveValue, readExternal, setProperty, setProperty, setValue, setValueAsString, typedCopy, updateStringValue, writeExternal
-
Methods inherited from class org.hl7.fhir.r4.model.Element
addChild, addExtension, addExtension, addExtension, copyValues, getExtension, getExtensionByUrl, getExtensionFirstRep, getExtensionsByUrl, getExtensionString, getId, getIdBase, getIdElement, getNamedProperty, hasExtension, hasExtension, hasId, hasIdElement, isDisallowExtensions, listChildren, noExtensions, removeExtension, setDisallowExtensions, setExtension, setId, setIdBase, setIdElement
-
Methods inherited from class org.hl7.fhir.r4.model.Base
castToAddress, castToAnnotation, castToAttachment, castToBase64Binary, castToBoolean, castToCanonical, castToCode, castToCodeableConcept, castToCoding, castToContactDetail, castToContactPoint, castToContributor, castToDataRequirement, castToDate, castToDateTime, castToDecimal, castToDosage, castToDuration, castToElementDefinition, castToExpression, castToExtension, castToHumanName, castToId, castToIdentifier, castToInstant, castToInteger, castToMarkdown, castToMarketingStatus, castToMeta, castToMoney, castToNarrative, castToOid, castToParameterDefinition, castToPeriod, castToPopulation, castToPositiveInt, castToProdCharacteristic, castToProductShelfLife, castToQuantity, castToRange, castToRatio, castToReference, castToRelatedArtifact, castToResource, castToSampledData, castToSignature, castToSimpleQuantity, castToString, castToSubstanceAmount, castToTime, castToTiming, castToTriggerDefinition, castToType, castToUnsignedInt, castToUri, castToUrl, castToUsageContext, castToXhtml, castToXhtmlString, children, clearUserData, compareDeep, compareDeep, compareDeep, compareDeep, compareValues, compareValues, dateTimeValue, equals, getChildByName, getFormatCommentsPost, getFormatCommentsPre, getNamedProperty, getUserData, getUserInt, getUserString, hasFormatComment, hasType, hasUserData, isBooleanPrimitive, isDateTime, isMetadataBased, isResource, listChildrenByName, 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
getFormatCommentsPost, getFormatCommentsPre, getUserData, hasFormatComment, setUserData
-
-
-
-
Method Detail
-
compareTo
public int compareTo(CodeType theCode)
- Specified by:
compareToin interfaceComparable<CodeType>
-
parse
protected String parse(String theValue)
Description copied from class:PrimitiveTypeSubclasses must override to convert an encoded representation of this datatype into a "coerced" one- Overrides:
parsein classStringType- Parameters:
theValue- Will not be null- Returns:
- May return null if the value does not correspond to anything
-
encode
protected String encode(String theValue)
Description copied from class:PrimitiveTypeSubclasses must override to convert a "coerced" value into an encoded one.- Overrides:
encodein classStringType- Parameters:
theValue- Will not be null- Returns:
- May return null if the value does not correspond to anything
-
copy
public CodeType copy()
- Overrides:
copyin classStringType
-
fhirType
public String fhirType()
- Specified by:
fhirTypein interfaceorg.hl7.fhir.instance.model.api.IBase- Overrides:
fhirTypein classStringType
-
getVersion
public String getVersion()
- Specified by:
getVersionin interfaceICoding
-
hasVersion
public boolean hasVersion()
- Specified by:
hasVersionin interfaceICoding
-
getDisplay
public String getDisplay()
- Specified by:
getDisplayin interfaceICoding
-
hasDisplay
public boolean hasDisplay()
- Specified by:
hasDisplayin interfaceICoding
-
supportsVersion
public boolean supportsVersion()
- Specified by:
supportsVersionin interfaceICoding
-
supportsDisplay
public boolean supportsDisplay()
- Specified by:
supportsDisplayin interfaceICoding
-
-