
Package org.hl7.fhir.dstu2.model
Class Base64BinaryType
java.lang.Object
org.hl7.fhir.dstu2.model.Base
org.hl7.fhir.dstu2.model.Element
org.hl7.fhir.dstu2.model.Type
org.hl7.fhir.dstu2.model.PrimitiveType<byte[]>
org.hl7.fhir.dstu2.model.Base64BinaryType
- All Implemented Interfaces:
ca.uhn.fhir.model.api.IElement
,Serializable
,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<byte[]>
Primitive type "base64Binary" in FHIR: a sequence of bytes represented in
base64
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionConstructorBase64BinaryType
(byte[] theBytes) Base64BinaryType
(String theValue) -
Method Summary
Modifier and TypeMethodDescriptionvoid
checkValidBase64
(String toCheck) Checks if the passed in String is a validBase64
encoded String.copy()
protected String
encode
(byte[] theValue) Subclasses must override to convert a "coerced" value into an encoded one.fhirType()
protected byte[]
Subclasses must override to convert an encoded representation of this datatype into a "coerced" onevoid
setValueAsString
(String theValue) Methods inherited from class org.hl7.fhir.dstu2.model.PrimitiveType
asStringValue, equalsDeep, equalsShallow, fromStringValue, getValue, getValueAsString, hashCode, hasValue, isEmpty, isPrimitive, primitiveValue, setValue, toString, typedCopy, updateStringValue
Methods inherited from class org.hl7.fhir.dstu2.model.Element
addChild, addExtension, addExtension, addExtension, copyValues, getExtension, getExtensionByUrl, getExtensionsByUrl, getExtensionString, getId, getIdElement, hasExtension, hasExtension, hasId, hasIdElement, listChildren, setId, setIdElement, setProperty
Methods inherited from class org.hl7.fhir.dstu2.model.Base
castToAddress, castToAnnotation, castToAttachment, castToBase64Binary, castToBoolean, castToCode, castToCodeableConcept, castToCoding, castToContactPoint, castToDate, castToDateTime, castToDecimal, castToDuration, castToElementDefinition, castToExtension, castToHumanName, castToId, castToIdentifier, castToInstant, castToInteger, castToMarkdown, castToMeta, castToMoney, castToNarrative, castToOid, castToPeriod, castToPositiveInt, castToQuantity, castToRange, castToRatio, castToReference, castToResource, castToSampledData, castToSignature, castToSimpleQuantity, castToString, castToTime, castToTiming, castToUnsignedInt, castToUri, children, compareDeep, compareDeep, compareDeep, compareValues, compareValues, equals, getChildByName, getFormatCommentsPost, getFormatCommentsPre, getUserData, getUserInt, getUserString, hasFormatComment, hasType, hasUserData, isMetadataBased, 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
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseElement
getUserData, setUserData
Methods inherited from interface org.hl7.fhir.instance.model.api.IBaseHasExtensions
addExtension, getExtension, hasExtension
-
Constructor Details
-
Base64BinaryType
public Base64BinaryType()Constructor -
Base64BinaryType
-
Base64BinaryType
-
-
Method Details
-
setValueAsString
- Specified by:
setValueAsString
in interfaceorg.hl7.fhir.instance.model.api.IPrimitiveType<byte[]>
- Overrides:
setValueAsString
in classPrimitiveType<byte[]>
-
parse
Description copied from class:PrimitiveType
Subclasses must override to convert an encoded representation of this datatype into a "coerced" one- Specified by:
parse
in classPrimitiveType<byte[]>
- Parameters:
theValue
- Will not be null- Returns:
- May return null if the value does not correspond to anything
-
encode
Description copied from class:PrimitiveType
Subclasses must override to convert a "coerced" value into an encoded one.- Specified by:
encode
in classPrimitiveType<byte[]>
- Parameters:
theValue
- Will not be null- Returns:
- May return null if the value does not correspond to anything
-
copy
- Specified by:
copy
in classPrimitiveType<byte[]>
-
fhirType
-
checkValidBase64
Checks if the passed in String is a validBase64
encoded String. Will throw aDataFormatException
if not formatted correctly.- Parameters:
toCheck
-String
to check if validBase64
- Throws:
DataFormatException
-