Class Binary

All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement, Serializable, org.hl7.fhir.instance.model.api.IAnyResource, org.hl7.fhir.instance.model.api.IBase, org.hl7.fhir.instance.model.api.IBaseBinary, org.hl7.fhir.instance.model.api.IBaseResource

public class Binary extends BaseBinary implements org.hl7.fhir.instance.model.api.IBaseBinary
A binary resource can contain any content, whether text, image, pdf, zip archive, etc.
See Also:
  • Field Details

    • contentType

      protected CodeType contentType
      MimeType of the binary content represented as a standard MimeType (BCP 13).
    • securityContext

      Treat this binary as if it was this other resource for access control purposes.
    • securityContextTarget

      The actual object that is the target of the reference (Treat this binary as if it was this other resource for access control purposes.)
    • content

      The actual content, base64 encoded.
    • SP_CONTENTTYPE

      public static final String SP_CONTENTTYPE
      Search parameter: contenttype

      Description: MimeType of the binary content
      Type: token
      Path: Binary.contentType

      See Also:
    • CONTENTTYPE

      public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTENTTYPE
      Fluent Client search parameter constant for contenttype

      Description: MimeType of the binary content
      Type: token
      Path: Binary.contentType

  • Constructor Details

  • Method Details

    • getContentTypeElement

      Returns:
      contentType (MimeType of the binary content represented as a standard MimeType (BCP 13).). This is the underlying object with id, value and extensions. The accessor "getContentType" gives direct access to the value
    • hasContentTypeElement

      public boolean hasContentTypeElement()
    • hasContentType

      public boolean hasContentType()
    • setContentTypeElement

      Parameters:
      value - contentType (MimeType of the binary content represented as a standard MimeType (BCP 13).). This is the underlying object with id, value and extensions. The accessor "getContentType" gives direct access to the value
    • getContentType

      Specified by:
      getContentType in interface org.hl7.fhir.instance.model.api.IBaseBinary
      Returns:
      MimeType of the binary content represented as a standard MimeType (BCP 13).
    • setContentType

      public Binary setContentType(String value)
      Specified by:
      setContentType in interface org.hl7.fhir.instance.model.api.IBaseBinary
      Parameters:
      value - MimeType of the binary content represented as a standard MimeType (BCP 13).
    • getSecurityContext

      Returns:
      securityContext (Treat this binary as if it was this other resource for access control purposes.)
    • hasSecurityContext

      public boolean hasSecurityContext()
    • setSecurityContext

      Parameters:
      value - securityContext (Treat this binary as if it was this other resource for access control purposes.)
    • getSecurityContextTarget

      Returns:
      securityContext The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Treat this binary as if it was this other resource for access control purposes.)
    • setSecurityContextTarget

      Parameters:
      value - securityContext The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Treat this binary as if it was this other resource for access control purposes.)
    • getContentElement

      Specified by:
      getContentElement in interface org.hl7.fhir.instance.model.api.IBaseBinary
      Specified by:
      getContentElement in class BaseBinary
      Returns:
      content (The actual content, base64 encoded.). This is the underlying object with id, value and extensions. The accessor "getContent" gives direct access to the value
    • hasContentElement

      public boolean hasContentElement()
    • hasContent

      public boolean hasContent()
    • setContentElement

      Parameters:
      value - content (The actual content, base64 encoded.). This is the underlying object with id, value and extensions. The accessor "getContent" gives direct access to the value
    • getContent

      public byte[] getContent()
      Specified by:
      getContent in interface org.hl7.fhir.instance.model.api.IBaseBinary
      Returns:
      The actual content, base64 encoded.
    • setContent

      public Binary setContent(byte[] value)
      Specified by:
      setContent in interface org.hl7.fhir.instance.model.api.IBaseBinary
      Parameters:
      value - The actual content, base64 encoded.
    • listChildren

      protected void listChildren(List<Property> children)
      Overrides:
      listChildren in class Resource
    • getNamedProperty

      public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      getNamedProperty in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • getProperty

      public Base[] getProperty(int hash, String name, boolean checkValid) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      getProperty in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • setProperty

      public Base setProperty(int hash, String name, Base value) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      setProperty in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • setProperty

      public Base setProperty(String name, Base value) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      setProperty in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • makeProperty

      public Base makeProperty(int hash, String name) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      makeProperty in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • getTypesForProperty

      public String[] getTypesForProperty(int hash, String name) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      getTypesForProperty in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • addChild

      public Base addChild(String name) throws org.hl7.fhir.exceptions.FHIRException
      Overrides:
      addChild in class Resource
      Throws:
      org.hl7.fhir.exceptions.FHIRException
    • fhirType

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

      public Binary copy()
      Specified by:
      copy in class Resource
    • typedCopy

      protected Binary typedCopy()
    • equalsDeep

      public boolean equalsDeep(Base other_)
      Overrides:
      equalsDeep in class Resource
    • equalsShallow

      public boolean equalsShallow(Base other_)
      Overrides:
      equalsShallow in class Resource
    • isEmpty

      public boolean isEmpty()
      Specified by:
      isEmpty in interface org.hl7.fhir.instance.model.api.IBase
      Overrides:
      isEmpty in class Resource
    • getResourceType

      Specified by:
      getResourceType in class Resource