Class TimingCodeR5
java.lang.Object
io.github.jy95.fds.r5.translators.TimingCodeR5
- All Implemented Interfaces:
Translator<FDSConfigR5,
,org.hl7.fhir.r5.model.Dosage> TranslatorTiming<FDSConfigR5,
org.hl7.fhir.r5.model.Dosage>
public class TimingCodeR5
extends Object
implements TranslatorTiming<FDSConfigR5,org.hl7.fhir.r5.model.Dosage>
R5 class for translating "timing.code"
- Author:
- jy95
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionconvert
(org.hl7.fhir.r5.model.Dosage dosage) Converts a dosage field into a human-readable string representation asynchronously.boolean
hasRequiredElements
(org.hl7.fhir.r5.model.Dosage dosage) Checks if the "Timing" element of the given dosage object contains the required conditions for this translator.boolean
hasTiming
(org.hl7.fhir.r5.model.Dosage dosage) Checks if the given dosage object contains a "Timing" element.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.jy95.fds.common.types.TranslatorTiming
isPresent
-
Constructor Details
-
TimingCodeR5
public TimingCodeR5()
-
-
Method Details
-
hasTiming
public boolean hasTiming(org.hl7.fhir.r5.model.Dosage dosage) Checks if the given dosage object contains a "Timing" element.- Specified by:
hasTiming
in interfaceTranslatorTiming<FDSConfigR5,
org.hl7.fhir.r5.model.Dosage> - Parameters:
dosage
- the dosage object to check- Returns:
true
if the dosage object has a "Timing" element,false
otherwise
-
convert
Converts a dosage field into a human-readable string representation asynchronously.- Specified by:
convert
in interfaceTranslator<FDSConfigR5,
org.hl7.fhir.r5.model.Dosage> - Parameters:
dosage
- the dosage field to be converted- Returns:
- a
CompletableFuture
that will complete with the human-readable string
-
hasRequiredElements
public boolean hasRequiredElements(org.hl7.fhir.r5.model.Dosage dosage) Checks if the "Timing" element of the given dosage object contains the required conditions for this translator.- Specified by:
hasRequiredElements
in interfaceTranslatorTiming<FDSConfigR5,
org.hl7.fhir.r5.model.Dosage> - Parameters:
dosage
- the dosage object to check- Returns:
true
if the "Timing" element has the required conditions,false
otherwise
-