Java Code Examples for org.hl7.fhir.instance.model.api.IPrimitiveType#getValue()

The following examples show how to use org.hl7.fhir.instance.model.api.IPrimitiveType#getValue() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: CareConnectServerConformanceR4Provider.java    From careconnect-reference-implementation with Apache License 2.0 5 votes vote down vote up
private DateTimeType conformanceDate() {
        IPrimitiveType<Date> buildDate = serverConfiguration.getConformanceDate();
        if (buildDate != null) {
            try {
                return new DateTimeType(buildDate.getValue());
            } catch (DataFormatException e) {
// fall through
            }
        }
        return DateTimeType.now();
    }
 
Example 2
Source File: CareConnectServerConformanceProvider.java    From careconnect-reference-implementation with Apache License 2.0 5 votes vote down vote up
private DateTimeType conformanceDate() {
    IPrimitiveType<Date> buildDate = serverConfiguration.getConformanceDate();
    if (buildDate != null) {
        try {
            return new DateTimeType(buildDate.getValue());
        } catch (DataFormatException e) {
            // fall through
        }
    }
    return DateTimeType.now();
}
 
Example 3
Source File: PrimitiveConverter.java    From bunsen with Apache License 2.0 4 votes vote down vote up
protected Object fromHapi(IPrimitiveType primitive) {
  return primitive.getValue();
}
 
Example 4
Source File: DefinitionToAvroVisitor.java    From bunsen with Apache License 2.0 2 votes vote down vote up
protected Object fromHapi(IPrimitiveType primitive) {

      return primitive.getValue();
    }