UNPKG

fhirbuilder

Version:
96 lines (95 loc) 2.92 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.HealthcareServiceAvailableTime = void 0; const base_1 = require("../base"); const base_2 = require("../../../core/r4/validators/base"); /** * @version R4 (v4.0.1) * @summary FHIR® Specification by HL7® * @description Class for HealthcareServiceAvailableTime BackboneElement undefined * @property {string[]} daysOfWeek * @property {IElement[]} _daysOfWeek * @property {boolean} allDay * @property {IElement} _allDay * @property {string} availableStartTime * @property {IElement} _availableStartTime * @property {string} availableEndTime * @property {IElement} _availableEndTime * @author Roberto Araneda Espinoza */ class HealthcareServiceAvailableTime extends base_1.BackboneElement { /** * @description Indicates which days of the week are available between the start and end Times. */ daysOfWeek; /** * @description Extensions for daysOfWeek */ _daysOfWeek; /** * @description Is this always available? (hence times are irrelevant) e.g. 24 hour service. */ allDay; /** * @description Extensions for allDay */ _allDay; /** * @description The opening time of day. Note: If the AllDay flag is set, then this time is ignored. */ availableStartTime; /** * @description Extensions for availableStartTime */ _availableStartTime; /** * @description The closing time of day. Note: If the AllDay flag is set, then this time is ignored. */ availableEndTime; /** * @description Extensions for availableEndTime */ _availableEndTime; /** * @description Returns a JSON representation of the model * @returns {Record<string, any>} */ toJson() { return JSON.parse(JSON.stringify(this)); } /** * @description Returns a string representation of the model * @returns {string} */ toString() { return `HealthcareServiceAvailableTime${JSON.stringify(this.toJson())}`; } /** * @description Returns a pretty string representation of the model * @returns {string} */ toPrettyString() { return `HealthcareServiceAvailableTime${JSON.stringify(this.toJson(), null, 2)}`; } /** * @description Returns a serialized string representation of the model * @returns {string} */ serialize() { return JSON.stringify(this.toJson()); } /** * @description Validates the model * @returns {isValid: boolean, operationOutcome: IOperationOutcome} */ validate() { return (0, base_2.ConformanceValidator)('HealthcareServiceAvailableTime', this); } constructor(args) { super(); if (args) Object.assign(this, args); } } exports.HealthcareServiceAvailableTime = HealthcareServiceAvailableTime;