Class OffsetWhen<D,C extends FDSConfig,V extends org.hl7.fhir.instance.model.api.IBaseEnumeration<?>>

java.lang.Object
io.github.jy95.fds.common.translators.timing.repeat.OffsetWhen<D,C,V>
Type Parameters:
D - The type of the translated data.
All Implemented Interfaces:
Translator<D>

public class OffsetWhen<D,C extends FDSConfig,V extends org.hl7.fhir.instance.model.api.IBaseEnumeration<?>> extends Object implements Translator<D>
Translator for translating "timing.repeat.offset" / "timing.repeat.when".
Since:
2.1.9
Author:
jy95
  • Constructor Details

    • OffsetWhen

      public OffsetWhen()
  • Method Details

    • isPresent

      public boolean isPresent(D data)
      Checks whether a field is present and can be converted to a string.
      Specified by:
      isPresent in interface Translator<D>
      Parameters:
      data - the fhir element containing field to check
      Returns:
      true if the field is present, false otherwise
    • convert

      public CompletableFuture<String> convert(D data)
      Converts a field into a human-readable string representation asynchronously.
      Specified by:
      convert in interface Translator<D>
      Parameters:
      data - the fhir element containing field to be converted
      Returns:
      a CompletableFuture that will complete with the human-readable string