Class BooleanType

All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement, Externalizable, Serializable, org.hl7.fhir.instance.model.api.IBase, org.hl7.fhir.instance.model.api.IBaseBooleanDatatype, 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<Boolean>

public class BooleanType extends PrimitiveType<Boolean> implements org.hl7.fhir.instance.model.api.IBaseBooleanDatatype
Primitive type "boolean" in FHIR "true" or "false"
See Also:
  • Constructor Details

  • Method Details

    • booleanValue

      public boolean booleanValue()
      Returns the value of this type as a primitive boolean.
      Returns:
      Returns the value of this type as a primitive boolean.
      Throws:
      NullPointerException - If the value is not set
    • copy

      public BooleanType copy()
      Specified by:
      copy in class PrimitiveType<Boolean>
    • encode

      protected String encode(Boolean theValue)
      Description copied from class: PrimitiveType
      Subclasses must override to convert a "coerced" value into an encoded one.
      Specified by:
      encode in class PrimitiveType<Boolean>
      Parameters:
      theValue - Will not be null
      Returns:
      May return null if the value does not correspond to anything
    • fhirType

      public String fhirType()
      Specified by:
      fhirType in interface org.hl7.fhir.instance.model.api.IBase
      Overrides:
      fhirType in class Element
    • parse

      protected Boolean parse(String theValue)
      Description copied from class: PrimitiveType
      Subclasses must override to convert an encoded representation of this datatype into a "coerced" one
      Specified by:
      parse in class PrimitiveType<Boolean>
      Parameters:
      theValue - Will not be null
      Returns:
      May return null if the value does not correspond to anything