From a6cd686d7232ed8ba7bf0236378400f05f321e6c Mon Sep 17 00:00:00 2001 From: Chris Moesel Date: Wed, 22 Apr 2026 13:31:10 -0400 Subject: [PATCH 1/2] Initial implementation of Long based on JS Number - Add support for Long literal, ToLong conversion, min/max long values - Use JavaScript Number to represent Long (NOTE: this means that values are imprecise outside of the safe integer range in JS) - Add tests for literals, conversion, and other operations that accept Long arguments - Improve underflow/overflow tests to test boundaries more carefully - Added .skip to tests that fail due to Number imprecision for high values - Unskipped Long tests in the spec tests that now pass --- examples/browser/cql4browsers.js | 84 +- src/elm/arithmetic.ts | 2 + src/elm/literal.ts | 19 + src/elm/type.ts | 31 +- src/runtime/context.ts | 3 + src/util/math.ts | 24 + test/elm/arithmetic/arithmetic-test.ts | 502 +- test/elm/arithmetic/data.cql | 110 +- test/elm/arithmetic/data.js | 11333 ++++++++++++---- test/elm/convert/convert-test.ts | 102 + test/elm/convert/data.cql | 28 +- test/elm/convert/data.js | 3769 +++-- test/elm/literal/data.cql | 1 + test/elm/literal/data.js | 82 +- test/elm/literal/literal-test.ts | 8 + .../cql/CqlAggregateFunctionsTest.cql | 8 +- .../cql/CqlAggregateFunctionsTest.json | 88 +- .../cql/CqlArithmeticFunctionsTest.cql | 60 +- .../cql/CqlArithmeticFunctionsTest.json | 382 +- test/spec-tests/skip-list.txt | 34 +- 20 files changed, 12844 insertions(+), 3826 deletions(-) diff --git a/examples/browser/cql4browsers.js b/examples/browser/cql4browsers.js index 3e42b4ecb..1f6dfa962 100644 --- a/examples/browser/cql4browsers.js +++ b/examples/browser/cql4browsers.js @@ -3680,6 +3680,7 @@ class MinValue extends expression_1.Expression { exports.MinValue = MinValue; MinValue.MIN_VALUES = { '{urn:hl7-org:elm-types:r1}Integer': MathUtil.MIN_INT_VALUE, + '{urn:hl7-org:elm-types:r1}Long': MathUtil.MIN_LONG_VALUE, '{urn:hl7-org:elm-types:r1}Decimal': MathUtil.MIN_FLOAT_VALUE, '{urn:hl7-org:elm-types:r1}DateTime': MathUtil.MIN_DATETIME_VALUE, '{urn:hl7-org:elm-types:r1}Date': MathUtil.MIN_DATE_VALUE, @@ -3709,6 +3710,7 @@ class MaxValue extends expression_1.Expression { exports.MaxValue = MaxValue; MaxValue.MAX_VALUES = { '{urn:hl7-org:elm-types:r1}Integer': MathUtil.MAX_INT_VALUE, + '{urn:hl7-org:elm-types:r1}Long': MathUtil.MAX_LONG_VALUE, '{urn:hl7-org:elm-types:r1}Decimal': MathUtil.MAX_FLOAT_VALUE, '{urn:hl7-org:elm-types:r1}DateTime': MathUtil.MAX_DATETIME_VALUE, '{urn:hl7-org:elm-types:r1}Date': MathUtil.MAX_DATE_VALUE, @@ -5967,7 +5969,7 @@ exports.Slice = Slice; },{"../util/comparison":52,"../util/immutableUtil":54,"../util/util":57,"./builder":16,"./expression":22,"immutable":72}],29:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.StringLiteral = exports.DecimalLiteral = exports.IntegerLiteral = exports.BooleanLiteral = exports.Literal = void 0; +exports.StringLiteral = exports.DecimalLiteral = exports.LongLiteral = exports.IntegerLiteral = exports.BooleanLiteral = exports.Literal = void 0; const expression_1 = require("./expression"); class Literal extends expression_1.Expression { static from(json) { @@ -5976,6 +5978,8 @@ class Literal extends expression_1.Expression { return new BooleanLiteral(json); case '{urn:hl7-org:elm-types:r1}Integer': return new IntegerLiteral(json); + case '{urn:hl7-org:elm-types:r1}Long': + return new LongLiteral(json); case '{urn:hl7-org:elm-types:r1}Decimal': return new DecimalLiteral(json); case '{urn:hl7-org:elm-types:r1}String': @@ -6025,6 +6029,21 @@ class IntegerLiteral extends Literal { } } exports.IntegerLiteral = IntegerLiteral; +class LongLiteral extends Literal { + constructor(json) { + super(json); + this.value = parseInt(this.value, 10); + } + // Define a simple getter to allow type-checking of this class without instanceof + // and in a way that survives minification (as opposed to checking constructor.name) + get isLongLiteral() { + return true; + } + async exec(_ctx) { + return this.value; + } +} +exports.LongLiteral = LongLiteral; class DecimalLiteral extends Literal { constructor(json) { super(json); @@ -7532,7 +7551,7 @@ exports.TupleElementDefinition = TupleElementDefinition; },{"./builder":16,"./expression":22}],41:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.TupleTypeSpecifier = exports.NamedTypeSpecifier = exports.ListTypeSpecifier = exports.IntervalTypeSpecifier = exports.Is = exports.CanConvertQuantity = exports.ConvertQuantity = exports.ConvertsToTime = exports.ConvertsToString = exports.ConvertsToRatio = exports.ConvertsToQuantity = exports.ConvertsToInteger = exports.ConvertsToDecimal = exports.ConvertsToDateTime = exports.ConvertsToDate = exports.ConvertsToBoolean = exports.Convert = exports.ToTime = exports.ToString = exports.ToRatio = exports.ToQuantity = exports.ToInteger = exports.ToDecimal = exports.ToDateTime = exports.ToDate = exports.ToConcept = exports.ToBoolean = exports.As = void 0; +exports.TupleTypeSpecifier = exports.NamedTypeSpecifier = exports.ListTypeSpecifier = exports.IntervalTypeSpecifier = exports.Is = exports.CanConvertQuantity = exports.ConvertQuantity = exports.ConvertsToTime = exports.ConvertsToString = exports.ConvertsToRatio = exports.ConvertsToQuantity = exports.ConvertsToInteger = exports.ConvertsToDecimal = exports.ConvertsToDateTime = exports.ConvertsToDate = exports.ConvertsToBoolean = exports.Convert = exports.ToTime = exports.ToString = exports.ToRatio = exports.ToQuantity = exports.ToLong = exports.ToInteger = exports.ToDecimal = exports.ToDateTime = exports.ToDate = exports.ToConcept = exports.ToBoolean = exports.As = void 0; const expression_1 = require("./expression"); const datetime_1 = require("../datatypes/datetime"); const clinical_1 = require("../datatypes/clinical"); @@ -7678,7 +7697,12 @@ class ToInteger extends expression_1.Expression { } async exec(ctx) { const arg = await this.execArgs(ctx); - if (typeof arg === 'string') { + if (typeof arg === 'number') { + if ((0, math_1.isValidInteger)(arg)) { + return arg; + } + } + else if (typeof arg === 'string') { const integer = parseInt(arg); if ((0, math_1.isValidInteger)(integer)) { return integer; @@ -7691,6 +7715,30 @@ class ToInteger extends expression_1.Expression { } } exports.ToInteger = ToInteger; +class ToLong extends expression_1.Expression { + constructor(json) { + super(json); + } + async exec(ctx) { + const arg = await this.execArgs(ctx); + if (typeof arg === 'number') { + if ((0, math_1.isValidLong)(arg)) { + return arg; + } + } + else if (typeof arg === 'string') { + const long = parseInt(arg); + if ((0, math_1.isValidLong)(long)) { + return long; + } + } + else if (typeof arg === 'boolean') { + return arg ? 1 : 0; + } + return null; + } +} +exports.ToLong = ToLong; class ToQuantity extends expression_1.Expression { constructor(json) { super(json); @@ -8490,6 +8538,7 @@ class Context { case '{urn:hl7-org:elm-types:r1}Decimal': return typeof val === 'number'; case '{urn:hl7-org:elm-types:r1}Integer': + case '{urn:hl7-org:elm-types:r1}Long': return typeof val === 'number' && Math.floor(val) === val; case '{urn:hl7-org:elm-types:r1}String': return typeof val === 'string'; @@ -8538,6 +8587,9 @@ class Context { else if (inst.isIntegerLiteral) { return typeof val === 'number' && Math.floor(val) === val; } + else if (inst.isLongLiteral) { + return typeof val === 'number' && Math.floor(val) === val; + } else if (inst.isStringLiteral) { return typeof val === 'string'; } @@ -9294,9 +9346,10 @@ exports.toNormalizedKey = toNormalizedKey; },{"../datatypes/datatypes":6,"./math":55,"./units":56,"@lhncbc/ucum-lhc":68,"immutable":72}],55:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.OverFlowException = exports.MAX_TIME_VALUE = exports.MIN_TIME_VALUE = exports.MAX_DATE_VALUE = exports.MIN_DATE_VALUE = exports.MAX_DATETIME_VALUE = exports.MIN_DATETIME_VALUE = exports.MIN_FLOAT_PRECISION_VALUE = exports.MIN_FLOAT_VALUE = exports.MAX_FLOAT_VALUE = exports.MIN_INT_VALUE = exports.MAX_INT_VALUE = void 0; +exports.OverFlowException = exports.MAX_TIME_VALUE = exports.MIN_TIME_VALUE = exports.MAX_DATE_VALUE = exports.MIN_DATE_VALUE = exports.MAX_DATETIME_VALUE = exports.MIN_DATETIME_VALUE = exports.MIN_FLOAT_PRECISION_VALUE = exports.MIN_FLOAT_VALUE = exports.MAX_FLOAT_VALUE = exports.MIN_LONG_VALUE = exports.MAX_LONG_VALUE = exports.MIN_INT_VALUE = exports.MAX_INT_VALUE = void 0; exports.overflowsOrUnderflows = overflowsOrUnderflows; exports.isValidInteger = isValidInteger; +exports.isValidLong = isValidLong; exports.isValidDecimal = isValidDecimal; exports.limitDecimalPrecision = limitDecimalPrecision; exports.successor = successor; @@ -9312,6 +9365,8 @@ const datetime_1 = require("../datatypes/datetime"); const uncertainty_1 = require("../datatypes/uncertainty"); exports.MAX_INT_VALUE = Math.pow(2, 31) - 1; exports.MIN_INT_VALUE = Math.pow(-2, 31); +exports.MAX_LONG_VALUE = Math.pow(2, 63) - 1; +exports.MIN_LONG_VALUE = Math.pow(-2, 63); exports.MAX_FLOAT_VALUE = 99999999999999999999.99999999; exports.MIN_FLOAT_VALUE = -99999999999999999999.99999999; exports.MIN_FLOAT_PRECISION_VALUE = Math.pow(10, -8); @@ -9355,6 +9410,7 @@ function overflowsOrUnderflows(value) { } } else if (Number.isInteger(value)) { + // TODO: Somehow distinguish Integer from Long if (!isValidInteger(value)) { return true; } @@ -9381,6 +9437,18 @@ function isValidInteger(integer) { } return true; } +function isValidLong(long) { + if (isNaN(long)) { + return false; + } + if (long > exports.MAX_LONG_VALUE) { + return false; + } + if (long < exports.MIN_LONG_VALUE) { + return false; + } + return true; +} function isValidDecimal(decimal) { if (isNaN(decimal)) { return false; @@ -9414,6 +9482,7 @@ exports.OverFlowException = OverFlowException; function successor(val) { if (typeof val === 'number') { if (Number.isInteger(val)) { + // TODO: Somehow distinguish Integer from Long if (val >= exports.MAX_INT_VALUE) { throw new OverFlowException(); } @@ -9478,6 +9547,7 @@ function successor(val) { function predecessor(val) { if (typeof val === 'number') { if (Number.isInteger(val)) { + // TODO: Somehow distinguish Integer from Long if (val <= exports.MIN_INT_VALUE) { throw new OverFlowException(); } @@ -9541,6 +9611,7 @@ function predecessor(val) { } function maxValueForInstance(val) { if (typeof val === 'number') { + // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return exports.MAX_INT_VALUE; } @@ -9570,6 +9641,8 @@ function maxValueForType(type, quantityInstance) { switch (type) { case '{urn:hl7-org:elm-types:r1}Integer': return exports.MAX_INT_VALUE; + case '{urn:hl7-org:elm-types:r1}Long': + return exports.MAX_LONG_VALUE; case '{urn:hl7-org:elm-types:r1}Decimal': return exports.MAX_FLOAT_VALUE; case '{urn:hl7-org:elm-types:r1}DateTime': @@ -9592,6 +9665,7 @@ function maxValueForType(type, quantityInstance) { } function minValueForInstance(val) { if (typeof val === 'number') { + // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return exports.MIN_INT_VALUE; } @@ -9621,6 +9695,8 @@ function minValueForType(type, quantityInstance) { switch (type) { case '{urn:hl7-org:elm-types:r1}Integer': return exports.MIN_INT_VALUE; + case '{urn:hl7-org:elm-types:r1}Long': + return exports.MIN_LONG_VALUE; case '{urn:hl7-org:elm-types:r1}Decimal': return exports.MIN_FLOAT_VALUE; case '{urn:hl7-org:elm-types:r1}DateTime': diff --git a/src/elm/arithmetic.ts b/src/elm/arithmetic.ts index f962e2b74..352d53787 100644 --- a/src/elm/arithmetic.ts +++ b/src/elm/arithmetic.ts @@ -383,6 +383,7 @@ export class Power extends Expression { export class MinValue extends Expression { static readonly MIN_VALUES = { '{urn:hl7-org:elm-types:r1}Integer': MathUtil.MIN_INT_VALUE, + '{urn:hl7-org:elm-types:r1}Long': MathUtil.MIN_LONG_VALUE, '{urn:hl7-org:elm-types:r1}Decimal': MathUtil.MIN_FLOAT_VALUE, '{urn:hl7-org:elm-types:r1}DateTime': MathUtil.MIN_DATETIME_VALUE, '{urn:hl7-org:elm-types:r1}Date': MathUtil.MIN_DATE_VALUE, @@ -414,6 +415,7 @@ export class MinValue extends Expression { export class MaxValue extends Expression { static readonly MAX_VALUES = { '{urn:hl7-org:elm-types:r1}Integer': MathUtil.MAX_INT_VALUE, + '{urn:hl7-org:elm-types:r1}Long': MathUtil.MAX_LONG_VALUE, '{urn:hl7-org:elm-types:r1}Decimal': MathUtil.MAX_FLOAT_VALUE, '{urn:hl7-org:elm-types:r1}DateTime': MathUtil.MAX_DATETIME_VALUE, '{urn:hl7-org:elm-types:r1}Date': MathUtil.MAX_DATE_VALUE, diff --git a/src/elm/literal.ts b/src/elm/literal.ts index e49bdc87f..badaf09dd 100644 --- a/src/elm/literal.ts +++ b/src/elm/literal.ts @@ -11,6 +11,8 @@ export class Literal extends Expression { return new BooleanLiteral(json); case '{urn:hl7-org:elm-types:r1}Integer': return new IntegerLiteral(json); + case '{urn:hl7-org:elm-types:r1}Long': + return new LongLiteral(json); case '{urn:hl7-org:elm-types:r1}Decimal': return new DecimalLiteral(json); case '{urn:hl7-org:elm-types:r1}String': @@ -67,6 +69,23 @@ export class IntegerLiteral extends Literal { } } +export class LongLiteral extends Literal { + constructor(json: any) { + super(json); + this.value = parseInt(this.value, 10); + } + + // Define a simple getter to allow type-checking of this class without instanceof + // and in a way that survives minification (as opposed to checking constructor.name) + get isLongLiteral() { + return true; + } + + async exec(_ctx: Context) { + return this.value; + } +} + export class DecimalLiteral extends Literal { constructor(json: any) { super(json); diff --git a/src/elm/type.ts b/src/elm/type.ts index e7a2822a7..4ff5b78e5 100644 --- a/src/elm/type.ts +++ b/src/elm/type.ts @@ -4,7 +4,7 @@ import { Expression, UnimplementedExpression } from './expression'; import { DateTime, Date } from '../datatypes/datetime'; import { Concept } from '../datatypes/clinical'; import { Quantity, parseQuantity } from '../datatypes/quantity'; -import { isValidDecimal, isValidInteger, limitDecimalPrecision } from '../util/math'; +import { isValidDecimal, isValidInteger, isValidLong, limitDecimalPrecision } from '../util/math'; import { normalizeMillisecondsField } from '../util/util'; import { Ratio } from '../datatypes/ratio'; import { Uncertainty } from '../datatypes/uncertainty'; @@ -147,7 +147,11 @@ export class ToInteger extends Expression { async exec(ctx: Context) { const arg = await this.execArgs(ctx); - if (typeof arg === 'string') { + if (typeof arg === 'number') { + if (isValidInteger(arg)) { + return arg; + } + } else if (typeof arg === 'string') { const integer = parseInt(arg); if (isValidInteger(integer)) { return integer; @@ -159,6 +163,29 @@ export class ToInteger extends Expression { } } +export class ToLong extends Expression { + constructor(json: any) { + super(json); + } + + async exec(ctx: Context) { + const arg = await this.execArgs(ctx); + if (typeof arg === 'number') { + if (isValidLong(arg)) { + return arg; + } + } else if (typeof arg === 'string') { + const long = parseInt(arg); + if (isValidLong(long)) { + return long; + } + } else if (typeof arg === 'boolean') { + return arg ? 1 : 0; + } + return null; + } +} + export class ToQuantity extends Expression { constructor(json: any) { super(json); diff --git a/src/runtime/context.ts b/src/runtime/context.ts index fff16b6bb..96a39e1d6 100644 --- a/src/runtime/context.ts +++ b/src/runtime/context.ts @@ -326,6 +326,7 @@ export class Context { case '{urn:hl7-org:elm-types:r1}Decimal': return typeof val === 'number'; case '{urn:hl7-org:elm-types:r1}Integer': + case '{urn:hl7-org:elm-types:r1}Long': return typeof val === 'number' && Math.floor(val) === val; case '{urn:hl7-org:elm-types:r1}String': return typeof val === 'string'; @@ -372,6 +373,8 @@ export class Context { return typeof val === 'number'; } else if (inst.isIntegerLiteral) { return typeof val === 'number' && Math.floor(val) === val; + } else if (inst.isLongLiteral) { + return typeof val === 'number' && Math.floor(val) === val; } else if (inst.isStringLiteral) { return typeof val === 'string'; } else if (inst.isCode) { diff --git a/src/util/math.ts b/src/util/math.ts index 5ecb9b84e..c2c9e8b49 100644 --- a/src/util/math.ts +++ b/src/util/math.ts @@ -12,6 +12,8 @@ import { Uncertainty } from '../datatypes/uncertainty'; export const MAX_INT_VALUE = Math.pow(2, 31) - 1; export const MIN_INT_VALUE = Math.pow(-2, 31); +export const MAX_LONG_VALUE = Math.pow(2, 63) - 1; +export const MIN_LONG_VALUE = Math.pow(-2, 63); export const MAX_FLOAT_VALUE = 99999999999999999999.99999999; export const MIN_FLOAT_VALUE = -99999999999999999999.99999999; export const MIN_FLOAT_PRECISION_VALUE = Math.pow(10, -8); @@ -52,6 +54,7 @@ export function overflowsOrUnderflows(value: any): boolean { return true; } } else if (Number.isInteger(value)) { + // TODO: Somehow distinguish Integer from Long if (!isValidInteger(value)) { return true; } @@ -78,6 +81,19 @@ export function isValidInteger(integer: any) { return true; } +export function isValidLong(long: any) { + if (isNaN(long)) { + return false; + } + if (long > MAX_LONG_VALUE) { + return false; + } + if (long < MIN_LONG_VALUE) { + return false; + } + return true; +} + export function isValidDecimal(decimal: any) { if (isNaN(decimal)) { return false; @@ -113,6 +129,7 @@ export class OverFlowException extends Exception {} export function successor(val: any): any { if (typeof val === 'number') { if (Number.isInteger(val)) { + // TODO: Somehow distinguish Integer from Long if (val >= MAX_INT_VALUE) { throw new OverFlowException(); } else { @@ -165,6 +182,7 @@ export function successor(val: any): any { export function predecessor(val: any): any { if (typeof val === 'number') { if (Number.isInteger(val)) { + // TODO: Somehow distinguish Integer from Long if (val <= MIN_INT_VALUE) { throw new OverFlowException(); } else { @@ -216,6 +234,7 @@ export function predecessor(val: any): any { export function maxValueForInstance(val: any) { if (typeof val === 'number') { + // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return MAX_INT_VALUE; } else { @@ -240,6 +259,8 @@ export function maxValueForType(type: string, quantityInstance?: Quantity) { switch (type) { case '{urn:hl7-org:elm-types:r1}Integer': return MAX_INT_VALUE; + case '{urn:hl7-org:elm-types:r1}Long': + return MAX_LONG_VALUE; case '{urn:hl7-org:elm-types:r1}Decimal': return MAX_FLOAT_VALUE; case '{urn:hl7-org:elm-types:r1}DateTime': @@ -263,6 +284,7 @@ export function maxValueForType(type: string, quantityInstance?: Quantity) { export function minValueForInstance(val: any) { if (typeof val === 'number') { + // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return MIN_INT_VALUE; } else { @@ -287,6 +309,8 @@ export function minValueForType(type: string, quantityInstance?: Quantity) { switch (type) { case '{urn:hl7-org:elm-types:r1}Integer': return MIN_INT_VALUE; + case '{urn:hl7-org:elm-types:r1}Long': + return MIN_LONG_VALUE; case '{urn:hl7-org:elm-types:r1}Decimal': return MIN_FLOAT_VALUE; case '{urn:hl7-org:elm-types:r1}DateTime': diff --git a/test/elm/arithmetic/arithmetic-test.ts b/test/elm/arithmetic/arithmetic-test.ts index 63dc0d51a..66f9ee81d 100644 --- a/test/elm/arithmetic/arithmetic-test.ts +++ b/test/elm/arithmetic/arithmetic-test.ts @@ -8,6 +8,22 @@ import { Quantity } from '../../../src/datatypes/quantity'; import setup from '../../setup'; +import { + MAX_FLOAT_VALUE, + MAX_INT_VALUE, + MAX_LONG_VALUE, + MIN_FLOAT_VALUE, + MIN_INT_VALUE, + MIN_LONG_VALUE +} from '../../../src/util/math'; +import { + MAX_DATE_VALUE, + MAX_DATETIME_VALUE, + MAX_TIME_VALUE, + MIN_DATE_VALUE, + MIN_DATETIME_VALUE, + MIN_TIME_VALUE +} from '../../../src/datatypes/datetime'; const data = require('./data'); @@ -59,6 +75,10 @@ describe('Add', () => { (await this.addVariables.exec(this.ctx)).should.equal(21); }); + it('should add two short longs', async function () { + (await this.onePlusTwoLong.exec(this.ctx)).should.equal(3); + }); + it('should add Time/Quantity', async function () { (await this.addTime.exec(this.ctx)).isTime().should.be.true(); }); @@ -99,6 +119,10 @@ describe('Subtract', () => { (await this.subtractVariables.exec(this.ctx)).should.equal(1); }); + it('should subtract two longs', async function () { + (await this.fiveMinusTwoLong.exec(this.ctx)).should.equal(3); + }); + it('should subtract uncertainty from uncertainty', async function () { const result = await this.subtractUncertainties.exec(this.ctx); result.low.should.equal(-6); @@ -135,6 +159,10 @@ describe('Multiply', () => { (await this.multiplyVariables.exec(this.ctx)).should.equal(110); }); + it('should multiply two longs', async function () { + (await this.fiveTimesTwoLong.exec(this.ctx)).should.equal(10); + }); + it('should multiply uncertainty and uncertainty', async function () { const result = await this.multiplyUncertainties.exec(this.ctx); result.low.should.equal(12); @@ -175,6 +203,10 @@ describe('Divide', () => { (await this.divideVariables.exec(this.ctx)).should.equal(25); }); + it('should divide two longs', async function () { + (await this.tenDividedByTwoLong.exec(this.ctx)).should.equal(5); + }); + it('should divide uncertainty by uncertainty', async function () { const result = await this.divideUncertainties.exec(this.ctx); result.low.should.equal(6 / 14); @@ -202,6 +234,10 @@ describe('Negate', () => { it('should negate a number', async function () { (await this.negativeOne.exec(this.ctx)).should.equal(-1); }); + + it('should negate a long', async function () { + (await this.negativeOneLong.exec(this.ctx)).should.equal(-1); + }); }); describe('MathPrecedence', () => { @@ -226,6 +262,10 @@ describe('Power', () => { it('should be able to calculate the power of a number', async function () { (await this.pow.exec(this.ctx)).should.equal(81); }); + + it('should be able to calculate the power of a long', async function () { + (await this.threeExpFourLong.exec(this.ctx)).should.equal(81); + }); }); describe('MinValue', () => { @@ -235,12 +275,40 @@ describe('MinValue', () => { it('of Integer should return minimum representable Integer value', async function () { const minIntegerValue = -2147483648; - (await this.minInteger.exec(this.ctx)).should.equal(minIntegerValue); + const minIntegerStringValue = '-2147483648'; + const minIntegerResult = await this.minInteger.exec(this.ctx); + minIntegerResult.should.equal(minIntegerValue); + String(minIntegerResult).should.equal(minIntegerStringValue); }); - it('of Decimal should return minimum representable Decimal value', async function () { + // JS number doesn't handle limits of Long precisely, but this ensures we are in the ballpark + it('of Long should return approximate minimum representable Long value', async function () { + const minLongResult = await this.minLong.exec(this.ctx); + minLongResult.should.be.aboveOrEqual(-9223372036854776000); + minLongResult.should.be.belowOrEqual(-9223372036854775000); + }); + + it.skip('of Long should return exact minimum representable Long value', async function () { + const minLongValue = -9223372036854775808; + const minLongStringValue = '-9223372036854775808'; + const minLongResult = await this.minLong.exec(this.ctx); + minLongResult.should.equal(minLongValue); + String(minLongResult).should.equal(minLongStringValue); + }); + + // JS number doesn't handle limits of decimal precisely, but this ensures we are in the ballpark + it('of Decimal should return approximate minimum representable Decimal value', async function () { + const minDecimalValue = -99999999999999999999.99999999; + const minDecimalResult = await this.minDecimal.exec(this.ctx); + minDecimalResult.should.be.approximately(minDecimalValue, 0.000000001); + }); + + it.skip('of Decimal should return exact minimum representable Decimal value', async function () { const minDecimalValue = -99999999999999999999.99999999; - (await this.minDecimal.exec(this.ctx)).should.be.approximately(minDecimalValue, 0.000000001); + const minDecimalStringValue = '-99999999999999999999.99999999'; + const minDecimalResult = await this.minDecimal.exec(this.ctx); + minDecimalResult.should.equal(minDecimalValue); + String(minDecimalResult).should.equal(minDecimalStringValue); }); it('of DateTime should return minimum representable DateTime value', async function () { @@ -274,12 +342,40 @@ describe('MaxValue', () => { it('of Integer should return maximum representable Integer value', async function () { const maxIntegerValue = 2147483647; - (await this.maxInteger.exec(this.ctx)).should.equal(maxIntegerValue); + const maxIntegerStringValue = '2147483647'; + const maxIntegerResult = await this.maxInteger.exec(this.ctx); + maxIntegerResult.should.equal(maxIntegerValue); + String(maxIntegerResult).should.equal(maxIntegerStringValue); + }); + + // JS number doesn't handle limits of Long precisely, but this ensures we are in the ballpark + it('of Long should return approximate maximum representable Long value', async function () { + const maxLongResult = await this.maxLong.exec(this.ctx); + maxLongResult.should.be.aboveOrEqual(9223372036854775000); + maxLongResult.should.be.belowOrEqual(9223372036854776000); + }); + + it.skip('of Long should return exact maximum representable Long value', async function () { + const maxLongValue = 9223372036854775807; + const maxLongStringValue = '9223372036854775807'; + const maxLongResult = await this.maxLong.exec(this.ctx); + maxLongResult.should.equal(maxLongValue); + String(maxLongResult).should.equal(maxLongStringValue); + }); + + // JS number doesn't handle limits of decimal precisely, but this ensures we are in the ballpark + it('of Decimal should return approximate maximum representable Decimal value', async function () { + const maxDecimalValue = 99999999999999999999.99999999; + const maxDecimalResult = await this.maxDecimal.exec(this.ctx); + maxDecimalResult.should.be.approximately(maxDecimalValue, 0.000000001); }); - it('of Decimal should return maximum representable Decimal value', async function () { + it.skip('of Decimal should return exact maximum representable Decimal value', async function () { const maxDecimalValue = 99999999999999999999.99999999; - (await this.maxDecimal.exec(this.ctx)).should.be.approximately(maxDecimalValue, 0.000000001); + const maxDecimalStringValue = '99999999999999999999.99999999'; + const maxDecimalResult = await this.maxDecimal.exec(this.ctx); + maxDecimalResult.should.equal(maxDecimalValue, 0.000000001); + String(maxDecimalResult).should.equal(maxDecimalStringValue); }); it('of DateTime should return maximum representable DateTime value', async function () { @@ -328,6 +424,10 @@ describe('TruncatedDivide', () => { (await this.trunc.exec(this.ctx)).should.equal(3); (await this.even.exec(this.ctx)).should.equal(3); }); + + it('should be able to return just the long portion of a division', async function () { + (await this.tenDivThreeLong.exec(this.ctx)).should.equal(3); + }); }); describe('Truncate', () => { @@ -339,6 +439,10 @@ describe('Truncate', () => { (await this.trunc.exec(this.ctx)).should.equal(10); (await this.even.exec(this.ctx)).should.equal(10); }); + + it('should be able to return the long portion of a number', async function () { + (await this.truncTenLong.exec(this.ctx)).should.equal(10); + }); }); describe('Floor', () => { @@ -349,6 +453,8 @@ describe('Floor', () => { it('should be able to round down to the closest integer', async function () { (await this.flr.exec(this.ctx)).should.equal(10); (await this.even.exec(this.ctx)).should.equal(10); + // NOTE: Floor returns an Integer (not specified to return a Long) + (await this.floorTenLong.exec(this.ctx)).should.equal(10); }); }); @@ -360,6 +466,8 @@ describe('Ceiling', () => { it('should be able to round up to the closest integer', async function () { (await this.ceil.exec(this.ctx)).should.equal(11); (await this.even.exec(this.ctx)).should.equal(10); + // Note: Ceiling returns an Integer (not specified to return a Long) + (await this.ceilTenLong.exec(this.ctx)).should.equal(10); }); }); @@ -371,6 +479,10 @@ describe('Ln', () => { it('should be able to return the natural log of a number', async function () { (await this.ln.exec(this.ctx)).should.equal(Math.log(4)); }); + + it('should be able to return the natural log of a long', async function () { + (await this.lnFourLong.exec(this.ctx)).should.equal(Math.log(4)); + }); }); describe('Log', () => { @@ -381,6 +493,10 @@ describe('Log', () => { it('should be able to return the log of a number based on an arbitrary base value', async function () { (await this.log.exec(this.ctx)).should.equal(0.25); }); + + it('should be able to return the log of a long based on an arbitrary base value', async function () { + (await this.logLong.exec(this.ctx)).should.equal(0.25); + }); }); describe('Modulo', () => { @@ -391,6 +507,10 @@ describe('Modulo', () => { it('should be able to return the remainder of a division', async function () { (await this.mod.exec(this.ctx)).should.equal(1); }); + + it('should be able to return the long remainder of a division', async function () { + (await this.threeModTwoLong.exec(this.ctx)).should.equal(1); + }); }); describe('Abs', () => { @@ -407,6 +527,9 @@ describe('Abs', () => { it('should be able to return the absolute value of 0', async function () { (await this.zero.exec(this.ctx)).should.equal(0); }); + it('should be able to return the absolute value of a negative long', async function () { + (await this.absNegTenLong.exec(this.ctx)).should.equal(10); + }); }); describe('Round', () => { @@ -432,6 +555,11 @@ describe('Successor', () => { it('should be able to get Integer Successor', async function () { (await this.is.exec(this.ctx)).should.equal(3); }); + + it('should be able to get Long Successor', async function () { + (await this.ls.exec(this.ctx)).should.equal(3); + }); + it('should be able to get Real Successor', async function () { (await this.rs.exec(this.ctx)).should.equal(2.2 + Math.pow(10, -8)); }); @@ -530,9 +658,15 @@ describe('Predecessor', () => { it('should be able to get Integer Predecessor', async function () { (await this.is.exec(this.ctx)).should.equal(1); }); + + it('should be able to get Long Predecessor', async function () { + (await this.ls.exec(this.ctx)).should.equal(1); + }); + it('should be able to get Real Predecessor', async function () { (await this.rs.exec(this.ctx)).should.equal(2.2 - Math.pow(10, -8)); }); + it('should return null for Predecessor greater than Integer Max value', async function () { should(await this.ufr.exec(this.ctx)).be.null(); }); @@ -739,6 +873,14 @@ describe('OutOfBounds', () => { should(await this.integerAddUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Add near overflow', async function () { + should(await this.integerAddNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); + }); + + it('should return value for Add near underflow', async function () { + should(await this.integerAddNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); + }); + it('should return null for Subtract overflow', async function () { should(await this.integerSubtractOverflow.exec(this.ctx)).be.null(); }); @@ -747,6 +889,14 @@ describe('OutOfBounds', () => { should(await this.integerSubtractUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Subtract near overflow', async function () { + should(await this.integerSubtractNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); + }); + + it('should return value for Subtract near underflow', async function () { + should(await this.integerSubtractNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); + }); + it('should return null for Multiply overflow', async function () { should(await this.integerMultiplyOverflow.exec(this.ctx)).be.null(); }); @@ -755,6 +905,14 @@ describe('OutOfBounds', () => { should(await this.integerMultiplyUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Multiply near overflow', async function () { + should(await this.integerMultiplyNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); + }); + + it('should return value for Multiply near underflow', async function () { + should(await this.integerMultiplyNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); + }); + it('should return null for Divide overflow', async function () { should(await this.integerDivideOverflow.exec(this.ctx)).be.null(); }); @@ -763,6 +921,14 @@ describe('OutOfBounds', () => { should(await this.integerDivideUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Divide near overflow', async function () { + should(await this.integerDivideNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); + }); + + it('should return value for Divide near underflow', async function () { + should(await this.integerDivideNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); + }); + it('should return null for Divide By Zero', async function () { should(await this.integerDivideByZero.exec(this.ctx)).be.null(); }); @@ -775,6 +941,14 @@ describe('OutOfBounds', () => { should(await this.integerPowerUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Power near overflow', async function () { + should(await this.integerPowerNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); + }); + + it('should return value for Power near underflow', async function () { + should(await this.integerPowerNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); + }); + it('should return null for successor overflow', async function () { should(await this.integerSuccessorOverflow.exec(this.ctx)).be.null(); }); @@ -782,6 +956,118 @@ describe('OutOfBounds', () => { it('should return null for predecessor underflow', async function () { should(await this.integerPredecessorUnderflow.exec(this.ctx)).be.null(); }); + + it('should return value for successor near overflow', async function () { + should(await this.integerSuccessorNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); + }); + + it('should return null for predecessor near underflow', async function () { + should(await this.integerPredecessorNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); + }); + }); + + describe('Long', () => { + it('should return null for Add overflow', async function () { + should(await this.longAddOverflow.exec(this.ctx)).be.null(); + }); + + it('should return null for Add underflow', async function () { + should(await this.longAddUnderflow.exec(this.ctx)).be.null(); + }); + + // skipping this and other long tests because logic can't distinguish between integer and long + // so it doesn't know when to overflow (and currently defaults to integer overflows) + it.skip('should return value for Add near overflow', async function () { + should(await this.longAddNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + }); + + it.skip('should return value for Add near underflow', async function () { + should(await this.longAddNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + }); + + it('should return null for Subtract overflow', async function () { + should(await this.longSubtractOverflow.exec(this.ctx)).be.null(); + }); + + it('should return null for Subtract underflow', async function () { + should(await this.longSubtractUnderflow.exec(this.ctx)).be.null(); + }); + + it.skip('should return value for Subtract near overflow', async function () { + should(await this.longSubtractNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + }); + + it.skip('should return value for Subtract near underflow', async function () { + should(await this.longSubtractNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + }); + + it('should return null for Multiply overflow', async function () { + should(await this.longMultiplyOverflow.exec(this.ctx)).be.null(); + }); + + it('should return null for Multiply underflow', async function () { + should(await this.longMultiplyUnderflow.exec(this.ctx)).be.null(); + }); + + it.skip('should return value for Multiply near overflow', async function () { + should(await this.longMultiplyNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + }); + + it.skip('should return value for Multiply near underflow', async function () { + should(await this.longMultiplyNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + }); + + it('should return null for Divide overflow', async function () { + should(await this.longDivideOverflow.exec(this.ctx)).be.null(); + }); + + it('should return null for Divide underflow', async function () { + should(await this.longDivideUnderflow.exec(this.ctx)).be.null(); + }); + + it.skip('should return value for Divide near overflow', async function () { + should(await this.longDivideNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + }); + + it.skip('should return value for Divide near underflow', async function () { + should(await this.longDivideNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + }); + + it('should return null for Divide By Zero', async function () { + should(await this.longDivideByZero.exec(this.ctx)).be.null(); + }); + + it('should return null for Power overflow', async function () { + should(await this.longPowerOverflow.exec(this.ctx)).be.null(); + }); + + it('should return null for Power underflow', async function () { + should(await this.longPowerUnderflow.exec(this.ctx)).be.null(); + }); + + it.skip('should return value for Power near overflow', async function () { + should(await this.longPowerNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + }); + + it.skip('should return value for Power near underflow', async function () { + should(await this.longPowerNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + }); + + it('should return null for successor overflow', async function () { + should(await this.longSuccessorOverflow.exec(this.ctx)).be.null(); + }); + + it('should return null for predecessor underflow', async function () { + should(await this.longPredecessorUnderflow.exec(this.ctx)).be.null(); + }); + + it.skip('should return value for successor near overflow', async function () { + should(await this.longSuccessorNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + }); + + it.skip('should return value for predecessor near underflow', async function () { + should(await this.longPredecessorNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + }); }); describe('Decimal', () => { @@ -793,6 +1079,16 @@ describe('OutOfBounds', () => { should(await this.decimalAddUnderflow.exec(this.ctx)).be.null(); }); + // skipping this and other decimal tests because javascript floats are imprecise + // at CQL's defined min/max for decimal, so near over/underflow still over/underflows + it.skip('should return value for Add near overflow', async function () { + should(await this.decimalAddNearOverflow.exec(this.ctx)).equal(MAX_FLOAT_VALUE); + }); + + it.skip('should return value for Add near underflow', async function () { + should(await this.decimalAddNearUnderflow.exec(this.ctx)).equal(MIN_FLOAT_VALUE); + }); + it('should return null for Subtract overflow', async function () { should(await this.decimalSubtractOverflow.exec(this.ctx)).be.null(); }); @@ -801,6 +1097,14 @@ describe('OutOfBounds', () => { should(await this.decimalSubtractUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Subtract near overflow', async function () { + should(await this.decimalSubtractNearOverflow.exec(this.ctx)).equal(MAX_FLOAT_VALUE); + }); + + it.skip('should return value for Subtract near underflow', async function () { + should(await this.decimalSubtractNearUnderflow.exec(this.ctx)).equal(MIN_FLOAT_VALUE); + }); + it('should return null for Multiply overflow', async function () { should(await this.decimalMultiplyOverflow.exec(this.ctx)).be.null(); }); @@ -809,6 +1113,14 @@ describe('OutOfBounds', () => { should(await this.decimalMultiplyUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Multiply near overflow', async function () { + should(await this.decimalMultiplyNearOverflow.exec(this.ctx)).equal(MAX_FLOAT_VALUE); + }); + + it.skip('should return value for Multiply near underflow', async function () { + should(await this.decimalMultiplyNearUnderflow.exec(this.ctx)).equal(MIN_FLOAT_VALUE); + }); + it('should return null for Divide overflow', async function () { should(await this.decimalDivideOverflow.exec(this.ctx)).be.null(); }); @@ -817,6 +1129,14 @@ describe('OutOfBounds', () => { should(await this.decimalDivideUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Divide near overflow', async function () { + should(await this.decimalDivideNearOverflow.exec(this.ctx)).equal(MAX_FLOAT_VALUE); + }); + + it.skip('should return value for Divide near underflow', async function () { + should(await this.decimalDivideNearUnderflow.exec(this.ctx)).equal(MIN_FLOAT_VALUE); + }); + it('should return null for Divide By Zero', async function () { should(await this.decimalDivideByZero.exec(this.ctx)).be.null(); }); @@ -829,6 +1149,14 @@ describe('OutOfBounds', () => { should(await this.decimalPowerUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Power near overflow', async function () { + should(await this.decimalPowerNearOverflow.exec(this.ctx)).equal(MAX_FLOAT_VALUE); + }); + + it.skip('should return value for Power near underflow', async function () { + should(await this.decimalPowerNearUnderflow.exec(this.ctx)).equal(MIN_FLOAT_VALUE); + }); + it('should return null for successor overflow', async function () { should(await this.decimalSuccessorOverflow.exec(this.ctx)).be.null(); }); @@ -836,6 +1164,14 @@ describe('OutOfBounds', () => { it('should return null for predecessor underflow', async function () { should(await this.decimalPredecessorUnderflow.exec(this.ctx)).be.null(); }); + + it.skip('should return value for successor near overflow', async function () { + should(await this.decimalSuccessorNearOverflow.exec(this.ctx)).equal(MAX_FLOAT_VALUE); + }); + + it.skip('should return value for predecessor near underflow', async function () { + should(await this.decimalPredecessorNearUnderflow.exec(this.ctx)).equal(MIN_FLOAT_VALUE); + }); }); describe('Quantity', () => { @@ -847,6 +1183,20 @@ describe('OutOfBounds', () => { should(await this.quantityAddUnderflow.exec(this.ctx)).be.null(); }); + // skipping this and other quantity tests because javascript floats are imprecise + // at CQL's defined min/max for decimal, so near over/underflow still over/underflows + it.skip('should return value for Add near overflow', async function () { + const result = await this.quantityAddNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MAX_FLOAT_VALUE, 'mm'); + }); + + it.skip('should return value for Add near underflow', async function () { + const result = await this.quantityAddNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MIN_FLOAT_VALUE, 'mm'); + }); + it('should return null for Subtract overflow', async function () { should(await this.quantitySubtractOverflow.exec(this.ctx)).be.null(); }); @@ -855,6 +1205,18 @@ describe('OutOfBounds', () => { should(await this.quantitySubtractUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Subtract near overflow', async function () { + const result = await this.quantitySubtractNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MAX_FLOAT_VALUE, 'mm'); + }); + + it.skip('should return value for Subtract near underflow', async function () { + const result = await this.quantitySubtractNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MIN_FLOAT_VALUE, 'mm'); + }); + it('should return null for Multiply overflow', async function () { should(await this.quantityMultiplyOverflow.exec(this.ctx)).be.null(); }); @@ -863,6 +1225,18 @@ describe('OutOfBounds', () => { should(await this.quantityMultiplyUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Multiply near overflow', async function () { + const result = await this.quantityMultiplyNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MAX_FLOAT_VALUE, 'mm'); + }); + + it.skip('should return value for Multiply near underflow', async function () { + const result = await this.quantityMultiplyNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MIN_FLOAT_VALUE, 'mm'); + }); + it('should return null for Divide overflow', async function () { should(await this.quantityDivideOverflow.exec(this.ctx)).be.null(); }); @@ -871,6 +1245,18 @@ describe('OutOfBounds', () => { should(await this.quantityDivideUnderflow.exec(this.ctx)).be.null(); }); + it.skip('should return value for Divide near overflow', async function () { + const result = await this.quantityDivideNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MAX_FLOAT_VALUE, 'mm'); + }); + + it.skip('should return value for Divide near underflow', async function () { + const result = await this.quantityDivideNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MIN_FLOAT_VALUE, 'mm'); + }); + it('should return null for Divide By Zero', async function () { should(await this.quantityDivideByZero.exec(this.ctx)).be.null(); }); @@ -882,6 +1268,18 @@ describe('OutOfBounds', () => { it('should return null for predecessor underflow', async function () { should(await this.quantityPredecessorUnderflow.exec(this.ctx)).be.null(); }); + + it.skip('should return value for successor near overflow', async function () { + const result = await this.quantitySuccessorNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MAX_FLOAT_VALUE, 'mm'); + }); + + it.skip('should return value for predecessor near underflow', async function () { + const result = await this.quantitPpredecessorNearOverflow.exec(this.ctx); + should(result).not.be.null(); + validateQuantity(result, MIN_FLOAT_VALUE, 'mm'); + }); }); describe('DateTime', () => { @@ -889,24 +1287,34 @@ describe('OutOfBounds', () => { should(await this.dateTimeAddOverflow.exec(this.ctx)).be.null(); }); - // TODO: Fix the logic so this test passes. It's been broken for a long time, but due to a - // faulty test, this was not noticed until now. The cause of the failure is not obvious, so - // this should be revisited (but is lower priority since it's an extremely rare use case). - it.skip('should return null for Add underflow', async function () { + it('should return null for Add underflow', async function () { should(await this.dateTimeAddUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Add near overflow', async function () { + should(await this.dateTimeAddNearOverflow.exec(this.ctx)).eql(MAX_DATETIME_VALUE); + }); + + it('should return value for Add near underflow', async function () { + should(await this.dateTimeAddNearUnderflow.exec(this.ctx)).eql(MIN_DATETIME_VALUE); + }); + it('should return null for Subtract overflow', async function () { should(await this.dateTimeSubtractOverflow.exec(this.ctx)).be.null(); }); - // TODO: Fix the logic so this test passes. It's been broken for a long time, but due to a - // faulty test, this was not noticed until now. The cause of the failure is not obvious, so - // this should be revisited (but is lower priority since it's an extremely rare use case). - it.skip('should return null for Subtract underflow', async function () { + it('should return null for Subtract underflow', async function () { should(await this.dateTimeSubtractUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Subtract near overflow', async function () { + should(await this.dateTimeSubtractNearOverflow.exec(this.ctx)).eql(MAX_DATETIME_VALUE); + }); + + it('should return value for Subtract near underflow', async function () { + should(await this.dateTimeSubtractNearUnderflow.exec(this.ctx)).eql(MIN_DATETIME_VALUE); + }); + it('should return null for successor overflow', async function () { should(await this.dateTimeSuccessorOverflow.exec(this.ctx)).be.null(); }); @@ -915,6 +1323,14 @@ describe('OutOfBounds', () => { should(await this.dateTimePredecessorUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for successor near overflow', async function () { + should(await this.dateTimeSuccessorNearOverflow.exec(this.ctx)).eql(MAX_DATETIME_VALUE); + }); + + it('should return value for predecessor near underflow', async function () { + should(await this.dateTimePredecessorNearUnderflow.exec(this.ctx)).eql(MIN_DATETIME_VALUE); + }); + // Tests for Precision are include in the spec tests }); @@ -923,24 +1339,34 @@ describe('OutOfBounds', () => { should(await this.dateAddOverflow.exec(this.ctx)).be.null(); }); - // TODO: Fix the logic so this test passes. It's been broken for a long time, but due to a - // faulty test, this was not noticed until now. The cause of the failure is not obvious, so - // this should be revisited (but is lower priority since it's an extremely rare use case). - it.skip('should return null for Add underflow', async function () { + it('should return null for Add underflow', async function () { should(await this.dateAddUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Add near overflow', async function () { + should(await this.dateAddNearOverflow.exec(this.ctx)).eql(MAX_DATE_VALUE); + }); + + it('should return value for Add near underflow', async function () { + should(await this.dateAddNearUnderflow.exec(this.ctx)).eql(MIN_DATE_VALUE); + }); + it('should return null for Subtract overflow', async function () { should(await this.dateSubtractOverflow.exec(this.ctx)).be.null(); }); - // TODO: Fix the logic so this test passes. It's been broken for a long time, but due to a - // faulty test, this was not noticed until now. The cause of the failure is not obvious, so - // this should be revisited (but is lower priority since it's an extremely rare use case). - it.skip('should return null for Subtract underflow', async function () { + it('should return null for Subtract underflow', async function () { should(await this.dateSubtractUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Subtract near overflow', async function () { + should(await this.dateSubtractNearOverflow.exec(this.ctx)).eql(MAX_DATE_VALUE); + }); + + it('should return value for Subtract near underflow', async function () { + should(await this.dateSubtractNearUnderflow.exec(this.ctx)).eql(MIN_DATE_VALUE); + }); + it('should return null for successor overflow', async function () { should(await this.dateSuccessorOverflow.exec(this.ctx)).be.null(); }); @@ -949,6 +1375,14 @@ describe('OutOfBounds', () => { should(await this.datePredecessorUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for successor near overflow', async function () { + should(await this.dateSuccessorNearOverflow.exec(this.ctx)).eql(MAX_DATE_VALUE); + }); + + it('should return value for predecessor near underflow', async function () { + should(await this.datePredecessorNearUnderflow.exec(this.ctx)).eql(MIN_DATE_VALUE); + }); + // Tests for Precision are include in the spec tests }); @@ -961,6 +1395,14 @@ describe('OutOfBounds', () => { should(await this.timeAddUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Add near overflow', async function () { + should(await this.timeAddNearOverflow.exec(this.ctx)).eql(MAX_TIME_VALUE); + }); + + it('should return value for Add near underflow', async function () { + should(await this.timeAddNearUnderflow.exec(this.ctx)).eql(MIN_TIME_VALUE); + }); + it('should return null for Subtract overflow', async function () { should(await this.timeSubtractOverflow.exec(this.ctx)).be.null(); }); @@ -969,6 +1411,14 @@ describe('OutOfBounds', () => { should(await this.timeSubtractUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for Subtract near overflow', async function () { + should(await this.timeSubtractNearOverflow.exec(this.ctx)).eql(MAX_TIME_VALUE); + }); + + it('should return value for Subtract near underflow', async function () { + should(await this.timeSubtractNearUnderflow.exec(this.ctx)).eql(MIN_TIME_VALUE); + }); + it('should return null for successor overflow', async function () { should(await this.timeSuccessorOverflow.exec(this.ctx)).be.null(); }); @@ -977,6 +1427,14 @@ describe('OutOfBounds', () => { should(await this.timePredecessorUnderflow.exec(this.ctx)).be.null(); }); + it('should return value for successor near overflow', async function () { + should(await this.timeSuccessorNearOverflow.exec(this.ctx)).eql(MAX_TIME_VALUE); + }); + + it('should return value for predecessor near underflow', async function () { + should(await this.timePredecessorNearUnderflow.exec(this.ctx)).eql(MIN_TIME_VALUE); + }); + // Tests for Precision are include in the spec tests }); diff --git a/test/elm/arithmetic/data.cql b/test/elm/arithmetic/data.cql index 677d082d1..2aaa87261 100644 --- a/test/elm/arithmetic/data.cql +++ b/test/elm/arithmetic/data.cql @@ -4,6 +4,7 @@ define Eleven: 11 define OnePlusTwo: 1 + 2 define AddMultiple: 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 define AddVariables: Ten + Eleven +define OnePlusTwoLong: 1L + 2L define AddTime: Time(12) + 1 'hour' define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) @@ -17,6 +18,7 @@ define Eleven: 11 define FiveMinusTwo: 5 - 2 define SubtractMultiple: 100 - 50 - 25 - 10 define SubtractVariables: Eleven - Ten +define FiveMinusTwoLong: 5L - 2L define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define SubtractUncertainties: UncertaintySixToEighteen - UncertaintyZeroToTwelve @@ -29,6 +31,7 @@ define Eleven: 11 define FiveTimesTwo: 5 * 2 define MultiplyMultiple: 1 * 2 * 3 * 4 * 5 define MultiplyVariables: Eleven * Ten +define FiveTimesTwoLong: 5 * 2 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define MultiplyUncertainties: UncertaintyTwoToFourteen * UncertaintySixToEighteen @@ -42,6 +45,7 @@ define TenDividedByTwo: 10 / 2 define TenDividedByFour: 10 / 4 define DivideMultiple: 1000 / 4 / 10 / 5 define DivideVariables: Hundred / Four +define TenDividedByTwoLong: 10 / 2 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define DivideUncertainties: UncertaintySixToEighteen / UncertaintyTwoToFourteen @@ -50,6 +54,7 @@ define DivideNumberByUncertainty: 36 / UncertaintySixToEighteen // @Test: Negate define NegativeOne: -1 +define NegativeOneLong: -1L // @Test: MathPrecedence define Mixed: 1 + 5 * 10 - 15 / 3 @@ -57,9 +62,11 @@ define Parenthetical: (1 + 5) * (10 - 15) / 3 // @Test: Power define Pow: 3 ^ 4 +define ThreeExpFourLong: 3L ^ 4L // @Test: MinValue define MinInteger: minimum Integer +define MinLong: minimum Long define MinDecimal: minimum Decimal define MinDateTime: minimum DateTime define MinTime: minimum Time @@ -67,6 +74,7 @@ define MinWrongType: minimum Quantity // @Test: MaxValue define MaxInteger: maximum Integer +define MaxLong: maximum Long define MaxDecimal: maximum Decimal define MaxDateTime: maximum DateTime define MaxTime: maximum Time @@ -75,26 +83,32 @@ define MaxWrongType: maximum Quantity // @Test: TruncatedDivide define Trunc: 10 div 3 define Even: 9 div 3 +define TenDivThreeLong: 10L div 3L // @Test: Modulo define Mod: 3 mod 2 +define ThreeModTwoLong: 3L mod 2L // @Test: Ceiling define Ceil: Ceiling(10.1) define Even: Ceiling(10) +define CeilTenLong: Ceiling(10L) // @Test: Floor define flr: Floor(10.1) define Even: Floor(10) +define FloorTenLong: Floor(10L) // @Test: Truncate define Trunc: Truncate(10.1) define Even: Truncate(10) +define TruncTenLong: Truncate(10L) // @Test: Abs define Pos: Abs(10) define Neg: Abs(-10) define Zero: Abs(0) +define AbsNegTenLong: Abs(-10L) // @Test: Round define Up: Round(4.56) @@ -104,12 +118,15 @@ define Down_percent: Round(4.43,1) // @Test: Ln define ln: Ln(4) +define LnFourLong: Ln(4L) // @Test: Log define log: Log(10,10000) +define logLong: Log(10L,10000L) // @Test: Successor define Is: successor of 2 +define Ls: successor of 2L define Rs: successor of 2.2 define ofr: successor of 2147483647 define y_date: successor of DateTime(2015) @@ -123,6 +140,7 @@ define max_date: successor of DateTime(9999,12,31,23,59,59,999) // @Test: Predecessor define Is: predecessor of 2 +define Ls: predecessor of 2L define Rs: predecessor of 2.2 define ufr: predecessor of -2147483648 define y_date: predecessor of DateTime(2015) @@ -163,65 +181,143 @@ define SubtractUcum: (25 'km' - 5 'm') = 24995 'm' // @Test: OutOfBounds define IntegerAddOverflow: maximum Integer + 1 define IntegerAddUnderflow: minimum Integer + -1 +define IntegerAddNearOverflow: maximum Integer + 0 +define IntegerAddNearUnderflow: minimum Integer + 0 define IntegerSubtractOverflow: maximum Integer - -1 define IntegerSubtractUnderflow: minimum Integer - 1 +define IntegerSubtractNearOverflow: maximum Integer - 0 +define IntegerSubtractNearUnderflow: minimum Integer - 0 define IntegerMultiplyOverflow: maximum Integer * 2 -define IntegerMultiplyUnderflow: minimum Integer * -2 -define IntegerDivideOverflow: maximum Integer / (0.5) -define IntegerDivideUnderflow: minimum Integer / (-0.5) +define IntegerMultiplyUnderflow: minimum Integer * 2 +define IntegerMultiplyNearOverflow: maximum Integer * 1 +define IntegerMultiplyNearUnderflow: minimum Integer * 1 +define IntegerDivideOverflow: maximum Integer / 0.5 +define IntegerDivideUnderflow: minimum Integer / 0.5 +define IntegerDivideNearOverflow: maximum Integer / 1 +define IntegerDivideNearUnderflow: minimum Integer / 1 define IntegerDivideByZero: 1 / 0 define IntegerPowerOverflow: (maximum Integer)^3 define IntegerPowerUnderflow: (minimum Integer)^3 +define IntegerPowerNearOverflow: (maximum Integer)^1 +define IntegerPowerNearUnderflow: (minimum Integer)^1 define IntegerSuccessorOverflow: successor of maximum Integer define IntegerPredecessorUnderflow: predecessor of minimum Integer +define IntegerSuccessorNearOverflow: successor of (maximum Integer - 1) +define IntegerPredecessorNearUnderflow: predecessor of (minimum Integer + 1) + +define LongAddOverflow: maximum Long + 1L +define LongAddUnderflow: minimum Long + -1L +define LongAddNearOverflow: maximum Long + 0L +define LongAddNearUnderflow: minimum Long + 0L +define LongSubtractOverflow: maximum Long - -1L +define LongSubtractUnderflow: minimum Long - 1L +define LongSubtractNearOverflow: maximum Long - 0L +define LongSubtractNearUnderflow: minimum Long - 0L +define LongMultiplyOverflow: maximum Long * 2L +define LongMultiplyUnderflow: minimum Long * 2L +define LongMultiplyNearOverflow: maximum Long * 1L +define LongMultiplyNearUnderflow: minimum Long * 1L +define LongDivideOverflow: maximum Long / 0.5 +define LongDivideUnderflow: minimum Long / 0.5 +define LongDivideNearOverflow: maximum Long / 1L +define LongDivideNearUnderflow: minimum Long / 1L +define LongDivideByZero: 1L / 0L +define LongPowerOverflow: (maximum Long)^3L +define LongPowerUnderflow: (minimum Long)^3L +define LongPowerNearOverflow: (maximum Long)^1L +define LongPowerNearUnderflow: (minimum Long)^1L +define LongSuccessorOverflow: successor of maximum Long +define LongPredecessorUnderflow: predecessor of minimum Long +define LongSuccessorNearOverflow: successor of (maximum Long - 1L) +define LongPredecessorNearUnderflow: predecessor of (minimum Long + 1L) define DecimalAddOverflow: maximum Decimal + 1.0 define DecimalAddUnderflow: minimum Decimal + -1.0 +define DecimalAddNearOverflow: maximum Decimal + 0.0 +define DecimalAddNearUnderflow: minimum Decimal + 0.0 define DecimalSubtractOverflow: maximum Decimal - -1.0 define DecimalSubtractUnderflow: minimum Decimal - 1.0 +define DecimalSubtractNearOverflow: maximum Decimal - 0.0 +define DecimalSubtractNearUnderflow: minimum Decimal - 0.0 define DecimalMultiplyOverflow: maximum Decimal * 2 -define DecimalMultiplyUnderflow: minimum Decimal * -2 -define DecimalDivideOverflow: maximum Decimal / (0.5) -define DecimalDivideUnderflow: minimum Decimal / (-0.5) +define DecimalMultiplyUnderflow: minimum Decimal * 2 +define DecimalMultiplyNearOverflow: maximum Decimal * 1 +define DecimalMultiplyNearUnderflow: minimum Decimal * 1 +define DecimalDivideOverflow: maximum Decimal / 0.5 +define DecimalDivideUnderflow: minimum Decimal / 0.5 +define DecimalDivideNearOverflow: maximum Decimal / 1.0 +define DecimalDivideNearUnderflow: minimum Decimal / 1.0 define DecimalDivideByZero: 1.0 / 0 define DecimalPowerOverflow: (maximum Decimal)^2 define DecimalPowerUnderflow: (minimum Decimal)^3 +define DecimalPowerNearOverflow: (maximum Decimal)^1 +define DecimalPowerNearUnderflow: (minimum Decimal)^1 define DecimalSuccessorOverflow: successor of maximum Decimal define DecimalPredecessorUnderflow: predecessor of minimum Decimal +define DecimalSuccessorNearOverflow: successor of (maximum Decimal - 0.00000001) +define DecimalPredecessorNearUnderflow: predecessor of (minimum Decimal + 0.00000001) define MaxQuantity: Quantity { value: maximum Decimal, unit: 'mm' } define MinQuantity: Quantity { value: minimum Decimal, unit: 'mm' } define QuantityAddOverflow: MaxQuantity + 1.0 'mm' define QuantityAddUnderflow: MinQuantity + (-1.0 'mm') +define QuantityAddNearOverflow: MaxQuantity + 0.0 'mm' +define QuantityAddNearUnderflow: MinQuantity + 0.0 'mm' define QuantitySubtractOverflow: MaxQuantity - (-1 'mm') define QuantitySubtractUnderflow: MinQuantity - 1 'mm' +define QuantitySubtractNearOverflow: MaxQuantity - 0.0 'mm' +define QuantitySubtractNearUnderflow: MinQuantity - 0.0 'mm' define QuantityMultiplyOverflow: MaxQuantity * 2 'mm' define QuantityMultiplyUnderflow: MinQuantity * 2 'mm' +define QuantityMultiplyNearOverflow: MaxQuantity * 1 'mm' +define QuantityMultiplyNearUnderflow: MinQuantity * 1 'mm' define QuantityDivideOverflow: MaxQuantity / 0.5 'mm' -define QuantityDivideUnderflow: MinQuantity / (-0.5 'mm') +define QuantityDivideUnderflow: MinQuantity / 0.5 'mm' +define QuantityDivideNearOverflow: MaxQuantity / 1 'mm' +define QuantityDivideNearUnderflow: MinQuantity / 1 'mm' define QuantityDivideByZero: 1.0 'mm' / 0 'mm' define QuantitySuccessorOverflow: successor of MaxQuantity define QuantityPredecessorUnderflow: predecessor of MinQuantity +define QuantitySuccessorNearOverflow: successor of Quantity { value: maximum Decimal - 0.00000001, unit: 'mm' } +define QuantityPredecessorNearUnderflow: predecessor of Quantity { value: minimum Decimal + 0.00000001, unit: 'mm' } define DateTimeAddOverflow: maximum DateTime + 1 day define DateTimeAddUnderflow: minimum DateTime + (-1 day) +define DateTimeAddNearOverflow: maximum DateTime + 0 days +define DateTimeAddNearUnderflow: minimum DateTime + 0 days define DateTimeSubtractOverflow: maximum DateTime - (-1 day) define DateTimeSubtractUnderflow: minimum DateTime - 1 day +define DateTimeSubtractNearOverflow: maximum DateTime - 0 days +define DateTimeSubtractNearUnderflow: minimum DateTime - 0 days define DateTimeSuccessorOverflow: successor of maximum DateTime define DateTimePredecessorUnderflow: predecessor of minimum DateTime +define DateTimeSuccessorNearOverflow: successor of (maximum DateTime - 1 millisecond) +define DateTimePredecessorNearUnderflow: predecessor of (minimum DateTime + 1 millisecond) define DateAddOverflow: maximum Date + 1 day define DateAddUnderflow: minimum Date + (-1 day) +define DateAddNearOverflow: maximum Date + 0 days +define DateAddNearUnderflow: minimum Date + 0 days define DateSubtractOverflow: maximum Date - (-1 day) define DateSubtractUnderflow: minimum Date - 1 day +define DateSubtractNearOverflow: maximum Date - 0 days +define DateSubtractNearUnderflow: minimum Date - 0 days define DateSuccessorOverflow: successor of maximum Date define DatePredecessorUnderflow: predecessor of minimum Date +define DateSuccessorNearOverflow: successor of (maximum Date - 1 day) +define DatePredecessorNearUnderflow: predecessor of (minimum Date + 1 day) define TimeAddOverflow: maximum Time + 1 second define TimeAddUnderflow: minimum Time + (-1 second) +define TimeAddNearOverflow: maximum Time + 0 seconds +define TimeAddNearUnderflow: minimum Time + 0 seconds define TimeSubtractOverflow: maximum Time - (-1 second) define TimeSubtractUnderflow: minimum Time - 1 second +define TimeSubtractNearOverflow: maximum Time - 0 seconds +define TimeSubtractNearUnderflow: minimum Time - 0 seconds define TimeSuccessorOverflow: successor of maximum Time define TimePredecessorUnderflow: predecessor of minimum Time +define TimeSuccessorNearOverflow: successor of (maximum Time - 1 millisecond) +define TimePredecessorNearUnderflow: predecessor of (minimum Time + 1 millisecond) define ExpOverflow: Exp(maximum Decimal) \ No newline at end of file diff --git a/test/elm/arithmetic/data.js b/test/elm/arithmetic/data.js index 985c4dfbd..1bb115bf9 100644 --- a/test/elm/arithmetic/data.js +++ b/test/elm/arithmetic/data.js @@ -17,6 +17,7 @@ define Eleven: 11 define OnePlusTwo: 1 + 2 define AddMultiple: 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 define AddVariables: Ten + Eleven +define OnePlusTwoLong: 1L + 2L define AddTime: Time(12) + 1 'hour' define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) @@ -37,7 +38,7 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "349", + "r" : "357", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -570,6 +571,60 @@ module.exports['Add'] = { } }, { "localId" : "278", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "OnePlusTwoLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "278", + "s" : [ { + "value" : [ "", "define ", "OnePlusTwoLong", ": " ] + }, { + "r" : "279", + "s" : [ { + "r" : "280", + "value" : [ "1L", " + ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "279", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "282", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "283", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "280", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "281", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "286", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "AddTime", "context" : "Patient", @@ -578,21 +633,21 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "278", + "r" : "286", "s" : [ { "value" : [ "", "define ", "AddTime", ": " ] }, { - "r" : "279", + "r" : "287", "s" : [ { - "r" : "284", + "r" : "292", "s" : [ { - "r" : "280", + "r" : "288", "value" : [ "Time", "(", "12", ")" ] } ] }, { "value" : [ " + " ] }, { - "r" : "286", + "r" : "294", "s" : [ { "value" : [ "1 ", "'hour'" ] } ] @@ -602,34 +657,34 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "279", + "localId" : "287", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "287", + "localId" : "295", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "288", + "localId" : "296", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "Time", - "localId" : "284", + "localId" : "292", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "285", + "localId" : "293", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "hour" : { "type" : "Literal", - "localId" : "280", + "localId" : "288", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -637,7 +692,7 @@ module.exports['Add'] = { } }, { "type" : "Quantity", - "localId" : "286", + "localId" : "294", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "hour", @@ -645,7 +700,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "291", + "localId" : "299", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "context" : "Patient", @@ -654,25 +709,25 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "291", + "r" : "299", "s" : [ { "value" : [ "", "define ", "UncertaintyZeroToTwelve", ": " ] }, { - "r" : "292", + "r" : "300", "s" : [ { "value" : [ "months between " ] }, { - "r" : "299", + "r" : "307", "s" : [ { - "r" : "293", + "r" : "301", "value" : [ "DateTime", "(", "2005", ", ", "12", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "306", + "r" : "314", "s" : [ { - "r" : "302", + "r" : "310", "value" : [ "DateTime", "(", "2006", ")" ] } ] } ] @@ -681,40 +736,40 @@ module.exports['Add'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "292", + "localId" : "300", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "316", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "309", + "localId" : "317", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "299", + "localId" : "307", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "300", + "localId" : "308", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "301", + "localId" : "309", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "293", + "localId" : "301", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -722,7 +777,7 @@ module.exports['Add'] = { }, "month" : { "type" : "Literal", - "localId" : "294", + "localId" : "302", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -730,18 +785,18 @@ module.exports['Add'] = { } }, { "type" : "DateTime", - "localId" : "306", + "localId" : "314", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "307", + "localId" : "315", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "302", + "localId" : "310", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -750,7 +805,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "312", + "localId" : "320", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -759,25 +814,25 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "312", + "r" : "320", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "313", + "r" : "321", "s" : [ { "value" : [ "months between " ] }, { - "r" : "318", + "r" : "326", "s" : [ { - "r" : "314", + "r" : "322", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "326", + "r" : "334", "s" : [ { - "r" : "320", + "r" : "328", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -786,35 +841,35 @@ module.exports['Add'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "313", + "localId" : "321", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "329", + "localId" : "337", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "330", + "localId" : "338", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "318", + "localId" : "326", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "319", + "localId" : "327", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "314", + "localId" : "322", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -822,23 +877,23 @@ module.exports['Add'] = { } }, { "type" : "DateTime", - "localId" : "326", + "localId" : "334", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "327", + "localId" : "335", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "328", + "localId" : "336", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "320", + "localId" : "328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -846,7 +901,7 @@ module.exports['Add'] = { }, "month" : { "type" : "Literal", - "localId" : "321", + "localId" : "329", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -855,7 +910,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "333", + "localId" : "341", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "AddUncertainties", "context" : "Patient", @@ -864,20 +919,20 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "333", + "r" : "341", "s" : [ { "value" : [ "", "define ", "AddUncertainties", ": " ] }, { - "r" : "334", + "r" : "342", "s" : [ { - "r" : "335", + "r" : "343", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] }, { "value" : [ " + " ] }, { - "r" : "336", + "r" : "344", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -887,36 +942,36 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "334", + "localId" : "342", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "337", + "localId" : "345", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "338", + "localId" : "346", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "335", + "localId" : "343", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "336", + "localId" : "344", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } ] } }, { - "localId" : "341", + "localId" : "349", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "AddUncertaintyAndNumber", "context" : "Patient", @@ -925,18 +980,18 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "341", + "r" : "349", "s" : [ { "value" : [ "", "define ", "AddUncertaintyAndNumber", ": " ] }, { - "r" : "342", + "r" : "350", "s" : [ { - "r" : "343", + "r" : "351", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] }, { - "r" : "344", + "r" : "352", "value" : [ " + ", "5" ] } ] } ] @@ -944,29 +999,29 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "342", + "localId" : "350", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "345", + "localId" : "353", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "346", + "localId" : "354", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "343", + "localId" : "351", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "344", + "localId" : "352", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "5", @@ -974,7 +1029,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "349", + "localId" : "357", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "AddNumberAndUncertainty", "context" : "Patient", @@ -983,16 +1038,16 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "349", + "r" : "357", "s" : [ { "value" : [ "", "define ", "AddNumberAndUncertainty", ": " ] }, { - "r" : "350", + "r" : "358", "s" : [ { - "r" : "351", + "r" : "359", "value" : [ "10", " + " ] }, { - "r" : "352", + "r" : "360", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] @@ -1002,30 +1057,30 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "350", + "localId" : "358", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "353", + "localId" : "361", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "354", + "localId" : "362", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "351", + "localId" : "359", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "352", + "localId" : "360", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] @@ -1045,6 +1100,7 @@ define Eleven: 11 define FiveMinusTwo: 5 - 2 define SubtractMultiple: 100 - 50 - 25 - 10 define SubtractVariables: Eleven - Ten +define FiveMinusTwoLong: 5L - 2L define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define SubtractUncertainties: UncertaintySixToEighteen - UncertaintyZeroToTwelve @@ -1064,7 +1120,7 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "312", + "r" : "320", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -1417,6 +1473,60 @@ module.exports['Subtract'] = { } }, { "localId" : "254", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "FiveMinusTwoLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "254", + "s" : [ { + "value" : [ "", "define ", "FiveMinusTwoLong", ": " ] + }, { + "r" : "255", + "s" : [ { + "r" : "256", + "value" : [ "5L", " - ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "255", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "258", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "259", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "256", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "5", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "257", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "262", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "context" : "Patient", @@ -1425,25 +1535,25 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "254", + "r" : "262", "s" : [ { "value" : [ "", "define ", "UncertaintyZeroToTwelve", ": " ] }, { - "r" : "255", + "r" : "263", "s" : [ { "value" : [ "months between " ] }, { - "r" : "262", + "r" : "270", "s" : [ { - "r" : "256", + "r" : "264", "value" : [ "DateTime", "(", "2005", ", ", "12", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "269", + "r" : "277", "s" : [ { - "r" : "265", + "r" : "273", "value" : [ "DateTime", "(", "2006", ")" ] } ] } ] @@ -1452,40 +1562,40 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "255", + "localId" : "263", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "271", + "localId" : "279", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "272", + "localId" : "280", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "262", + "localId" : "270", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "263", + "localId" : "271", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "264", + "localId" : "272", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "256", + "localId" : "264", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -1493,7 +1603,7 @@ module.exports['Subtract'] = { }, "month" : { "type" : "Literal", - "localId" : "257", + "localId" : "265", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -1501,18 +1611,18 @@ module.exports['Subtract'] = { } }, { "type" : "DateTime", - "localId" : "269", + "localId" : "277", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "270", + "localId" : "278", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "265", + "localId" : "273", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -1521,7 +1631,7 @@ module.exports['Subtract'] = { } ] } }, { - "localId" : "275", + "localId" : "283", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -1530,25 +1640,25 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "275", + "r" : "283", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "276", + "r" : "284", "s" : [ { "value" : [ "months between " ] }, { - "r" : "281", + "r" : "289", "s" : [ { - "r" : "277", + "r" : "285", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "289", + "r" : "297", "s" : [ { - "r" : "283", + "r" : "291", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -1557,35 +1667,35 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "276", + "localId" : "284", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "292", + "localId" : "300", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "293", + "localId" : "301", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "281", + "localId" : "289", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "282", + "localId" : "290", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "277", + "localId" : "285", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -1593,23 +1703,23 @@ module.exports['Subtract'] = { } }, { "type" : "DateTime", - "localId" : "289", + "localId" : "297", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "290", + "localId" : "298", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "291", + "localId" : "299", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "283", + "localId" : "291", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -1617,7 +1727,7 @@ module.exports['Subtract'] = { }, "month" : { "type" : "Literal", - "localId" : "284", + "localId" : "292", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -1626,7 +1736,7 @@ module.exports['Subtract'] = { } ] } }, { - "localId" : "296", + "localId" : "304", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "SubtractUncertainties", "context" : "Patient", @@ -1635,20 +1745,20 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "296", + "r" : "304", "s" : [ { "value" : [ "", "define ", "SubtractUncertainties", ": " ] }, { - "r" : "297", + "r" : "305", "s" : [ { - "r" : "298", + "r" : "306", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { "value" : [ " - " ] }, { - "r" : "299", + "r" : "307", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] @@ -1658,36 +1768,36 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "297", + "localId" : "305", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "300", + "localId" : "308", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "301", + "localId" : "309", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "298", + "localId" : "306", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "299", + "localId" : "307", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] } ] } }, { - "localId" : "304", + "localId" : "312", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "SubtractNumberFromUncertainty", "context" : "Patient", @@ -1696,18 +1806,18 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "304", + "r" : "312", "s" : [ { "value" : [ "", "define ", "SubtractNumberFromUncertainty", ": " ] }, { - "r" : "305", + "r" : "313", "s" : [ { - "r" : "306", + "r" : "314", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { - "r" : "307", + "r" : "315", "value" : [ " - ", "5" ] } ] } ] @@ -1715,29 +1825,29 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "305", + "localId" : "313", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "316", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "309", + "localId" : "317", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "306", + "localId" : "314", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "307", + "localId" : "315", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "5", @@ -1745,7 +1855,7 @@ module.exports['Subtract'] = { } ] } }, { - "localId" : "312", + "localId" : "320", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "SubtractUncertaintyFromNumber", "context" : "Patient", @@ -1754,16 +1864,16 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "312", + "r" : "320", "s" : [ { "value" : [ "", "define ", "SubtractUncertaintyFromNumber", ": " ] }, { - "r" : "313", + "r" : "321", "s" : [ { - "r" : "314", + "r" : "322", "value" : [ "10", " - " ] }, { - "r" : "315", + "r" : "323", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -1773,30 +1883,30 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "313", + "localId" : "321", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "316", + "localId" : "324", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "317", + "localId" : "325", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "314", + "localId" : "322", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "315", + "localId" : "323", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] @@ -1816,6 +1926,7 @@ define Eleven: 11 define FiveTimesTwo: 5 * 2 define MultiplyMultiple: 1 * 2 * 3 * 4 * 5 define MultiplyVariables: Eleven * Ten +define FiveTimesTwoLong: 5 * 2 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define MultiplyUncertainties: UncertaintyTwoToFourteen * UncertaintySixToEighteen @@ -1835,7 +1946,7 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "316", + "r" : "324", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -2219,7 +2330,7 @@ module.exports['Multiply'] = { }, { "localId" : "258", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "UncertaintyTwoToFourteen", + "name" : "FiveTimesTwoLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -2228,23 +2339,77 @@ module.exports['Multiply'] = { "s" : { "r" : "258", "s" : [ { - "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] + "value" : [ "", "define ", "FiveTimesTwoLong", ": " ] }, { "r" : "259", + "s" : [ { + "r" : "260", + "value" : [ "5", " * ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "259", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "262", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "263", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "260", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "5", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "261", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "266", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "UncertaintyTwoToFourteen", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "266", + "s" : [ { + "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] + }, { + "r" : "267", "s" : [ { "value" : [ "months between " ] }, { - "r" : "266", + "r" : "274", "s" : [ { - "r" : "260", + "r" : "268", "value" : [ "DateTime", "(", "2005", ", ", "10", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "273", + "r" : "281", "s" : [ { - "r" : "269", + "r" : "277", "value" : [ "DateTime", "(", "2006", ")" ] } ] } ] @@ -2253,40 +2418,40 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "259", + "localId" : "267", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "275", + "localId" : "283", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "276", + "localId" : "284", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "266", + "localId" : "274", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "267", + "localId" : "275", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "268", + "localId" : "276", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "260", + "localId" : "268", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -2294,7 +2459,7 @@ module.exports['Multiply'] = { }, "month" : { "type" : "Literal", - "localId" : "261", + "localId" : "269", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", @@ -2302,18 +2467,18 @@ module.exports['Multiply'] = { } }, { "type" : "DateTime", - "localId" : "273", + "localId" : "281", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "274", + "localId" : "282", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "269", + "localId" : "277", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -2322,7 +2487,7 @@ module.exports['Multiply'] = { } ] } }, { - "localId" : "279", + "localId" : "287", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -2331,25 +2496,25 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "279", + "r" : "287", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "280", + "r" : "288", "s" : [ { "value" : [ "months between " ] }, { - "r" : "285", + "r" : "293", "s" : [ { - "r" : "281", + "r" : "289", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "293", + "r" : "301", "s" : [ { - "r" : "287", + "r" : "295", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -2358,35 +2523,35 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "280", + "localId" : "288", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "296", + "localId" : "304", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "297", + "localId" : "305", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "285", + "localId" : "293", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "286", + "localId" : "294", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "281", + "localId" : "289", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -2394,23 +2559,23 @@ module.exports['Multiply'] = { } }, { "type" : "DateTime", - "localId" : "293", + "localId" : "301", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "294", + "localId" : "302", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "295", + "localId" : "303", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "287", + "localId" : "295", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -2418,7 +2583,7 @@ module.exports['Multiply'] = { }, "month" : { "type" : "Literal", - "localId" : "288", + "localId" : "296", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -2427,7 +2592,7 @@ module.exports['Multiply'] = { } ] } }, { - "localId" : "300", + "localId" : "308", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "MultiplyUncertainties", "context" : "Patient", @@ -2436,20 +2601,20 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "300", + "r" : "308", "s" : [ { "value" : [ "", "define ", "MultiplyUncertainties", ": " ] }, { - "r" : "301", + "r" : "309", "s" : [ { - "r" : "302", + "r" : "310", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] }, { "value" : [ " * " ] }, { - "r" : "303", + "r" : "311", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -2459,36 +2624,36 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "301", + "localId" : "309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "304", + "localId" : "312", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "305", + "localId" : "313", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "302", + "localId" : "310", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "303", + "localId" : "311", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } ] } }, { - "localId" : "308", + "localId" : "316", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "MultiplyUncertaintyAndNumber", "context" : "Patient", @@ -2497,18 +2662,18 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "308", + "r" : "316", "s" : [ { "value" : [ "", "define ", "MultiplyUncertaintyAndNumber", ": " ] }, { - "r" : "309", + "r" : "317", "s" : [ { - "r" : "310", + "r" : "318", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] }, { - "r" : "311", + "r" : "319", "value" : [ " * ", "5" ] } ] } ] @@ -2516,29 +2681,29 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "309", + "localId" : "317", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "312", + "localId" : "320", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "313", + "localId" : "321", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "310", + "localId" : "318", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "311", + "localId" : "319", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "5", @@ -2546,7 +2711,7 @@ module.exports['Multiply'] = { } ] } }, { - "localId" : "316", + "localId" : "324", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "MultiplyNumberAndUncertainty", "context" : "Patient", @@ -2555,16 +2720,16 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "316", + "r" : "324", "s" : [ { "value" : [ "", "define ", "MultiplyNumberAndUncertainty", ": " ] }, { - "r" : "317", + "r" : "325", "s" : [ { - "r" : "318", + "r" : "326", "value" : [ "10", " * " ] }, { - "r" : "319", + "r" : "327", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] @@ -2574,30 +2739,30 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "317", + "localId" : "325", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "320", + "localId" : "328", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "321", + "localId" : "329", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "318", + "localId" : "326", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "319", + "localId" : "327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] @@ -2618,6 +2783,7 @@ define TenDividedByTwo: 10 / 2 define TenDividedByFour: 10 / 4 define DivideMultiple: 1000 / 4 / 10 / 5 define DivideVariables: Hundred / Four +define TenDividedByTwoLong: 10 / 2 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define DivideUncertainties: UncertaintySixToEighteen / UncertaintyTwoToFourteen @@ -2637,7 +2803,7 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "362", + "r" : "376", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -3154,8 +3320,8 @@ module.exports['Divide'] = { } }, { "localId" : "292", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "UncertaintyTwoToFourteen", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TenDividedByTwoLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -3164,73 +3330,149 @@ module.exports['Divide'] = { "s" : { "r" : "292", "s" : [ { - "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] + "value" : [ "", "define ", "TenDividedByTwoLong", ": " ] }, { "r" : "293", "s" : [ { - "value" : [ "months between " ] - }, { - "r" : "300", - "s" : [ { - "r" : "294", - "value" : [ "DateTime", "(", "2005", ", ", "10", ")" ] - } ] - }, { - "value" : [ " and " ] - }, { - "r" : "307", - "s" : [ { - "r" : "303", - "value" : [ "DateTime", "(", "2006", ")" ] - } ] + "r" : "294", + "value" : [ "10", " / ", "2" ] } ] } ] } } ], "expression" : { - "type" : "DurationBetween", + "type" : "Divide", "localId" : "293", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "precision" : "Month", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "309", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "302", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "310", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "303", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { - "type" : "DateTime", - "localId" : "300", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "ToDecimal", + "localId" : "297", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "301", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "302", + "localId" : "298", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "year" : { + "operand" : { "type" : "Literal", "localId" : "294", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "300", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "301", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "295", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "306", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "UncertaintyTwoToFourteen", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "306", + "s" : [ { + "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] + }, { + "r" : "307", + "s" : [ { + "value" : [ "months between " ] + }, { + "r" : "314", + "s" : [ { + "r" : "308", + "value" : [ "DateTime", "(", "2005", ", ", "10", ")" ] + } ] + }, { + "value" : [ " and " ] + }, { + "r" : "321", + "s" : [ { + "r" : "317", + "value" : [ "DateTime", "(", "2006", ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "DurationBetween", + "localId" : "307", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "precision" : "Month", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "323", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "324", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "DateTime", + "localId" : "314", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "315", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "316", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "year" : { + "type" : "Literal", + "localId" : "308", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", "annotation" : [ ] }, "month" : { "type" : "Literal", - "localId" : "295", + "localId" : "309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", @@ -3238,18 +3480,18 @@ module.exports['Divide'] = { } }, { "type" : "DateTime", - "localId" : "307", + "localId" : "321", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "322", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "303", + "localId" : "317", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -3258,7 +3500,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "313", + "localId" : "327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -3267,25 +3509,25 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "313", + "r" : "327", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "314", + "r" : "328", "s" : [ { "value" : [ "months between " ] }, { - "r" : "319", + "r" : "333", "s" : [ { - "r" : "315", + "r" : "329", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "327", + "r" : "341", "s" : [ { - "r" : "321", + "r" : "335", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -3294,35 +3536,35 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "314", + "localId" : "328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "330", + "localId" : "344", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "331", + "localId" : "345", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "319", + "localId" : "333", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "320", + "localId" : "334", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "315", + "localId" : "329", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -3330,23 +3572,23 @@ module.exports['Divide'] = { } }, { "type" : "DateTime", - "localId" : "327", + "localId" : "341", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "328", + "localId" : "342", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "329", + "localId" : "343", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "321", + "localId" : "335", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -3354,7 +3596,7 @@ module.exports['Divide'] = { }, "month" : { "type" : "Literal", - "localId" : "322", + "localId" : "336", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -3363,7 +3605,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "334", + "localId" : "348", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DivideUncertainties", "context" : "Patient", @@ -3372,20 +3614,20 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "334", + "r" : "348", "s" : [ { "value" : [ "", "define ", "DivideUncertainties", ": " ] }, { - "r" : "335", + "r" : "349", "s" : [ { - "r" : "336", + "r" : "350", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { "value" : [ " / " ] }, { - "r" : "337", + "r" : "351", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] @@ -3395,50 +3637,50 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "Divide", - "localId" : "335", + "localId" : "349", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "344", + "localId" : "358", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "345", + "localId" : "359", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "339", + "localId" : "353", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "340", + "localId" : "354", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "336", + "localId" : "350", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } }, { "type" : "ToDecimal", - "localId" : "342", + "localId" : "356", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "343", + "localId" : "357", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "337", + "localId" : "351", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] @@ -3446,7 +3688,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "348", + "localId" : "362", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DivideUncertaintyByNumber", "context" : "Patient", @@ -3455,18 +3697,18 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "348", + "r" : "362", "s" : [ { "value" : [ "", "define ", "DivideUncertaintyByNumber", ": " ] }, { - "r" : "349", + "r" : "363", "s" : [ { - "r" : "350", + "r" : "364", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { - "r" : "351", + "r" : "365", "value" : [ " / ", "2" ] } ] } ] @@ -3474,50 +3716,50 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "Divide", - "localId" : "349", + "localId" : "363", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "358", + "localId" : "372", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "359", + "localId" : "373", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "353", + "localId" : "367", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "354", + "localId" : "368", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "350", + "localId" : "364", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } }, { "type" : "ToDecimal", - "localId" : "356", + "localId" : "370", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "357", + "localId" : "371", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "351", + "localId" : "365", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2", @@ -3526,7 +3768,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "362", + "localId" : "376", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DivideNumberByUncertainty", "context" : "Patient", @@ -3535,16 +3777,16 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "362", + "r" : "376", "s" : [ { "value" : [ "", "define ", "DivideNumberByUncertainty", ": " ] }, { - "r" : "363", + "r" : "377", "s" : [ { - "r" : "364", + "r" : "378", "value" : [ "36", " / " ] }, { - "r" : "365", + "r" : "379", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -3554,33 +3796,33 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "Divide", - "localId" : "363", + "localId" : "377", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "372", + "localId" : "386", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "373", + "localId" : "387", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "367", + "localId" : "381", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "368", + "localId" : "382", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "364", + "localId" : "378", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "36", @@ -3588,17 +3830,17 @@ module.exports['Divide'] = { } }, { "type" : "ToDecimal", - "localId" : "370", + "localId" : "384", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "371", + "localId" : "385", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "365", + "localId" : "379", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] @@ -3615,6 +3857,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define NegativeOne: -1 +define NegativeOneLong: -1L */ module.exports['Negate'] = { @@ -3629,7 +3872,7 @@ module.exports['Negate'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "214", + "r" : "220", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -3743,6 +3986,48 @@ module.exports['Negate'] = { "annotation" : [ ] } } + }, { + "localId" : "220", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "NegativeOneLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "220", + "s" : [ { + "value" : [ "", "define ", "NegativeOneLong", ": " ] + }, { + "r" : "221", + "s" : [ { + "r" : "222", + "value" : [ "-", "1L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Negate", + "localId" : "221", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "223", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } + } } ] } } @@ -4205,6 +4490,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define Pow: 3 ^ 4 +define ThreeExpFourLong: 3L ^ 4L */ module.exports['Power'] = { @@ -4219,7 +4505,7 @@ module.exports['Power'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "214", + "r" : "222", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -4345,48 +4631,103 @@ module.exports['Power'] = { "annotation" : [ ] } ] } - } ] - } - } -} - -/* MinValue -library TestSnippet version '1' -using Simple version '1.0.0' -context Patient -define MinInteger: minimum Integer -define MinDecimal: minimum Decimal -define MinDateTime: minimum DateTime -define MinTime: minimum Time -define MinWrongType: minimum Quantity -*/ - -module.exports['MinValue'] = { - "library" : { - "localId" : "0", - "annotation" : [ { - "type" : "CqlToElmInfo", - "translatorVersion" : "4.2.0", - "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", - "signatureLevel" : "All" - }, { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "234", - "s" : [ { - "value" : [ "", "library TestSnippet version '1'" ] - } ] - } - } ], - "identifier" : { - "id" : "TestSnippet", - "version" : "1" - }, - "schemaIdentifier" : { - "id" : "urn:hl7-org:elm", - "version" : "r1" - }, + }, { + "localId" : "222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "ThreeExpFourLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "222", + "s" : [ { + "value" : [ "", "define ", "ThreeExpFourLong", ": " ] + }, { + "r" : "223", + "s" : [ { + "r" : "224", + "value" : [ "3L", " ^ ", "4L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "223", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "226", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "4", + "annotation" : [ ] + } ] + } + } ] + } + } +} + +/* MinValue +library TestSnippet version '1' +using Simple version '1.0.0' +context Patient +define MinInteger: minimum Integer +define MinLong: minimum Long +define MinDecimal: minimum Decimal +define MinDateTime: minimum DateTime +define MinTime: minimum Time +define MinWrongType: minimum Quantity +*/ + +module.exports['MinValue'] = { + "library" : { + "localId" : "0", + "annotation" : [ { + "type" : "CqlToElmInfo", + "translatorVersion" : "4.2.0", + "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", + "signatureLevel" : "All" + }, { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "239", + "s" : [ { + "value" : [ "", "library TestSnippet version '1'" ] + } ] + } + } ], + "identifier" : { + "id" : "TestSnippet", + "version" : "1" + }, + "schemaIdentifier" : { + "id" : "urn:hl7-org:elm", + "version" : "r1" + }, "usings" : { "def" : [ { "localId" : "1", @@ -4480,8 +4821,8 @@ module.exports['MinValue'] = { } }, { "localId" : "219", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "MinDecimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "MinLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -4490,7 +4831,7 @@ module.exports['MinValue'] = { "s" : { "r" : "219", "s" : [ { - "value" : [ "", "define ", "MinDecimal", ": " ] + "value" : [ "", "define ", "MinLong", ": " ] }, { "r" : "221", "s" : [ { @@ -4498,7 +4839,7 @@ module.exports['MinValue'] = { }, { "r" : "220", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Long" ] } ] } ] } ] @@ -4507,12 +4848,45 @@ module.exports['MinValue'] = { "expression" : { "type" : "MinValue", "localId" : "221", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + }, { + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "MinDecimal", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "224", + "s" : [ { + "value" : [ "", "define ", "MinDecimal", ": " ] + }, { + "r" : "226", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "225", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "MinValue", + "localId" : "226", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } }, { - "localId" : "224", + "localId" : "229", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "MinDateTime", "context" : "Patient", @@ -4521,15 +4895,15 @@ module.exports['MinValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "224", + "r" : "229", "s" : [ { "value" : [ "", "define ", "MinDateTime", ": " ] }, { - "r" : "226", + "r" : "231", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "225", + "r" : "230", "s" : [ { "value" : [ "DateTime" ] } ] @@ -4539,13 +4913,13 @@ module.exports['MinValue'] = { } ], "expression" : { "type" : "MinValue", - "localId" : "226", + "localId" : "231", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } }, { - "localId" : "229", + "localId" : "234", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "MinTime", "context" : "Patient", @@ -4554,15 +4928,15 @@ module.exports['MinValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "229", + "r" : "234", "s" : [ { "value" : [ "", "define ", "MinTime", ": " ] }, { - "r" : "231", + "r" : "236", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "230", + "r" : "235", "s" : [ { "value" : [ "Time" ] } ] @@ -4572,13 +4946,13 @@ module.exports['MinValue'] = { } ], "expression" : { "type" : "MinValue", - "localId" : "231", + "localId" : "236", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } }, { - "localId" : "234", + "localId" : "239", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinWrongType", "context" : "Patient", @@ -4587,15 +4961,15 @@ module.exports['MinValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "239", "s" : [ { "value" : [ "", "define ", "MinWrongType", ": " ] }, { - "r" : "236", + "r" : "241", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "235", + "r" : "240", "s" : [ { "value" : [ "Quantity" ] } ] @@ -4605,7 +4979,7 @@ module.exports['MinValue'] = { } ], "expression" : { "type" : "MinValue", - "localId" : "236", + "localId" : "241", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "valueType" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] @@ -4620,6 +4994,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define MaxInteger: maximum Integer +define MaxLong: maximum Long define MaxDecimal: maximum Decimal define MaxDateTime: maximum DateTime define MaxTime: maximum Time @@ -4638,7 +5013,7 @@ module.exports['MaxValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "239", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -4745,8 +5120,8 @@ module.exports['MaxValue'] = { } }, { "localId" : "219", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "MaxDecimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "MaxLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -4755,7 +5130,7 @@ module.exports['MaxValue'] = { "s" : { "r" : "219", "s" : [ { - "value" : [ "", "define ", "MaxDecimal", ": " ] + "value" : [ "", "define ", "MaxLong", ": " ] }, { "r" : "221", "s" : [ { @@ -4763,7 +5138,7 @@ module.exports['MaxValue'] = { }, { "r" : "220", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Long" ] } ] } ] } ] @@ -4772,12 +5147,45 @@ module.exports['MaxValue'] = { "expression" : { "type" : "MaxValue", "localId" : "221", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + }, { + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "MaxDecimal", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "224", + "s" : [ { + "value" : [ "", "define ", "MaxDecimal", ": " ] + }, { + "r" : "226", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "225", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "MaxValue", + "localId" : "226", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } }, { - "localId" : "224", + "localId" : "229", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "MaxDateTime", "context" : "Patient", @@ -4786,15 +5194,15 @@ module.exports['MaxValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "224", + "r" : "229", "s" : [ { "value" : [ "", "define ", "MaxDateTime", ": " ] }, { - "r" : "226", + "r" : "231", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "225", + "r" : "230", "s" : [ { "value" : [ "DateTime" ] } ] @@ -4804,13 +5212,13 @@ module.exports['MaxValue'] = { } ], "expression" : { "type" : "MaxValue", - "localId" : "226", + "localId" : "231", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } }, { - "localId" : "229", + "localId" : "234", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "MaxTime", "context" : "Patient", @@ -4819,15 +5227,15 @@ module.exports['MaxValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "229", + "r" : "234", "s" : [ { "value" : [ "", "define ", "MaxTime", ": " ] }, { - "r" : "231", + "r" : "236", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "230", + "r" : "235", "s" : [ { "value" : [ "Time" ] } ] @@ -4837,13 +5245,13 @@ module.exports['MaxValue'] = { } ], "expression" : { "type" : "MaxValue", - "localId" : "231", + "localId" : "236", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } }, { - "localId" : "234", + "localId" : "239", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxWrongType", "context" : "Patient", @@ -4852,15 +5260,15 @@ module.exports['MaxValue'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "239", "s" : [ { "value" : [ "", "define ", "MaxWrongType", ": " ] }, { - "r" : "236", + "r" : "241", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "235", + "r" : "240", "s" : [ { "value" : [ "Quantity" ] } ] @@ -4870,7 +5278,7 @@ module.exports['MaxValue'] = { } ], "expression" : { "type" : "MaxValue", - "localId" : "236", + "localId" : "241", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "valueType" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] @@ -4886,6 +5294,7 @@ using Simple version '1.0.0' context Patient define Trunc: 10 div 3 define Even: 9 div 3 +define TenDivThreeLong: 10L div 3L */ module.exports['TruncatedDivide'] = { @@ -4900,7 +5309,7 @@ module.exports['TruncatedDivide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "222", + "r" : "230", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5080,6 +5489,60 @@ module.exports['TruncatedDivide'] = { "annotation" : [ ] } ] } + }, { + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "TenDivThreeLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "230", + "s" : [ { + "value" : [ "", "define ", "TenDivThreeLong", ": " ] + }, { + "r" : "231", + "s" : [ { + "r" : "232", + "value" : [ "10L", " div ", "3L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "TruncatedDivide", + "localId" : "231", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "234", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "235", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "233", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + } ] + } } ] } } @@ -5090,6 +5553,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define Mod: 3 mod 2 +define ThreeModTwoLong: 3L mod 2L */ module.exports['Modulo'] = { @@ -5104,7 +5568,7 @@ module.exports['Modulo'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "214", + "r" : "222", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5230,9 +5694,63 @@ module.exports['Modulo'] = { "annotation" : [ ] } ] } - } ] - } - } + }, { + "localId" : "222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "ThreeModTwoLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "222", + "s" : [ { + "value" : [ "", "define ", "ThreeModTwoLong", ": " ] + }, { + "r" : "223", + "s" : [ { + "r" : "224", + "value" : [ "3L", " mod ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Modulo", + "localId" : "223", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "226", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + } ] + } + } } /* Ceiling @@ -5241,6 +5759,7 @@ using Simple version '1.0.0' context Patient define Ceil: Ceiling(10.1) define Even: Ceiling(10) +define CeilTenLong: Ceiling(10L) */ module.exports['Ceiling'] = { @@ -5255,7 +5774,7 @@ module.exports['Ceiling'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "223", + "r" : "238", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5422,6 +5941,59 @@ module.exports['Ceiling'] = { } } } + }, { + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "CeilTenLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "238", + "s" : [ { + "value" : [ "", "define ", "CeilTenLong", ": " ] + }, { + "r" : "246", + "s" : [ { + "r" : "239", + "value" : [ "Ceiling", "(", "10L", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Ceiling", + "localId" : "246", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "250", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ToDecimal", + "localId" : "248", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "249", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "239", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + } + } } ] } } @@ -5433,6 +6005,7 @@ using Simple version '1.0.0' context Patient define flr: Floor(10.1) define Even: Floor(10) +define FloorTenLong: Floor(10L) */ module.exports['Floor'] = { @@ -5447,7 +6020,7 @@ module.exports['Floor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "223", + "r" : "238", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5614,6 +6187,59 @@ module.exports['Floor'] = { } } } + }, { + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "FloorTenLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "238", + "s" : [ { + "value" : [ "", "define ", "FloorTenLong", ": " ] + }, { + "r" : "246", + "s" : [ { + "r" : "239", + "value" : [ "Floor", "(", "10L", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Floor", + "localId" : "246", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "250", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ToDecimal", + "localId" : "248", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "249", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "239", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + } + } } ] } } @@ -5625,6 +6251,7 @@ using Simple version '1.0.0' context Patient define Trunc: Truncate(10.1) define Even: Truncate(10) +define TruncTenLong: Truncate(10L) */ module.exports['Truncate'] = { @@ -5639,7 +6266,7 @@ module.exports['Truncate'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "223", + "r" : "238", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5806,6 +6433,59 @@ module.exports['Truncate'] = { } } } + }, { + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "TruncTenLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "238", + "s" : [ { + "value" : [ "", "define ", "TruncTenLong", ": " ] + }, { + "r" : "246", + "s" : [ { + "r" : "239", + "value" : [ "Truncate", "(", "10L", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Truncate", + "localId" : "246", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "250", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ToDecimal", + "localId" : "248", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "249", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "239", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + } + } } ] } } @@ -5818,6 +6498,7 @@ context Patient define Pos: Abs(10) define Neg: Abs(-10) define Zero: Abs(0) +define AbsNegTenLong: Abs(-10L) */ module.exports['Abs'] = { @@ -5832,7 +6513,7 @@ module.exports['Abs'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "243", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -6049,6 +6730,67 @@ module.exports['Abs'] = { "annotation" : [ ] } } + }, { + "localId" : "243", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "AbsNegTenLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "243", + "s" : [ { + "value" : [ "", "define ", "AbsNegTenLong", ": " ] + }, { + "r" : "250", + "s" : [ { + "value" : [ "Abs", "(" ] + }, { + "r" : "244", + "s" : [ { + "r" : "245", + "value" : [ "-", "10L" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Abs", + "localId" : "250", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "251", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Negate", + "localId" : "244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "246", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "245", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + } + } } ] } } @@ -6352,6 +7094,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define ln: Ln(4) +define LnFourLong: Ln(4L) */ module.exports['Ln'] = { @@ -6366,7 +7109,7 @@ module.exports['Ln'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "214", + "r" : "229", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -6491,37 +7234,91 @@ module.exports['Ln'] = { } } } - } ] - } - } -} - -/* Log -library TestSnippet version '1' -using Simple version '1.0.0' -context Patient -define log: Log(10,10000) -*/ - -module.exports['Log'] = { - "library" : { - "localId" : "0", - "annotation" : [ { - "type" : "CqlToElmInfo", - "translatorVersion" : "4.2.0", - "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", - "signatureLevel" : "All" - }, { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "214", - "s" : [ { - "value" : [ "", "library TestSnippet version '1'" ] - } ] - } - } ], - "identifier" : { + }, { + "localId" : "229", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "LnFourLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "229", + "s" : [ { + "value" : [ "", "define ", "LnFourLong", ": " ] + }, { + "r" : "237", + "s" : [ { + "r" : "230", + "value" : [ "Ln", "(", "4L", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Ln", + "localId" : "237", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "241", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ToDecimal", + "localId" : "239", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "240", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "4", + "annotation" : [ ] + } + } + } + } ] + } + } +} + +/* Log +library TestSnippet version '1' +using Simple version '1.0.0' +context Patient +define log: Log(10,10000) +define logLong: Log(10L,10000L) +*/ + +module.exports['Log'] = { + "library" : { + "localId" : "0", + "annotation" : [ { + "type" : "CqlToElmInfo", + "translatorVersion" : "4.2.0", + "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", + "signatureLevel" : "All" + }, { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "238", + "s" : [ { + "value" : [ "", "library TestSnippet version '1'" ] + } ] + } + } ], + "identifier" : { "id" : "TestSnippet", "version" : "1" }, @@ -6663,6 +7460,82 @@ module.exports['Log'] = { } } ] } + }, { + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "logLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "238", + "s" : [ { + "value" : [ "", "define ", "logLong", ": " ] + }, { + "r" : "251", + "s" : [ { + "r" : "239", + "value" : [ "Log", "(", "10L", ",", "10000L", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Log", + "localId" : "251", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "258", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "259", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "253", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "254", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "239", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "256", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "257", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10000", + "annotation" : [ ] + } + } ] + } } ] } } @@ -6673,6 +7546,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define Is: successor of 2 +define Ls: successor of 2L define Rs: successor of 2.2 define ofr: successor of 2147483647 define y_date: successor of DateTime(2015) @@ -6697,7 +7571,7 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "372", + "r" : "378", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -6813,8 +7687,8 @@ module.exports['Successor'] = { } }, { "localId" : "220", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "Rs", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "Ls", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -6823,12 +7697,12 @@ module.exports['Successor'] = { "s" : { "r" : "220", "s" : [ { - "value" : [ "", "define ", "Rs", ": " ] + "value" : [ "", "define ", "Ls", ": " ] }, { "r" : "222", "s" : [ { "r" : "221", - "value" : [ "successor of ", "2.2" ] + "value" : [ "successor of ", "2L" ] } ] } ] } @@ -6836,17 +7710,59 @@ module.exports['Successor'] = { "expression" : { "type" : "Successor", "localId" : "222", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "223", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", "localId" : "221", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } + } + }, { + "localId" : "226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "Rs", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "226", + "s" : [ { + "value" : [ "", "define ", "Rs", ": " ] + }, { + "r" : "228", + "s" : [ { + "r" : "227", + "value" : [ "successor of ", "2.2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "228", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "229", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "227", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "2.2", @@ -6854,7 +7770,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "226", + "localId" : "232", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "ofr", "context" : "Patient", @@ -6863,13 +7779,13 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "226", + "r" : "232", "s" : [ { "value" : [ "", "define ", "ofr", ": " ] }, { - "r" : "228", + "r" : "234", "s" : [ { - "r" : "227", + "r" : "233", "value" : [ "successor of ", "2147483647" ] } ] } ] @@ -6877,18 +7793,18 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "228", + "localId" : "234", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "229", + "localId" : "235", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "227", + "localId" : "233", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2147483647", @@ -6896,7 +7812,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "232", + "localId" : "238", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "y_date", "context" : "Patient", @@ -6905,17 +7821,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "232", + "r" : "238", "s" : [ { "value" : [ "", "define ", "y_date", ": " ] }, { - "r" : "239", + "r" : "245", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "237", + "r" : "243", "s" : [ { - "r" : "233", + "r" : "239", "value" : [ "DateTime", "(", "2015", ")" ] } ] } ] @@ -6924,29 +7840,29 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "239", + "localId" : "245", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "240", + "localId" : "246", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "237", + "localId" : "243", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "238", + "localId" : "244", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "233", + "localId" : "239", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -6955,7 +7871,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "243", + "localId" : "249", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ym_date", "context" : "Patient", @@ -6964,17 +7880,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "243", + "r" : "249", "s" : [ { "value" : [ "", "define ", "ym_date", ": " ] }, { - "r" : "253", + "r" : "259", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "250", + "r" : "256", "s" : [ { - "r" : "244", + "r" : "250", "value" : [ "DateTime", "(", "2015", ",", "01", ")" ] } ] } ] @@ -6983,34 +7899,34 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "253", + "localId" : "259", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "254", + "localId" : "260", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "250", + "localId" : "256", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "251", + "localId" : "257", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "252", + "localId" : "258", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "244", + "localId" : "250", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -7018,7 +7934,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "245", + "localId" : "251", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7027,7 +7943,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "257", + "localId" : "263", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymd_date", "context" : "Patient", @@ -7036,17 +7952,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "257", + "r" : "263", "s" : [ { "value" : [ "", "define ", "ymd_date", ": " ] }, { - "r" : "270", + "r" : "276", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "266", + "r" : "272", "s" : [ { - "r" : "258", + "r" : "264", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ")" ] } ] } ] @@ -7055,39 +7971,39 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "270", + "localId" : "276", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "271", + "localId" : "277", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "266", + "localId" : "272", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "267", + "localId" : "273", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "268", + "localId" : "274", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "269", + "localId" : "275", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "258", + "localId" : "264", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -7095,7 +8011,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "259", + "localId" : "265", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7103,7 +8019,7 @@ module.exports['Successor'] = { }, "day" : { "type" : "Literal", - "localId" : "260", + "localId" : "266", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7112,7 +8028,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "274", + "localId" : "280", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdh_date", "context" : "Patient", @@ -7121,17 +8037,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "274", + "r" : "280", "s" : [ { "value" : [ "", "define ", "ymdh_date", ": " ] }, { - "r" : "290", + "r" : "296", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "285", + "r" : "291", "s" : [ { - "r" : "275", + "r" : "281", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ")" ] } ] } ] @@ -7140,44 +8056,44 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "290", + "localId" : "296", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "291", + "localId" : "297", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "285", + "localId" : "291", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "286", + "localId" : "292", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "287", + "localId" : "293", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "288", + "localId" : "294", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "289", + "localId" : "295", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "275", + "localId" : "281", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -7185,7 +8101,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "276", + "localId" : "282", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7193,7 +8109,7 @@ module.exports['Successor'] = { }, "day" : { "type" : "Literal", - "localId" : "277", + "localId" : "283", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7201,7 +8117,7 @@ module.exports['Successor'] = { }, "hour" : { "type" : "Literal", - "localId" : "278", + "localId" : "284", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7210,7 +8126,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "294", + "localId" : "300", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdhm_date", "context" : "Patient", @@ -7219,17 +8135,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "294", + "r" : "300", "s" : [ { "value" : [ "", "define ", "ymdhm_date", ": " ] }, { - "r" : "313", + "r" : "319", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "307", + "r" : "313", "s" : [ { - "r" : "295", + "r" : "301", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ",", "0", ")" ] } ] } ] @@ -7238,49 +8154,49 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "313", + "localId" : "319", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "314", + "localId" : "320", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "307", + "localId" : "313", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "314", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "309", + "localId" : "315", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "310", + "localId" : "316", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "311", + "localId" : "317", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "312", + "localId" : "318", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "295", + "localId" : "301", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -7288,7 +8204,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "296", + "localId" : "302", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7296,7 +8212,7 @@ module.exports['Successor'] = { }, "day" : { "type" : "Literal", - "localId" : "297", + "localId" : "303", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7304,7 +8220,7 @@ module.exports['Successor'] = { }, "hour" : { "type" : "Literal", - "localId" : "298", + "localId" : "304", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7312,7 +8228,7 @@ module.exports['Successor'] = { }, "minute" : { "type" : "Literal", - "localId" : "299", + "localId" : "305", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7321,7 +8237,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "317", + "localId" : "323", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdhms_date", "context" : "Patient", @@ -7330,17 +8246,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "317", + "r" : "323", "s" : [ { "value" : [ "", "define ", "ymdhms_date", ": " ] }, { - "r" : "339", + "r" : "345", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "332", + "r" : "338", "s" : [ { - "r" : "318", + "r" : "324", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ",", "0", ",", "0", ")" ] } ] } ] @@ -7349,54 +8265,54 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "339", + "localId" : "345", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "340", + "localId" : "346", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "332", + "localId" : "338", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "333", + "localId" : "339", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "334", + "localId" : "340", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "335", + "localId" : "341", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "336", + "localId" : "342", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "337", + "localId" : "343", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "338", + "localId" : "344", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "318", + "localId" : "324", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -7404,7 +8320,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "319", + "localId" : "325", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7412,7 +8328,7 @@ module.exports['Successor'] = { }, "day" : { "type" : "Literal", - "localId" : "320", + "localId" : "326", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7420,7 +8336,7 @@ module.exports['Successor'] = { }, "hour" : { "type" : "Literal", - "localId" : "321", + "localId" : "327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7428,7 +8344,7 @@ module.exports['Successor'] = { }, "minute" : { "type" : "Literal", - "localId" : "322", + "localId" : "328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7436,7 +8352,7 @@ module.exports['Successor'] = { }, "second" : { "type" : "Literal", - "localId" : "323", + "localId" : "329", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7445,7 +8361,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "343", + "localId" : "349", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdhmsm_date", "context" : "Patient", @@ -7454,17 +8370,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "343", + "r" : "349", "s" : [ { "value" : [ "", "define ", "ymdhmsm_date", ": " ] }, { - "r" : "368", + "r" : "374", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "360", + "r" : "366", "s" : [ { - "r" : "344", + "r" : "350", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ",", "0", ",", "0", ",", "0", ")" ] } ] } ] @@ -7473,59 +8389,59 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "368", + "localId" : "374", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "369", + "localId" : "375", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "360", + "localId" : "366", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "361", + "localId" : "367", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "362", + "localId" : "368", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "363", + "localId" : "369", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "364", + "localId" : "370", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "365", + "localId" : "371", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "366", + "localId" : "372", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "367", + "localId" : "373", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "344", + "localId" : "350", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -7533,7 +8449,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "345", + "localId" : "351", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7541,7 +8457,7 @@ module.exports['Successor'] = { }, "day" : { "type" : "Literal", - "localId" : "346", + "localId" : "352", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -7549,7 +8465,7 @@ module.exports['Successor'] = { }, "hour" : { "type" : "Literal", - "localId" : "347", + "localId" : "353", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7557,7 +8473,7 @@ module.exports['Successor'] = { }, "minute" : { "type" : "Literal", - "localId" : "348", + "localId" : "354", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7565,7 +8481,7 @@ module.exports['Successor'] = { }, "second" : { "type" : "Literal", - "localId" : "349", + "localId" : "355", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7573,7 +8489,7 @@ module.exports['Successor'] = { }, "millisecond" : { "type" : "Literal", - "localId" : "350", + "localId" : "356", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -7582,7 +8498,7 @@ module.exports['Successor'] = { } } }, { - "localId" : "372", + "localId" : "378", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "max_date", "context" : "Patient", @@ -7591,17 +8507,17 @@ module.exports['Successor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "372", + "r" : "378", "s" : [ { "value" : [ "", "define ", "max_date", ": " ] }, { - "r" : "397", + "r" : "403", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "389", + "r" : "395", "s" : [ { - "r" : "373", + "r" : "379", "value" : [ "DateTime", "(", "9999", ",", "12", ",", "31", ",", "23", ",", "59", ",", "59", ",", "999", ")" ] } ] } ] @@ -7610,59 +8526,59 @@ module.exports['Successor'] = { } ], "expression" : { "type" : "Successor", - "localId" : "397", + "localId" : "403", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "398", + "localId" : "404", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "389", + "localId" : "395", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "390", + "localId" : "396", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "391", + "localId" : "397", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "392", + "localId" : "398", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "393", + "localId" : "399", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "394", + "localId" : "400", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "395", + "localId" : "401", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "396", + "localId" : "402", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "373", + "localId" : "379", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "9999", @@ -7670,7 +8586,7 @@ module.exports['Successor'] = { }, "month" : { "type" : "Literal", - "localId" : "374", + "localId" : "380", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -7678,7 +8594,7 @@ module.exports['Successor'] = { }, "day" : { "type" : "Literal", - "localId" : "375", + "localId" : "381", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "31", @@ -7686,7 +8602,7 @@ module.exports['Successor'] = { }, "hour" : { "type" : "Literal", - "localId" : "376", + "localId" : "382", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "23", @@ -7694,7 +8610,7 @@ module.exports['Successor'] = { }, "minute" : { "type" : "Literal", - "localId" : "377", + "localId" : "383", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "59", @@ -7702,7 +8618,7 @@ module.exports['Successor'] = { }, "second" : { "type" : "Literal", - "localId" : "378", + "localId" : "384", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "59", @@ -7710,7 +8626,7 @@ module.exports['Successor'] = { }, "millisecond" : { "type" : "Literal", - "localId" : "379", + "localId" : "385", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "999", @@ -7728,6 +8644,7 @@ library TestSnippet version '1' using Simple version '1.0.0' context Patient define Is: predecessor of 2 +define Ls: predecessor of 2L define Rs: predecessor of 2.2 define ufr: predecessor of -2147483648 define y_date: predecessor of DateTime(2015) @@ -7752,7 +8669,7 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "374", + "r" : "380", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -7868,8 +8785,8 @@ module.exports['Predecessor'] = { } }, { "localId" : "220", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "Rs", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "Ls", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -7878,12 +8795,12 @@ module.exports['Predecessor'] = { "s" : { "r" : "220", "s" : [ { - "value" : [ "", "define ", "Rs", ": " ] + "value" : [ "", "define ", "Ls", ": " ] }, { "r" : "222", "s" : [ { "r" : "221", - "value" : [ "predecessor of ", "2.2" ] + "value" : [ "predecessor of ", "2L" ] } ] } ] } @@ -7891,17 +8808,59 @@ module.exports['Predecessor'] = { "expression" : { "type" : "Predecessor", "localId" : "222", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "223", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", "localId" : "221", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } + } + }, { + "localId" : "226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "Rs", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "226", + "s" : [ { + "value" : [ "", "define ", "Rs", ": " ] + }, { + "r" : "228", + "s" : [ { + "r" : "227", + "value" : [ "predecessor of ", "2.2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "228", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "229", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "227", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "2.2", @@ -7909,7 +8868,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "226", + "localId" : "232", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "ufr", "context" : "Patient", @@ -7918,17 +8877,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "226", + "r" : "232", "s" : [ { "value" : [ "", "define ", "ufr", ": " ] }, { - "r" : "230", + "r" : "236", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "227", + "r" : "233", "s" : [ { - "r" : "228", + "r" : "234", "value" : [ "-", "2147483648" ] } ] } ] @@ -7937,29 +8896,29 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "230", + "localId" : "236", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "231", + "localId" : "237", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Negate", - "localId" : "227", + "localId" : "233", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "229", + "localId" : "235", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "228", + "localId" : "234", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2147483648", @@ -7968,7 +8927,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "234", + "localId" : "240", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "y_date", "context" : "Patient", @@ -7977,17 +8936,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "240", "s" : [ { "value" : [ "", "define ", "y_date", ": " ] }, { - "r" : "241", + "r" : "247", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "239", + "r" : "245", "s" : [ { - "r" : "235", + "r" : "241", "value" : [ "DateTime", "(", "2015", ")" ] } ] } ] @@ -7996,29 +8955,29 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "241", + "localId" : "247", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "242", + "localId" : "248", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "239", + "localId" : "245", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "240", + "localId" : "246", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "235", + "localId" : "241", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8027,7 +8986,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "245", + "localId" : "251", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ym_date", "context" : "Patient", @@ -8036,17 +8995,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "245", + "r" : "251", "s" : [ { "value" : [ "", "define ", "ym_date", ": " ] }, { - "r" : "255", + "r" : "261", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "252", + "r" : "258", "s" : [ { - "r" : "246", + "r" : "252", "value" : [ "DateTime", "(", "2015", ",", "01", ")" ] } ] } ] @@ -8055,34 +9014,34 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "255", + "localId" : "261", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "256", + "localId" : "262", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "252", + "localId" : "258", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "253", + "localId" : "259", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "254", + "localId" : "260", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "246", + "localId" : "252", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8090,7 +9049,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "247", + "localId" : "253", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8099,7 +9058,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "259", + "localId" : "265", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymd_date", "context" : "Patient", @@ -8108,17 +9067,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "259", + "r" : "265", "s" : [ { "value" : [ "", "define ", "ymd_date", ": " ] }, { - "r" : "272", + "r" : "278", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "268", + "r" : "274", "s" : [ { - "r" : "260", + "r" : "266", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ")" ] } ] } ] @@ -8127,39 +9086,39 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "272", + "localId" : "278", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "273", + "localId" : "279", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "268", + "localId" : "274", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "269", + "localId" : "275", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "270", + "localId" : "276", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "271", + "localId" : "277", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "260", + "localId" : "266", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8167,7 +9126,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "261", + "localId" : "267", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8175,7 +9134,7 @@ module.exports['Predecessor'] = { }, "day" : { "type" : "Literal", - "localId" : "262", + "localId" : "268", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8184,7 +9143,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "276", + "localId" : "282", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdh_date", "context" : "Patient", @@ -8193,17 +9152,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "276", + "r" : "282", "s" : [ { "value" : [ "", "define ", "ymdh_date", ": " ] }, { - "r" : "292", + "r" : "298", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "287", + "r" : "293", "s" : [ { - "r" : "277", + "r" : "283", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ")" ] } ] } ] @@ -8212,44 +9171,44 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "292", + "localId" : "298", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "293", + "localId" : "299", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "287", + "localId" : "293", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "288", + "localId" : "294", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "289", + "localId" : "295", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "290", + "localId" : "296", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "291", + "localId" : "297", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "277", + "localId" : "283", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8257,7 +9216,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "278", + "localId" : "284", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8265,7 +9224,7 @@ module.exports['Predecessor'] = { }, "day" : { "type" : "Literal", - "localId" : "279", + "localId" : "285", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8273,7 +9232,7 @@ module.exports['Predecessor'] = { }, "hour" : { "type" : "Literal", - "localId" : "280", + "localId" : "286", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8282,7 +9241,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "296", + "localId" : "302", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdhm_date", "context" : "Patient", @@ -8291,17 +9250,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "296", + "r" : "302", "s" : [ { "value" : [ "", "define ", "ymdhm_date", ": " ] }, { - "r" : "315", + "r" : "321", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "309", + "r" : "315", "s" : [ { - "r" : "297", + "r" : "303", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ",", "0", ")" ] } ] } ] @@ -8310,49 +9269,49 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "315", + "localId" : "321", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "316", + "localId" : "322", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "309", + "localId" : "315", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "310", + "localId" : "316", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "311", + "localId" : "317", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "312", + "localId" : "318", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "313", + "localId" : "319", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "314", + "localId" : "320", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "297", + "localId" : "303", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8360,7 +9319,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "298", + "localId" : "304", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8368,7 +9327,7 @@ module.exports['Predecessor'] = { }, "day" : { "type" : "Literal", - "localId" : "299", + "localId" : "305", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8376,7 +9335,7 @@ module.exports['Predecessor'] = { }, "hour" : { "type" : "Literal", - "localId" : "300", + "localId" : "306", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8384,7 +9343,7 @@ module.exports['Predecessor'] = { }, "minute" : { "type" : "Literal", - "localId" : "301", + "localId" : "307", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8393,7 +9352,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "319", + "localId" : "325", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdhms_date", "context" : "Patient", @@ -8402,17 +9361,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "319", + "r" : "325", "s" : [ { "value" : [ "", "define ", "ymdhms_date", ": " ] }, { - "r" : "341", + "r" : "347", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "334", + "r" : "340", "s" : [ { - "r" : "320", + "r" : "326", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ",", "0", ",", "0", ")" ] } ] } ] @@ -8421,54 +9380,54 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "341", + "localId" : "347", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "342", + "localId" : "348", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "334", + "localId" : "340", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "335", + "localId" : "341", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "336", + "localId" : "342", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "337", + "localId" : "343", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "338", + "localId" : "344", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "339", + "localId" : "345", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "340", + "localId" : "346", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "320", + "localId" : "326", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8476,7 +9435,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "321", + "localId" : "327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8484,7 +9443,7 @@ module.exports['Predecessor'] = { }, "day" : { "type" : "Literal", - "localId" : "322", + "localId" : "328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8492,7 +9451,7 @@ module.exports['Predecessor'] = { }, "hour" : { "type" : "Literal", - "localId" : "323", + "localId" : "329", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8500,7 +9459,7 @@ module.exports['Predecessor'] = { }, "minute" : { "type" : "Literal", - "localId" : "324", + "localId" : "330", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8508,7 +9467,7 @@ module.exports['Predecessor'] = { }, "second" : { "type" : "Literal", - "localId" : "325", + "localId" : "331", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8517,7 +9476,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "345", + "localId" : "351", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "ymdhmsm_date", "context" : "Patient", @@ -8526,17 +9485,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "345", + "r" : "351", "s" : [ { "value" : [ "", "define ", "ymdhmsm_date", ": " ] }, { - "r" : "370", + "r" : "376", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "362", + "r" : "368", "s" : [ { - "r" : "346", + "r" : "352", "value" : [ "DateTime", "(", "2015", ",", "01", ",", "01", ",", "0", ",", "0", ",", "0", ",", "0", ")" ] } ] } ] @@ -8545,59 +9504,59 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "370", + "localId" : "376", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "371", + "localId" : "377", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "362", + "localId" : "368", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "363", + "localId" : "369", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "364", + "localId" : "370", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "365", + "localId" : "371", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "366", + "localId" : "372", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "367", + "localId" : "373", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "368", + "localId" : "374", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "369", + "localId" : "375", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "346", + "localId" : "352", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2015", @@ -8605,7 +9564,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "347", + "localId" : "353", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8613,7 +9572,7 @@ module.exports['Predecessor'] = { }, "day" : { "type" : "Literal", - "localId" : "348", + "localId" : "354", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8621,7 +9580,7 @@ module.exports['Predecessor'] = { }, "hour" : { "type" : "Literal", - "localId" : "349", + "localId" : "355", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8629,7 +9588,7 @@ module.exports['Predecessor'] = { }, "minute" : { "type" : "Literal", - "localId" : "350", + "localId" : "356", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8637,7 +9596,7 @@ module.exports['Predecessor'] = { }, "second" : { "type" : "Literal", - "localId" : "351", + "localId" : "357", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8645,7 +9604,7 @@ module.exports['Predecessor'] = { }, "millisecond" : { "type" : "Literal", - "localId" : "352", + "localId" : "358", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8654,7 +9613,7 @@ module.exports['Predecessor'] = { } } }, { - "localId" : "374", + "localId" : "380", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "min_date", "context" : "Patient", @@ -8663,17 +9622,17 @@ module.exports['Predecessor'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "374", + "r" : "380", "s" : [ { "value" : [ "", "define ", "min_date", ": " ] }, { - "r" : "399", + "r" : "405", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "391", + "r" : "397", "s" : [ { - "r" : "375", + "r" : "381", "value" : [ "DateTime", "(", "0001", ",", "01", ",", "01", ",", "0", ",", "0", ",", "0", ",", "0", ")" ] } ] } ] @@ -8682,59 +9641,59 @@ module.exports['Predecessor'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "399", + "localId" : "405", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "400", + "localId" : "406", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "DateTime", - "localId" : "391", + "localId" : "397", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "392", + "localId" : "398", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "393", + "localId" : "399", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "394", + "localId" : "400", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "395", + "localId" : "401", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "396", + "localId" : "402", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "397", + "localId" : "403", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "398", + "localId" : "404", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "375", + "localId" : "381", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0001", @@ -8742,7 +9701,7 @@ module.exports['Predecessor'] = { }, "month" : { "type" : "Literal", - "localId" : "376", + "localId" : "382", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8750,7 +9709,7 @@ module.exports['Predecessor'] = { }, "day" : { "type" : "Literal", - "localId" : "377", + "localId" : "383", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "01", @@ -8758,7 +9717,7 @@ module.exports['Predecessor'] = { }, "hour" : { "type" : "Literal", - "localId" : "378", + "localId" : "384", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8766,7 +9725,7 @@ module.exports['Predecessor'] = { }, "minute" : { "type" : "Literal", - "localId" : "379", + "localId" : "385", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8774,7 +9733,7 @@ module.exports['Predecessor'] = { }, "second" : { "type" : "Literal", - "localId" : "380", + "localId" : "386", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -8782,7 +9741,7 @@ module.exports['Predecessor'] = { }, "millisecond" : { "type" : "Literal", - "localId" : "381", + "localId" : "387", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -10440,66 +11399,144 @@ using Simple version '1.0.0' context Patient define IntegerAddOverflow: maximum Integer + 1 define IntegerAddUnderflow: minimum Integer + -1 +define IntegerAddNearOverflow: maximum Integer + 0 +define IntegerAddNearUnderflow: minimum Integer + 0 define IntegerSubtractOverflow: maximum Integer - -1 define IntegerSubtractUnderflow: minimum Integer - 1 +define IntegerSubtractNearOverflow: maximum Integer - 0 +define IntegerSubtractNearUnderflow: minimum Integer - 0 define IntegerMultiplyOverflow: maximum Integer * 2 -define IntegerMultiplyUnderflow: minimum Integer * -2 -define IntegerDivideOverflow: maximum Integer / (0.5) -define IntegerDivideUnderflow: minimum Integer / (-0.5) +define IntegerMultiplyUnderflow: minimum Integer * 2 +define IntegerMultiplyNearOverflow: maximum Integer * 1 +define IntegerMultiplyNearUnderflow: minimum Integer * 1 +define IntegerDivideOverflow: maximum Integer / 0.5 +define IntegerDivideUnderflow: minimum Integer / 0.5 +define IntegerDivideNearOverflow: maximum Integer / 1 +define IntegerDivideNearUnderflow: minimum Integer / 1 define IntegerDivideByZero: 1 / 0 define IntegerPowerOverflow: (maximum Integer)^3 define IntegerPowerUnderflow: (minimum Integer)^3 +define IntegerPowerNearOverflow: (maximum Integer)^1 +define IntegerPowerNearUnderflow: (minimum Integer)^1 define IntegerSuccessorOverflow: successor of maximum Integer define IntegerPredecessorUnderflow: predecessor of minimum Integer +define IntegerSuccessorNearOverflow: successor of (maximum Integer - 1) +define IntegerPredecessorNearUnderflow: predecessor of (minimum Integer + 1) + +define LongAddOverflow: maximum Long + 1L +define LongAddUnderflow: minimum Long + -1L +define LongAddNearOverflow: maximum Long + 0L +define LongAddNearUnderflow: minimum Long + 0L +define LongSubtractOverflow: maximum Long - -1L +define LongSubtractUnderflow: minimum Long - 1L +define LongSubtractNearOverflow: maximum Long - 0L +define LongSubtractNearUnderflow: minimum Long - 0L +define LongMultiplyOverflow: maximum Long * 2L +define LongMultiplyUnderflow: minimum Long * 2L +define LongMultiplyNearOverflow: maximum Long * 1L +define LongMultiplyNearUnderflow: minimum Long * 1L +define LongDivideOverflow: maximum Long / 0.5 +define LongDivideUnderflow: minimum Long / 0.5 +define LongDivideNearOverflow: maximum Long / 1L +define LongDivideNearUnderflow: minimum Long / 1L +define LongDivideByZero: 1L / 0L +define LongPowerOverflow: (maximum Long)^3L +define LongPowerUnderflow: (minimum Long)^3L +define LongPowerNearOverflow: (maximum Long)^1L +define LongPowerNearUnderflow: (minimum Long)^1L +define LongSuccessorOverflow: successor of maximum Long +define LongPredecessorUnderflow: predecessor of minimum Long +define LongSuccessorNearOverflow: successor of (maximum Long - 1L) +define LongPredecessorNearUnderflow: predecessor of (minimum Long + 1L) define DecimalAddOverflow: maximum Decimal + 1.0 define DecimalAddUnderflow: minimum Decimal + -1.0 +define DecimalAddNearOverflow: maximum Decimal + 0.0 +define DecimalAddNearUnderflow: minimum Decimal + 0.0 define DecimalSubtractOverflow: maximum Decimal - -1.0 define DecimalSubtractUnderflow: minimum Decimal - 1.0 +define DecimalSubtractNearOverflow: maximum Decimal - 0.0 +define DecimalSubtractNearUnderflow: minimum Decimal - 0.0 define DecimalMultiplyOverflow: maximum Decimal * 2 -define DecimalMultiplyUnderflow: minimum Decimal * -2 -define DecimalDivideOverflow: maximum Decimal / (0.5) -define DecimalDivideUnderflow: minimum Decimal / (-0.5) +define DecimalMultiplyUnderflow: minimum Decimal * 2 +define DecimalMultiplyNearOverflow: maximum Decimal * 1 +define DecimalMultiplyNearUnderflow: minimum Decimal * 1 +define DecimalDivideOverflow: maximum Decimal / 0.5 +define DecimalDivideUnderflow: minimum Decimal / 0.5 +define DecimalDivideNearOverflow: maximum Decimal / 1.0 +define DecimalDivideNearUnderflow: minimum Decimal / 1.0 define DecimalDivideByZero: 1.0 / 0 define DecimalPowerOverflow: (maximum Decimal)^2 define DecimalPowerUnderflow: (minimum Decimal)^3 +define DecimalPowerNearOverflow: (maximum Decimal)^1 +define DecimalPowerNearUnderflow: (minimum Decimal)^1 define DecimalSuccessorOverflow: successor of maximum Decimal define DecimalPredecessorUnderflow: predecessor of minimum Decimal +define DecimalSuccessorNearOverflow: successor of (maximum Decimal - 0.00000001) +define DecimalPredecessorNearUnderflow: predecessor of (minimum Decimal + 0.00000001) define MaxQuantity: Quantity { value: maximum Decimal, unit: 'mm' } define MinQuantity: Quantity { value: minimum Decimal, unit: 'mm' } define QuantityAddOverflow: MaxQuantity + 1.0 'mm' define QuantityAddUnderflow: MinQuantity + (-1.0 'mm') +define QuantityAddNearOverflow: MaxQuantity + 0.0 'mm' +define QuantityAddNearUnderflow: MinQuantity + 0.0 'mm' define QuantitySubtractOverflow: MaxQuantity - (-1 'mm') define QuantitySubtractUnderflow: MinQuantity - 1 'mm' +define QuantitySubtractNearOverflow: MaxQuantity - 0.0 'mm' +define QuantitySubtractNearUnderflow: MinQuantity - 0.0 'mm' define QuantityMultiplyOverflow: MaxQuantity * 2 'mm' define QuantityMultiplyUnderflow: MinQuantity * 2 'mm' +define QuantityMultiplyNearOverflow: MaxQuantity * 1 'mm' +define QuantityMultiplyNearUnderflow: MinQuantity * 1 'mm' define QuantityDivideOverflow: MaxQuantity / 0.5 'mm' -define QuantityDivideUnderflow: MinQuantity / (-0.5 'mm') +define QuantityDivideUnderflow: MinQuantity / 0.5 'mm' +define QuantityDivideNearOverflow: MaxQuantity / 1 'mm' +define QuantityDivideNearUnderflow: MinQuantity / 1 'mm' define QuantityDivideByZero: 1.0 'mm' / 0 'mm' define QuantitySuccessorOverflow: successor of MaxQuantity define QuantityPredecessorUnderflow: predecessor of MinQuantity +define QuantitySuccessorNearOverflow: successor of Quantity { value: maximum Decimal - 0.00000001, unit: 'mm' } +define QuantityPredecessorNearUnderflow: predecessor of Quantity { value: minimum Decimal + 0.00000001, unit: 'mm' } define DateTimeAddOverflow: maximum DateTime + 1 day define DateTimeAddUnderflow: minimum DateTime + (-1 day) +define DateTimeAddNearOverflow: maximum DateTime + 0 days +define DateTimeAddNearUnderflow: minimum DateTime + 0 days define DateTimeSubtractOverflow: maximum DateTime - (-1 day) define DateTimeSubtractUnderflow: minimum DateTime - 1 day +define DateTimeSubtractNearOverflow: maximum DateTime - 0 days +define DateTimeSubtractNearUnderflow: minimum DateTime - 0 days define DateTimeSuccessorOverflow: successor of maximum DateTime define DateTimePredecessorUnderflow: predecessor of minimum DateTime +define DateTimeSuccessorNearOverflow: successor of (maximum DateTime - 1 millisecond) +define DateTimePredecessorNearUnderflow: predecessor of (minimum DateTime + 1 millisecond) define DateAddOverflow: maximum Date + 1 day define DateAddUnderflow: minimum Date + (-1 day) +define DateAddNearOverflow: maximum Date + 0 days +define DateAddNearUnderflow: minimum Date + 0 days define DateSubtractOverflow: maximum Date - (-1 day) define DateSubtractUnderflow: minimum Date - 1 day +define DateSubtractNearOverflow: maximum Date - 0 days +define DateSubtractNearUnderflow: minimum Date - 0 days define DateSuccessorOverflow: successor of maximum Date define DatePredecessorUnderflow: predecessor of minimum Date +define DateSuccessorNearOverflow: successor of (maximum Date - 1 day) +define DatePredecessorNearUnderflow: predecessor of (minimum Date + 1 day) define TimeAddOverflow: maximum Time + 1 second define TimeAddUnderflow: minimum Time + (-1 second) +define TimeAddNearOverflow: maximum Time + 0 seconds +define TimeAddNearUnderflow: minimum Time + 0 seconds define TimeSubtractOverflow: maximum Time - (-1 second) define TimeSubtractUnderflow: minimum Time - 1 second +define TimeSubtractNearOverflow: maximum Time - 0 seconds +define TimeSubtractNearUnderflow: minimum Time - 0 seconds define TimeSuccessorOverflow: successor of maximum Time define TimePredecessorUnderflow: predecessor of minimum Time +define TimeSuccessorNearOverflow: successor of (maximum Time - 1 millisecond) +define TimePredecessorNearUnderflow: predecessor of (minimum Time + 1 millisecond) define ExpOverflow: Exp(maximum Decimal) */ @@ -10516,7 +11553,7 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "751", + "r" : "1509", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -10734,7 +11771,7 @@ module.exports['OutOfBounds'] = { }, { "localId" : "234", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerSubtractOverflow", + "name" : "IntegerAddNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -10743,7 +11780,7 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "234", "s" : [ { - "value" : [ "", "define ", "IntegerSubtractOverflow", ": " ] + "value" : [ "", "define ", "IntegerAddNearOverflow", ": " ] }, { "r" : "235", "s" : [ { @@ -10756,31 +11793,26 @@ module.exports['OutOfBounds'] = { "value" : [ "Integer" ] } ] } ] - }, { - "value" : [ " - " ] }, { "r" : "238", - "s" : [ { - "r" : "239", - "value" : [ "-", "1" ] - } ] + "value" : [ " + ", "0" ] } ] } ] } } ], "expression" : { - "type" : "Subtract", + "type" : "Add", "localId" : "235", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "241", + "localId" : "239", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "242", + "localId" : "240", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], @@ -10791,124 +11823,117 @@ module.exports['OutOfBounds'] = { "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { - "type" : "Negate", + "type" : "Literal", "localId" : "238", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "240", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "239", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - } + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "0", + "annotation" : [ ] } ] } }, { - "localId" : "245", + "localId" : "243", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerSubtractUnderflow", + "name" : "IntegerAddNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "245", + "r" : "243", "s" : [ { - "value" : [ "", "define ", "IntegerSubtractUnderflow", ": " ] + "value" : [ "", "define ", "IntegerAddNearUnderflow", ": " ] }, { - "r" : "246", + "r" : "244", "s" : [ { - "r" : "248", + "r" : "246", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "247", + "r" : "245", "s" : [ { "value" : [ "Integer" ] } ] } ] }, { - "r" : "249", - "value" : [ " - ", "1" ] + "r" : "247", + "value" : [ " + ", "0" ] } ] } ] } } ], "expression" : { - "type" : "Subtract", - "localId" : "246", + "type" : "Add", + "localId" : "244", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "250", + "localId" : "248", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "251", + "localId" : "249", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "248", + "localId" : "246", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "249", + "localId" : "247", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", + "value" : "0", "annotation" : [ ] } ] } }, { - "localId" : "254", + "localId" : "252", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerMultiplyOverflow", + "name" : "IntegerSubtractOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "254", + "r" : "252", "s" : [ { - "value" : [ "", "define ", "IntegerMultiplyOverflow", ": " ] + "value" : [ "", "define ", "IntegerSubtractOverflow", ": " ] }, { - "r" : "255", + "r" : "253", "s" : [ { - "r" : "257", + "r" : "255", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "256", + "r" : "254", "s" : [ { "value" : [ "Integer" ] } ] } ] }, { - "r" : "258", - "value" : [ " * ", "2" ] + "value" : [ " - " ] + }, { + "r" : "256", + "s" : [ { + "r" : "257", + "value" : [ "-", "1" ] + } ] } ] } ] } } ], "expression" : { - "type" : "Multiply", - "localId" : "255", + "type" : "Subtract", + "localId" : "253", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { @@ -10924,23 +11949,35 @@ module.exports['OutOfBounds'] = { } ], "operand" : [ { "type" : "MaxValue", - "localId" : "257", + "localId" : "255", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { - "type" : "Literal", - "localId" : "258", + "type" : "Negate", + "localId" : "256", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "258", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "257", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } } ] } }, { "localId" : "263", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerMultiplyUnderflow", + "name" : "IntegerSubtractUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -10949,7 +11986,7 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "263", "s" : [ { - "value" : [ "", "define ", "IntegerMultiplyUnderflow", ": " ] + "value" : [ "", "define ", "IntegerSubtractUnderflow", ": " ] }, { "r" : "264", "s" : [ { @@ -10962,31 +11999,26 @@ module.exports['OutOfBounds'] = { "value" : [ "Integer" ] } ] } ] - }, { - "value" : [ " * " ] }, { "r" : "267", - "s" : [ { - "r" : "268", - "value" : [ "-", "2" ] - } ] + "value" : [ " - ", "1" ] } ] } ] } } ], "expression" : { - "type" : "Multiply", + "type" : "Subtract", "localId" : "264", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "270", + "localId" : "268", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "271", + "localId" : "269", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], @@ -10997,974 +12029,930 @@ module.exports['OutOfBounds'] = { "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { - "type" : "Negate", + "type" : "Literal", "localId" : "267", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "269", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "268", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - } + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] } ] } }, { - "localId" : "274", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "IntegerDivideOverflow", + "localId" : "272", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerSubtractNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "274", + "r" : "272", "s" : [ { - "value" : [ "", "define ", "IntegerDivideOverflow", ": " ] + "value" : [ "", "define ", "IntegerSubtractNearOverflow", ": " ] }, { - "r" : "275", + "r" : "273", "s" : [ { - "r" : "277", + "r" : "275", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "276", + "r" : "274", "s" : [ { "value" : [ "Integer" ] } ] } ] }, { - "value" : [ " / " ] - }, { - "r" : "278", - "s" : [ { - "r" : "278", - "value" : [ "(", "0.5", ")" ] - } ] + "r" : "276", + "value" : [ " - ", "0" ] } ] } ] } } ], "expression" : { - "type" : "Divide", - "localId" : "275", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Subtract", + "localId" : "273", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "282", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "277", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "283", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "278", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { - "type" : "ToDecimal", - "localId" : "280", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "281", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "MaxValue", - "localId" : "277", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } - }, { - "type" : "Literal", - "localId" : "278", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "0.5", + "type" : "MaxValue", + "localId" : "275", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "276", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "0", "annotation" : [ ] } ] } }, { - "localId" : "286", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "IntegerDivideUnderflow", + "localId" : "281", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerSubtractNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "286", + "r" : "281", "s" : [ { - "value" : [ "", "define ", "IntegerDivideUnderflow", ": " ] + "value" : [ "", "define ", "IntegerSubtractNearUnderflow", ": " ] }, { - "r" : "287", + "r" : "282", "s" : [ { - "r" : "289", + "r" : "284", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "288", + "r" : "283", "s" : [ { "value" : [ "Integer" ] } ] } ] }, { - "value" : [ " / " ] - }, { - "r" : "290", - "s" : [ { - "value" : [ "(" ] - }, { - "r" : "290", - "s" : [ { - "r" : "291", - "value" : [ "-", "0.5" ] - } ] - }, { - "value" : [ ")" ] - } ] + "r" : "285", + "value" : [ " - ", "0" ] } ] } ] } } ], "expression" : { - "type" : "Divide", - "localId" : "287", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Subtract", + "localId" : "282", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "296", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "286", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "297", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "287", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { - "type" : "ToDecimal", - "localId" : "294", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "295", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "MinValue", - "localId" : "289", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } + "type" : "MinValue", + "localId" : "284", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] }, { - "type" : "Negate", - "localId" : "290", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "292", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "291", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "0.5", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "285", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "0", + "annotation" : [ ] } ] } }, { - "localId" : "300", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "IntegerDivideByZero", + "localId" : "290", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerMultiplyOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "300", + "r" : "290", "s" : [ { - "value" : [ "", "define ", "IntegerDivideByZero", ": " ] + "value" : [ "", "define ", "IntegerMultiplyOverflow", ": " ] }, { - "r" : "301", + "r" : "291", "s" : [ { - "r" : "302", - "value" : [ "1", " / ", "0" ] + "r" : "293", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "292", + "s" : [ { + "value" : [ "Integer" ] + } ] + } ] + }, { + "r" : "294", + "value" : [ " * ", "2" ] } ] } ] } } ], "expression" : { - "type" : "Divide", - "localId" : "301", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Multiply", + "localId" : "291", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "310", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "295", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "311", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "296", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { - "type" : "ToDecimal", - "localId" : "305", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "306", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "302", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - } + "type" : "MaxValue", + "localId" : "293", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] }, { - "type" : "ToDecimal", - "localId" : "308", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "309", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "303", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "0", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "294", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] } ] } }, { - "localId" : "314", + "localId" : "299", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerPowerOverflow", + "name" : "IntegerMultiplyUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "314", + "r" : "299", "s" : [ { - "value" : [ "", "define ", "IntegerPowerOverflow", ": " ] + "value" : [ "", "define ", "IntegerMultiplyUnderflow", ": " ] }, { - "r" : "315", + "r" : "300", "s" : [ { - "r" : "317", + "r" : "302", "s" : [ { - "value" : [ "(" ] + "value" : [ "minimum", " " ] }, { - "r" : "317", + "r" : "301", "s" : [ { - "value" : [ "maximum", " " ] - }, { - "r" : "316", - "s" : [ { - "value" : [ "Integer" ] - } ] + "value" : [ "Integer" ] } ] - }, { - "value" : [ ")" ] } ] }, { - "r" : "318", - "value" : [ "^", "3" ] + "r" : "303", + "value" : [ " * ", "2" ] } ] } ] } } ], "expression" : { - "type" : "Power", - "localId" : "315", + "type" : "Multiply", + "localId" : "300", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "319", + "localId" : "304", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "320", + "localId" : "305", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { - "type" : "MaxValue", - "localId" : "317", + "type" : "MinValue", + "localId" : "302", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "318", + "localId" : "303", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "3", + "value" : "2", "annotation" : [ ] } ] } }, { - "localId" : "323", + "localId" : "308", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerPowerUnderflow", + "name" : "IntegerMultiplyNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "323", + "r" : "308", "s" : [ { - "value" : [ "", "define ", "IntegerPowerUnderflow", ": " ] + "value" : [ "", "define ", "IntegerMultiplyNearOverflow", ": " ] }, { - "r" : "324", + "r" : "309", "s" : [ { - "r" : "326", + "r" : "311", "s" : [ { - "value" : [ "(" ] + "value" : [ "maximum", " " ] }, { - "r" : "326", + "r" : "310", "s" : [ { - "value" : [ "minimum", " " ] - }, { - "r" : "325", - "s" : [ { - "value" : [ "Integer" ] - } ] + "value" : [ "Integer" ] } ] - }, { - "value" : [ ")" ] } ] }, { - "r" : "327", - "value" : [ "^", "3" ] + "r" : "312", + "value" : [ " * ", "1" ] } ] } ] } } ], "expression" : { - "type" : "Power", - "localId" : "324", + "type" : "Multiply", + "localId" : "309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "328", + "localId" : "313", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "329", + "localId" : "314", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { - "type" : "MinValue", - "localId" : "326", + "type" : "MaxValue", + "localId" : "311", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "327", + "localId" : "312", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "3", + "value" : "1", "annotation" : [ ] } ] } }, { - "localId" : "332", + "localId" : "317", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerSuccessorOverflow", + "name" : "IntegerMultiplyNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "332", + "r" : "317", "s" : [ { - "value" : [ "", "define ", "IntegerSuccessorOverflow", ": " ] + "value" : [ "", "define ", "IntegerMultiplyNearUnderflow", ": " ] }, { - "r" : "335", + "r" : "318", "s" : [ { - "value" : [ "successor of " ] - }, { - "r" : "334", + "r" : "320", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "minimum", " " ] }, { - "r" : "333", + "r" : "319", "s" : [ { "value" : [ "Integer" ] } ] } ] + }, { + "r" : "321", + "value" : [ " * ", "1" ] } ] } ] } } ], "expression" : { - "type" : "Successor", - "localId" : "335", + "type" : "Multiply", + "localId" : "318", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "336", + "localId" : "322", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "323", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "operand" : { - "type" : "MaxValue", - "localId" : "334", + "operand" : [ { + "type" : "MinValue", + "localId" : "320", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] - } + }, { + "type" : "Literal", + "localId" : "321", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } ] } }, { - "localId" : "339", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "IntegerPredecessorUnderflow", + "localId" : "326", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "IntegerDivideOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "339", + "r" : "326", "s" : [ { - "value" : [ "", "define ", "IntegerPredecessorUnderflow", ": " ] + "value" : [ "", "define ", "IntegerDivideOverflow", ": " ] }, { - "r" : "342", + "r" : "327", "s" : [ { - "value" : [ "predecessor of " ] - }, { - "r" : "341", + "r" : "329", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "maximum", " " ] }, { - "r" : "340", + "r" : "328", "s" : [ { "value" : [ "Integer" ] } ] } ] + }, { + "r" : "330", + "value" : [ " / ", "0.5" ] } ] } ] } } ], "expression" : { - "type" : "Predecessor", - "localId" : "342", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "type" : "Divide", + "localId" : "327", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "343", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + "localId" : "334", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "335", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], - "operand" : { - "type" : "MinValue", - "localId" : "341", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "operand" : [ { + "type" : "ToDecimal", + "localId" : "332", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "333", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "329", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "330", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.5", "annotation" : [ ] - } + } ] } }, { - "localId" : "346", + "localId" : "338", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalAddOverflow", + "name" : "IntegerDivideUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "346", + "r" : "338", "s" : [ { - "value" : [ "", "define ", "DecimalAddOverflow", ": " ] + "value" : [ "", "define ", "IntegerDivideUnderflow", ": " ] }, { - "r" : "347", + "r" : "339", "s" : [ { - "r" : "349", + "r" : "341", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "minimum", " " ] }, { - "r" : "348", + "r" : "340", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Integer" ] } ] } ] }, { - "r" : "350", - "value" : [ " + ", "1.0" ] + "r" : "342", + "value" : [ " / ", "0.5" ] } ] } ] } } ], "expression" : { - "type" : "Add", - "localId" : "347", + "type" : "Divide", + "localId" : "339", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "351", + "localId" : "346", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "352", + "localId" : "347", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { - "type" : "MaxValue", - "localId" : "349", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "344", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "345", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "341", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } }, { "type" : "Literal", - "localId" : "350", + "localId" : "342", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "1.0", + "value" : "0.5", "annotation" : [ ] } ] } }, { - "localId" : "355", + "localId" : "350", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalAddUnderflow", + "name" : "IntegerDivideNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "355", + "r" : "350", "s" : [ { - "value" : [ "", "define ", "DecimalAddUnderflow", ": " ] + "value" : [ "", "define ", "IntegerDivideNearOverflow", ": " ] }, { - "r" : "356", + "r" : "351", "s" : [ { - "r" : "358", + "r" : "353", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "maximum", " " ] }, { - "r" : "357", + "r" : "352", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Integer" ] } ] } ] }, { - "value" : [ " + " ] - }, { - "r" : "359", - "s" : [ { - "r" : "360", - "value" : [ "-", "1.0" ] - } ] + "r" : "354", + "value" : [ " / ", "1" ] } ] } ] } } ], "expression" : { - "type" : "Add", - "localId" : "356", + "type" : "Divide", + "localId" : "351", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "362", + "localId" : "361", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "363", + "localId" : "362", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { - "type" : "MinValue", - "localId" : "358", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "356", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "357", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "353", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } }, { - "type" : "Negate", + "type" : "ToDecimal", "localId" : "359", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "361", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "360", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "360", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "1.0", + "localId" : "354", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", "annotation" : [ ] } } ] } }, { - "localId" : "366", + "localId" : "365", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalSubtractOverflow", + "name" : "IntegerDivideNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "366", + "r" : "365", "s" : [ { - "value" : [ "", "define ", "DecimalSubtractOverflow", ": " ] + "value" : [ "", "define ", "IntegerDivideNearUnderflow", ": " ] }, { - "r" : "367", + "r" : "366", "s" : [ { - "r" : "369", + "r" : "368", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "minimum", " " ] }, { - "r" : "368", + "r" : "367", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Integer" ] } ] } ] }, { - "value" : [ " - " ] - }, { - "r" : "370", - "s" : [ { - "r" : "371", - "value" : [ "-", "1.0" ] - } ] + "r" : "369", + "value" : [ " / ", "1" ] } ] } ] } } ], "expression" : { - "type" : "Subtract", - "localId" : "367", + "type" : "Divide", + "localId" : "366", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "373", + "localId" : "376", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "374", + "localId" : "377", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { - "type" : "MaxValue", - "localId" : "369", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - }, { - "type" : "Negate", - "localId" : "370", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "ToDecimal", + "localId" : "371", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "372", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "368", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "374", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "375", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "371", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "1.0", + "localId" : "369", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", "annotation" : [ ] } } ] } }, { - "localId" : "377", + "localId" : "380", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalSubtractUnderflow", + "name" : "IntegerDivideByZero", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "377", + "r" : "380", "s" : [ { - "value" : [ "", "define ", "DecimalSubtractUnderflow", ": " ] + "value" : [ "", "define ", "IntegerDivideByZero", ": " ] }, { - "r" : "378", + "r" : "381", "s" : [ { - "r" : "380", - "s" : [ { - "value" : [ "minimum", " " ] - }, { - "r" : "379", - "s" : [ { - "value" : [ "Decimal" ] - } ] - } ] - }, { - "r" : "381", - "value" : [ " - ", "1.0" ] + "r" : "382", + "value" : [ "1", " / ", "0" ] } ] } ] } } ], "expression" : { - "type" : "Subtract", - "localId" : "378", + "type" : "Divide", + "localId" : "381", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "382", + "localId" : "390", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "383", + "localId" : "391", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { - "type" : "MinValue", - "localId" : "380", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "385", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "386", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "382", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } }, { - "type" : "Literal", - "localId" : "381", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "1.0", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "388", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "389", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "383", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "0", + "annotation" : [ ] + } } ] } }, { - "localId" : "386", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalMultiplyOverflow", + "localId" : "394", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerPowerOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "386", + "r" : "394", "s" : [ { - "value" : [ "", "define ", "DecimalMultiplyOverflow", ": " ] + "value" : [ "", "define ", "IntegerPowerOverflow", ": " ] }, { - "r" : "387", + "r" : "395", "s" : [ { - "r" : "389", + "r" : "397", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "(" ] }, { - "r" : "388", + "r" : "397", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "maximum", " " ] + }, { + "r" : "396", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "value" : [ ")" ] } ] }, { - "r" : "390", - "value" : [ " * ", "2" ] + "r" : "398", + "value" : [ "^", "3" ] } ] } ] } } ], "expression" : { - "type" : "Multiply", - "localId" : "387", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Power", + "localId" : "395", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "394", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "399", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "395", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "400", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "389", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "397", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { - "type" : "ToDecimal", - "localId" : "392", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "393", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "390", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "398", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "3", + "annotation" : [ ] } ] } }, { - "localId" : "398", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalMultiplyUnderflow", + "localId" : "403", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerPowerUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "398", + "r" : "403", "s" : [ { - "value" : [ "", "define ", "DecimalMultiplyUnderflow", ": " ] + "value" : [ "", "define ", "IntegerPowerUnderflow", ": " ] }, { - "r" : "399", + "r" : "404", "s" : [ { - "r" : "401", + "r" : "406", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "(" ] }, { - "r" : "400", + "r" : "406", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "minimum", " " ] + }, { + "r" : "405", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "value" : [ ")" ] } ] }, { - "value" : [ " * " ] - }, { - "r" : "402", - "s" : [ { - "r" : "403", - "value" : [ "-", "2" ] - } ] + "r" : "407", + "value" : [ "^", "3" ] } ] } ] } } ], "expression" : { - "type" : "Multiply", - "localId" : "399", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Power", + "localId" : "404", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "408", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", "localId" : "409", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "401", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "406", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { - "type" : "ToDecimal", - "localId" : "406", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "407", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Negate", - "localId" : "402", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "404", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "403", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - } - } + "type" : "Literal", + "localId" : "407", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "3", + "annotation" : [ ] } ] } }, { "localId" : "412", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalDivideOverflow", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerPowerNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -11973,66 +12961,68 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "412", "s" : [ { - "value" : [ "", "define ", "DecimalDivideOverflow", ": " ] + "value" : [ "", "define ", "IntegerPowerNearOverflow", ": " ] }, { "r" : "413", "s" : [ { "r" : "415", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "(" ] }, { - "r" : "414", + "r" : "415", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "maximum", " " ] + }, { + "r" : "414", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "value" : [ ")" ] } ] - }, { - "value" : [ " / " ] }, { "r" : "416", - "s" : [ { - "r" : "416", - "value" : [ "(", "0.5", ")" ] - } ] + "value" : [ "^", "1" ] } ] } ] } } ], "expression" : { - "type" : "Divide", + "type" : "Power", "localId" : "413", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "417", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", "localId" : "418", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", "localId" : "415", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "Literal", "localId" : "416", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "0.5", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", "annotation" : [ ] } ] } }, { "localId" : "421", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalDivideUnderflow", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerPowerNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -12041,231 +13031,255 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "421", "s" : [ { - "value" : [ "", "define ", "DecimalDivideUnderflow", ": " ] + "value" : [ "", "define ", "IntegerPowerNearUnderflow", ": " ] }, { "r" : "422", "s" : [ { "r" : "424", - "s" : [ { - "value" : [ "minimum", " " ] - }, { - "r" : "423", - "s" : [ { - "value" : [ "Decimal" ] - } ] - } ] - }, { - "value" : [ " / " ] - }, { - "r" : "425", "s" : [ { "value" : [ "(" ] }, { - "r" : "425", + "r" : "424", "s" : [ { - "r" : "426", - "value" : [ "-", "0.5" ] + "value" : [ "minimum", " " ] + }, { + "r" : "423", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] }, { "value" : [ ")" ] } ] + }, { + "r" : "425", + "value" : [ "^", "1" ] } ] } ] } } ], "expression" : { - "type" : "Divide", + "type" : "Power", "localId" : "422", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "428", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "426", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "429", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "427", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", "localId" : "424", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { - "type" : "Negate", + "type" : "Literal", "localId" : "425", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "427", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "426", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "0.5", - "annotation" : [ ] - } + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] } ] } }, { - "localId" : "432", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalDivideByZero", + "localId" : "430", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerSuccessorOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "432", + "r" : "430", "s" : [ { - "value" : [ "", "define ", "DecimalDivideByZero", ": " ] + "value" : [ "", "define ", "IntegerSuccessorOverflow", ": " ] }, { "r" : "433", "s" : [ { - "r" : "434", - "value" : [ "1.0", " / ", "0" ] + "value" : [ "successor of " ] + }, { + "r" : "432", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "431", + "s" : [ { + "value" : [ "Integer" ] + } ] + } ] } ] } ] } } ], "expression" : { - "type" : "Divide", + "type" : "Successor", "localId" : "433", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "439", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "434", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] - }, { + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "432", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } + } + }, { + "localId" : "437", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerPredecessorUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "437", + "s" : [ { + "value" : [ "", "define ", "IntegerPredecessorUnderflow", ": " ] + }, { + "r" : "440", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "439", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "438", + "s" : [ { + "value" : [ "Integer" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "440", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "440", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "441", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "operand" : [ { - "type" : "Literal", - "localId" : "434", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "1.0", + "operand" : { + "type" : "MinValue", + "localId" : "439", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] - }, { - "type" : "ToDecimal", - "localId" : "437", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "438", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "435", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "0", - "annotation" : [ ] - } - } ] + } } }, { - "localId" : "443", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalPowerOverflow", + "localId" : "444", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerSuccessorNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "443", + "r" : "444", "s" : [ { - "value" : [ "", "define ", "DecimalPowerOverflow", ": " ] + "value" : [ "", "define ", "IntegerSuccessorNearOverflow", ": " ] }, { - "r" : "444", + "r" : "451", "s" : [ { - "r" : "446", + "value" : [ "successor of " ] + }, { + "r" : "445", "s" : [ { "value" : [ "(" ] }, { - "r" : "446", + "r" : "445", "s" : [ { - "value" : [ "maximum", " " ] - }, { - "r" : "445", + "r" : "447", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "maximum", " " ] + }, { + "r" : "446", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "r" : "448", + "value" : [ " - ", "1" ] } ] }, { "value" : [ ")" ] } ] - }, { - "r" : "447", - "value" : [ "^", "2" ] } ] } ] } } ], "expression" : { - "type" : "Power", - "localId" : "444", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Successor", + "localId" : "451", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "451", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - }, { "type" : "NamedTypeSpecifier", "localId" : "452", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "operand" : [ { - "type" : "MaxValue", - "localId" : "446", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - }, { - "type" : "ToDecimal", - "localId" : "449", + "operand" : { + "type" : "Subtract", + "localId" : "445", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "449", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { "type" : "NamedTypeSpecifier", "localId" : "450", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "operand" : { - "type" : "Literal", + "operand" : [ { + "type" : "MaxValue", "localId" : "447", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", "annotation" : [ ] - } - } ] + }, { + "type" : "Literal", + "localId" : "448", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } ] + } } }, { "localId" : "455", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalPowerUnderflow", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "IntegerPredecessorNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -12274,749 +13288,686 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "455", "s" : [ { - "value" : [ "", "define ", "DecimalPowerUnderflow", ": " ] + "value" : [ "", "define ", "IntegerPredecessorNearUnderflow", ": " ] }, { - "r" : "456", + "r" : "462", "s" : [ { - "r" : "458", + "value" : [ "predecessor of " ] + }, { + "r" : "456", "s" : [ { "value" : [ "(" ] }, { - "r" : "458", + "r" : "456", "s" : [ { - "value" : [ "minimum", " " ] - }, { - "r" : "457", + "r" : "458", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "minimum", " " ] + }, { + "r" : "457", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "r" : "459", + "value" : [ " + ", "1" ] } ] }, { "value" : [ ")" ] } ] - }, { - "r" : "459", - "value" : [ "^", "3" ] } ] } ] } } ], "expression" : { - "type" : "Power", - "localId" : "456", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Predecessor", + "localId" : "462", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "463", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "464", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "operand" : [ { - "type" : "MinValue", - "localId" : "458", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - }, { - "type" : "ToDecimal", - "localId" : "461", + "operand" : { + "type" : "Add", + "localId" : "456", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "462", + "localId" : "460", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "461", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { + "type" : "MinValue", + "localId" : "458", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { "type" : "Literal", "localId" : "459", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "3", + "value" : "1", "annotation" : [ ] - } - } ] + } ] + } } }, { - "localId" : "467", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalSuccessorOverflow", + "localId" : "466", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongAddOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "467", + "r" : "466", "s" : [ { - "value" : [ "", "define ", "DecimalSuccessorOverflow", ": " ] + "value" : [ "", "define ", "LongAddOverflow", ": " ] }, { - "r" : "470", + "r" : "467", "s" : [ { - "value" : [ "successor of " ] - }, { "r" : "469", "s" : [ { "value" : [ "maximum", " " ] }, { "r" : "468", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Long" ] } ] } ] + }, { + "r" : "470", + "value" : [ " + ", "1L" ] } ] } ] } } ], "expression" : { - "type" : "Successor", - "localId" : "470", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Add", + "localId" : "467", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "471", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "472", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { "type" : "MaxValue", "localId" : "469", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] - } + }, { + "type" : "Literal", + "localId" : "470", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } ] } }, { - "localId" : "474", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalPredecessorUnderflow", + "localId" : "475", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongAddUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "474", + "r" : "475", "s" : [ { - "value" : [ "", "define ", "DecimalPredecessorUnderflow", ": " ] + "value" : [ "", "define ", "LongAddUnderflow", ": " ] }, { - "r" : "477", + "r" : "476", "s" : [ { - "value" : [ "predecessor of " ] - }, { - "r" : "476", + "r" : "478", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "475", + "r" : "477", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "Long" ] } ] } ] + }, { + "value" : [ " + " ] + }, { + "r" : "479", + "s" : [ { + "r" : "480", + "value" : [ "-", "1L" ] + } ] } ] } ] } } ], "expression" : { - "type" : "Predecessor", - "localId" : "477", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "Add", + "localId" : "476", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "478", - "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "482", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "483", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { "type" : "MinValue", - "localId" : "476", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "localId" : "478", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] - } - } - }, { - "localId" : "481", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MaxQuantity", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "481", - "s" : [ { - "value" : [ "", "define ", "MaxQuantity", ": " ] - }, { - "r" : "482", - "s" : [ { - "value" : [ "Quantity", " { " ] - }, { - "s" : [ { - "value" : [ "value", ": " ] - }, { - "r" : "485", - "s" : [ { - "value" : [ "maximum", " " ] - }, { - "r" : "484", - "s" : [ { - "value" : [ "Decimal" ] - } ] - } ] - } ] - }, { - "value" : [ ", " ] - }, { - "s" : [ { - "value" : [ "unit", ": " ] - }, { - "r" : "486", - "s" : [ { - "value" : [ "'mm'" ] - } ] - } ] - }, { - "value" : [ " }" ] - } ] - } ] - } - } ], - "expression" : { - "type" : "Instance", - "localId" : "482", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "classType" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ], - "element" : [ { - "name" : "value", - "value" : { - "type" : "MaxValue", - "localId" : "485", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - } }, { - "name" : "unit", - "value" : { + "type" : "Negate", + "localId" : "479", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "481", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { "type" : "Literal", - "localId" : "486", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "mm", + "localId" : "480", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", "annotation" : [ ] } } ] } }, { - "localId" : "490", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MinQuantity", + "localId" : "486", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongAddNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "490", + "r" : "486", "s" : [ { - "value" : [ "", "define ", "MinQuantity", ": " ] + "value" : [ "", "define ", "LongAddNearOverflow", ": " ] }, { - "r" : "491", + "r" : "487", "s" : [ { - "value" : [ "Quantity", " { " ] - }, { - "s" : [ { - "value" : [ "value", ": " ] - }, { - "r" : "494", - "s" : [ { - "value" : [ "minimum", " " ] - }, { - "r" : "493", - "s" : [ { - "value" : [ "Decimal" ] - } ] - } ] - } ] - }, { - "value" : [ ", " ] - }, { + "r" : "489", "s" : [ { - "value" : [ "unit", ": " ] + "value" : [ "maximum", " " ] }, { - "r" : "495", + "r" : "488", "s" : [ { - "value" : [ "'mm'" ] + "value" : [ "Long" ] } ] } ] }, { - "value" : [ " }" ] + "r" : "490", + "value" : [ " + ", "0L" ] } ] } ] } } ], "expression" : { - "type" : "Instance", - "localId" : "491", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "classType" : "{urn:hl7-org:elm-types:r1}Quantity", + "type" : "Add", + "localId" : "487", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], - "element" : [ { - "name" : "value", - "value" : { - "type" : "MinValue", - "localId" : "494", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "annotation" : [ ] - } + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "491", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] }, { - "name" : "unit", - "value" : { - "type" : "Literal", - "localId" : "495", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "mm", - "annotation" : [ ] - } + "type" : "NamedTypeSpecifier", + "localId" : "492", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "489", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "490", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "0", + "annotation" : [ ] } ] } }, { - "localId" : "499", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityAddOverflow", + "localId" : "495", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongAddNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "499", + "r" : "495", "s" : [ { - "value" : [ "", "define ", "QuantityAddOverflow", ": " ] + "value" : [ "", "define ", "LongAddNearUnderflow", ": " ] }, { - "r" : "500", + "r" : "496", "s" : [ { - "r" : "501", + "r" : "498", "s" : [ { - "value" : [ "MaxQuantity" ] + "value" : [ "minimum", " " ] + }, { + "r" : "497", + "s" : [ { + "value" : [ "Long" ] + } ] } ] }, { - "value" : [ " + " ] - }, { - "r" : "502", - "s" : [ { - "value" : [ "1.0 ", "'mm'" ] - } ] + "r" : "499", + "value" : [ " + ", "0L" ] } ] } ] } } ], "expression" : { "type" : "Add", - "localId" : "500", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "496", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "503", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "500", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "504", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "501", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "501", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MaxQuantity", + "type" : "MinValue", + "localId" : "498", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Quantity", - "localId" : "502", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1.0, - "unit" : "mm", + "type" : "Literal", + "localId" : "499", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "0", "annotation" : [ ] } ] } }, { - "localId" : "507", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityAddUnderflow", + "localId" : "504", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongSubtractOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "507", + "r" : "504", "s" : [ { - "value" : [ "", "define ", "QuantityAddUnderflow", ": " ] + "value" : [ "", "define ", "LongSubtractOverflow", ": " ] }, { - "r" : "508", + "r" : "505", "s" : [ { - "r" : "509", + "r" : "507", "s" : [ { - "value" : [ "MinQuantity" ] + "value" : [ "maximum", " " ] + }, { + "r" : "506", + "s" : [ { + "value" : [ "Long" ] + } ] } ] }, { - "value" : [ " + " ] + "value" : [ " - " ] }, { - "r" : "510", + "r" : "508", "s" : [ { - "value" : [ "(" ] - }, { - "r" : "510", - "s" : [ { - "value" : [ "-" ] - }, { - "r" : "511", - "s" : [ { - "value" : [ "1.0 ", "'mm'" ] - } ] - } ] - }, { - "value" : [ ")" ] + "r" : "509", + "value" : [ "-", "1L" ] } ] } ] } ] } } ], "expression" : { - "type" : "Add", - "localId" : "508", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "type" : "Subtract", + "localId" : "505", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "513", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "511", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "514", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "512", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "509", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MinQuantity", + "type" : "MaxValue", + "localId" : "507", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "510", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "508", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "512", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "510", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { - "type" : "Quantity", - "localId" : "511", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1.0, - "unit" : "mm", + "type" : "Literal", + "localId" : "509", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", "annotation" : [ ] } } ] } }, { - "localId" : "517", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantitySubtractOverflow", + "localId" : "515", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongSubtractUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "517", + "r" : "515", "s" : [ { - "value" : [ "", "define ", "QuantitySubtractOverflow", ": " ] + "value" : [ "", "define ", "LongSubtractUnderflow", ": " ] }, { - "r" : "518", + "r" : "516", "s" : [ { - "r" : "519", + "r" : "518", "s" : [ { - "value" : [ "MaxQuantity" ] - } ] - }, { - "value" : [ " - " ] - }, { - "r" : "520", - "s" : [ { - "value" : [ "(" ] + "value" : [ "minimum", " " ] }, { - "r" : "520", + "r" : "517", "s" : [ { - "value" : [ "-" ] - }, { - "r" : "521", - "s" : [ { - "value" : [ "1 ", "'mm'" ] - } ] + "value" : [ "Long" ] } ] - }, { - "value" : [ ")" ] } ] + }, { + "r" : "519", + "value" : [ " - ", "1L" ] } ] } ] } } ], "expression" : { "type" : "Subtract", - "localId" : "518", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "516", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "523", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "520", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "524", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "521", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "519", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MaxQuantity", + "type" : "MinValue", + "localId" : "518", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Negate", - "localId" : "520", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "522", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Quantity", - "localId" : "521", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "mm", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "519", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] } ] } }, { - "localId" : "527", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantitySubtractUnderflow", + "localId" : "524", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongSubtractNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "527", + "r" : "524", "s" : [ { - "value" : [ "", "define ", "QuantitySubtractUnderflow", ": " ] + "value" : [ "", "define ", "LongSubtractNearOverflow", ": " ] }, { - "r" : "528", + "r" : "525", "s" : [ { - "r" : "529", + "r" : "527", "s" : [ { - "value" : [ "MinQuantity" ] + "value" : [ "maximum", " " ] + }, { + "r" : "526", + "s" : [ { + "value" : [ "Long" ] + } ] } ] }, { - "value" : [ " - " ] - }, { - "r" : "530", - "s" : [ { - "value" : [ "1 ", "'mm'" ] - } ] + "r" : "528", + "value" : [ " - ", "0L" ] } ] } ] } } ], "expression" : { "type" : "Subtract", - "localId" : "528", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "525", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "531", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "529", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "532", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "530", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "529", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MinQuantity", + "type" : "MaxValue", + "localId" : "527", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Quantity", - "localId" : "530", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "mm", + "type" : "Literal", + "localId" : "528", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "0", "annotation" : [ ] } ] } }, { - "localId" : "535", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityMultiplyOverflow", + "localId" : "533", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongSubtractNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "535", + "r" : "533", "s" : [ { - "value" : [ "", "define ", "QuantityMultiplyOverflow", ": " ] + "value" : [ "", "define ", "LongSubtractNearUnderflow", ": " ] }, { - "r" : "536", + "r" : "534", "s" : [ { - "r" : "537", + "r" : "536", "s" : [ { - "value" : [ "MaxQuantity" ] + "value" : [ "minimum", " " ] + }, { + "r" : "535", + "s" : [ { + "value" : [ "Long" ] + } ] } ] }, { - "value" : [ " * " ] - }, { - "r" : "538", - "s" : [ { - "value" : [ "2 ", "'mm'" ] - } ] + "r" : "537", + "value" : [ " - ", "0L" ] } ] } ] } } ], "expression" : { - "type" : "Multiply", - "localId" : "536", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "type" : "Subtract", + "localId" : "534", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "539", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "538", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "540", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "539", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "537", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MaxQuantity", + "type" : "MinValue", + "localId" : "536", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Quantity", - "localId" : "538", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 2, - "unit" : "mm", + "type" : "Literal", + "localId" : "537", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "0", "annotation" : [ ] } ] } }, { - "localId" : "543", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityMultiplyUnderflow", + "localId" : "542", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongMultiplyOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "543", + "r" : "542", "s" : [ { - "value" : [ "", "define ", "QuantityMultiplyUnderflow", ": " ] + "value" : [ "", "define ", "LongMultiplyOverflow", ": " ] }, { - "r" : "544", + "r" : "543", "s" : [ { "r" : "545", "s" : [ { - "value" : [ "MinQuantity" ] + "value" : [ "maximum", " " ] + }, { + "r" : "544", + "s" : [ { + "value" : [ "Long" ] + } ] } ] - }, { - "value" : [ " * " ] }, { "r" : "546", - "s" : [ { - "value" : [ "2 ", "'mm'" ] - } ] + "value" : [ " * ", "2L" ] } ] } ] } } ], "expression" : { "type" : "Multiply", - "localId" : "544", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "543", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "547", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", "localId" : "548", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", + "type" : "MaxValue", "localId" : "545", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MinQuantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Quantity", + "type" : "Literal", "localId" : "546", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 2, - "unit" : "mm", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", "annotation" : [ ] } ] } }, { "localId" : "551", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityDivideOverflow", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongMultiplyUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -13025,146 +13976,124 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "551", "s" : [ { - "value" : [ "", "define ", "QuantityDivideOverflow", ": " ] + "value" : [ "", "define ", "LongMultiplyUnderflow", ": " ] }, { "r" : "552", "s" : [ { - "r" : "553", - "s" : [ { - "value" : [ "MaxQuantity" ] - } ] - }, { - "value" : [ " / " ] - }, { "r" : "554", "s" : [ { - "value" : [ "0.5 ", "'mm'" ] + "value" : [ "minimum", " " ] + }, { + "r" : "553", + "s" : [ { + "value" : [ "Long" ] + } ] } ] + }, { + "r" : "555", + "value" : [ " * ", "2L" ] } ] } ] } } ], "expression" : { - "type" : "Divide", + "type" : "Multiply", "localId" : "552", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "555", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "556", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "556", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "557", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "553", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MaxQuantity", + "type" : "MinValue", + "localId" : "554", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Quantity", - "localId" : "554", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 0.5, - "unit" : "mm", + "type" : "Literal", + "localId" : "555", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", "annotation" : [ ] } ] } }, { - "localId" : "559", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityDivideUnderflow", + "localId" : "560", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongMultiplyNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "559", + "r" : "560", "s" : [ { - "value" : [ "", "define ", "QuantityDivideUnderflow", ": " ] + "value" : [ "", "define ", "LongMultiplyNearOverflow", ": " ] }, { - "r" : "560", + "r" : "561", "s" : [ { - "r" : "561", - "s" : [ { - "value" : [ "MinQuantity" ] - } ] - }, { - "value" : [ " / " ] - }, { - "r" : "562", + "r" : "563", "s" : [ { - "value" : [ "(" ] + "value" : [ "maximum", " " ] }, { "r" : "562", "s" : [ { - "value" : [ "-" ] - }, { - "r" : "563", - "s" : [ { - "value" : [ "0.5 ", "'mm'" ] - } ] + "value" : [ "Long" ] } ] - }, { - "value" : [ ")" ] } ] + }, { + "r" : "564", + "value" : [ " * ", "1L" ] } ] } ] } } ], "expression" : { - "type" : "Divide", - "localId" : "560", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "type" : "Multiply", + "localId" : "561", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "565", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", "localId" : "566", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "ExpressionRef", - "localId" : "561", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MinQuantity", + "type" : "MaxValue", + "localId" : "563", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Negate", - "localId" : "562", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "564", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Quantity", - "localId" : "563", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 0.5, - "unit" : "mm", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "564", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] } ] } }, { "localId" : "569", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityDivideByZero", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongMultiplyNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -13173,178 +14102,5396 @@ module.exports['OutOfBounds'] = { "s" : { "r" : "569", "s" : [ { - "value" : [ "", "define ", "QuantityDivideByZero", ": " ] + "value" : [ "", "define ", "LongMultiplyNearUnderflow", ": " ] }, { "r" : "570", "s" : [ { - "r" : "571", - "s" : [ { - "value" : [ "1.0 ", "'mm'" ] - } ] - }, { - "value" : [ " / " ] - }, { "r" : "572", "s" : [ { - "value" : [ "0 ", "'mm'" ] + "value" : [ "minimum", " " ] + }, { + "r" : "571", + "s" : [ { + "value" : [ "Long" ] + } ] } ] + }, { + "r" : "573", + "value" : [ " * ", "1L" ] } ] } ] } } ], "expression" : { - "type" : "Divide", + "type" : "Multiply", "localId" : "570", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "573", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "574", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "574", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "575", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "Quantity", - "localId" : "571", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1.0, - "unit" : "mm", + "type" : "MinValue", + "localId" : "572", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { - "type" : "Quantity", - "localId" : "572", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 0, - "unit" : "mm", + "type" : "Literal", + "localId" : "573", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", "annotation" : [ ] } ] } }, { - "localId" : "577", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantitySuccessorOverflow", + "localId" : "578", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "LongDivideOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "577", + "r" : "578", "s" : [ { - "value" : [ "", "define ", "QuantitySuccessorOverflow", ": " ] + "value" : [ "", "define ", "LongDivideOverflow", ": " ] }, { "r" : "579", "s" : [ { - "value" : [ "successor of " ] - }, { - "r" : "578", + "r" : "581", "s" : [ { - "value" : [ "MaxQuantity" ] + "value" : [ "maximum", " " ] + }, { + "r" : "580", + "s" : [ { + "value" : [ "Long" ] + } ] } ] + }, { + "r" : "582", + "value" : [ " / ", "0.5" ] } ] } ] } } ], "expression" : { - "type" : "Successor", + "type" : "Divide", "localId" : "579", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "580", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "586", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "587", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], - "operand" : { - "type" : "ExpressionRef", - "localId" : "578", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MaxQuantity", + "operand" : [ { + "type" : "ToDecimal", + "localId" : "584", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "585", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "581", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "582", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.5", "annotation" : [ ] - } + } ] } }, { - "localId" : "583", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "QuantityPredecessorUnderflow", + "localId" : "590", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "LongDivideUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "583", + "r" : "590", "s" : [ { - "value" : [ "", "define ", "QuantityPredecessorUnderflow", ": " ] + "value" : [ "", "define ", "LongDivideUnderflow", ": " ] }, { - "r" : "585", + "r" : "591", "s" : [ { - "value" : [ "predecessor of " ] - }, { - "r" : "584", + "r" : "593", "s" : [ { - "value" : [ "MinQuantity" ] + "value" : [ "minimum", " " ] + }, { + "r" : "592", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "r" : "594", + "value" : [ " / ", "0.5" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "591", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "598", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "599", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "596", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "597", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "593", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "594", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.5", + "annotation" : [ ] + } ] + } + }, { + "localId" : "602", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "LongDivideNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "602", + "s" : [ { + "value" : [ "", "define ", "LongDivideNearOverflow", ": " ] + }, { + "r" : "603", + "s" : [ { + "r" : "605", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "604", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "r" : "606", + "value" : [ " / ", "1L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "603", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "613", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "614", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "608", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "609", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "605", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "611", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "612", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "606", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "617", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "LongDivideNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "617", + "s" : [ { + "value" : [ "", "define ", "LongDivideNearUnderflow", ": " ] + }, { + "r" : "618", + "s" : [ { + "r" : "620", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "619", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "r" : "621", + "value" : [ " / ", "1L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "618", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "628", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "629", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "623", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "624", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "620", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "626", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "627", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "621", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "632", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "LongDivideByZero", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "632", + "s" : [ { + "value" : [ "", "define ", "LongDivideByZero", ": " ] + }, { + "r" : "633", + "s" : [ { + "r" : "634", + "value" : [ "1L", " / ", "0L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "633", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "642", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "643", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "637", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "638", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "634", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "640", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "641", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "635", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "0", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "646", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongPowerOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "646", + "s" : [ { + "value" : [ "", "define ", "LongPowerOverflow", ": " ] + }, { + "r" : "647", + "s" : [ { + "r" : "649", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "649", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "648", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "650", + "value" : [ "^", "3L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "647", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "651", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "652", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "649", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "650", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + } ] + } + }, { + "localId" : "655", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongPowerUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "655", + "s" : [ { + "value" : [ "", "define ", "LongPowerUnderflow", ": " ] + }, { + "r" : "656", + "s" : [ { + "r" : "658", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "658", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "657", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "659", + "value" : [ "^", "3L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "656", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "660", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "661", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "658", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "659", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + } ] + } + }, { + "localId" : "664", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongPowerNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "664", + "s" : [ { + "value" : [ "", "define ", "LongPowerNearOverflow", ": " ] + }, { + "r" : "665", + "s" : [ { + "r" : "667", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "667", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "666", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "668", + "value" : [ "^", "1L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "665", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "669", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "670", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "667", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "668", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } ] + } + }, { + "localId" : "673", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongPowerNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "673", + "s" : [ { + "value" : [ "", "define ", "LongPowerNearUnderflow", ": " ] + }, { + "r" : "674", + "s" : [ { + "r" : "676", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "676", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "675", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "677", + "value" : [ "^", "1L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "674", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "678", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "679", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "676", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "677", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } ] + } + }, { + "localId" : "682", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongSuccessorOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "682", + "s" : [ { + "value" : [ "", "define ", "LongSuccessorOverflow", ": " ] + }, { + "r" : "685", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "684", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "683", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "685", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "686", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "684", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + } + }, { + "localId" : "689", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongPredecessorUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "689", + "s" : [ { + "value" : [ "", "define ", "LongPredecessorUnderflow", ": " ] + }, { + "r" : "692", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "691", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "690", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "692", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "693", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "691", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + } + }, { + "localId" : "696", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongSuccessorNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "696", + "s" : [ { + "value" : [ "", "define ", "LongSuccessorNearOverflow", ": " ] + }, { + "r" : "703", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "697", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "697", + "s" : [ { + "r" : "699", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "698", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "r" : "700", + "value" : [ " - ", "1L" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "703", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "704", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Subtract", + "localId" : "697", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "701", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "702", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "699", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "700", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "707", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongPredecessorNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "707", + "s" : [ { + "value" : [ "", "define ", "LongPredecessorNearUnderflow", ": " ] + }, { + "r" : "714", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "708", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "708", + "s" : [ { + "r" : "710", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "709", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "r" : "711", + "value" : [ " + ", "1L" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "714", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "715", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Add", + "localId" : "708", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "712", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "713", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "710", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "711", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "718", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalAddOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "718", + "s" : [ { + "value" : [ "", "define ", "DecimalAddOverflow", ": " ] + }, { + "r" : "719", + "s" : [ { + "r" : "721", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "720", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "722", + "value" : [ " + ", "1.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "719", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "723", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "724", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "721", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "722", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "727", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalAddUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "727", + "s" : [ { + "value" : [ "", "define ", "DecimalAddUnderflow", ": " ] + }, { + "r" : "728", + "s" : [ { + "r" : "730", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "729", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "731", + "s" : [ { + "r" : "732", + "value" : [ "-", "1.0" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "728", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "734", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "735", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "730", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Negate", + "localId" : "731", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "733", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "732", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "738", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalAddNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "738", + "s" : [ { + "value" : [ "", "define ", "DecimalAddNearOverflow", ": " ] + }, { + "r" : "739", + "s" : [ { + "r" : "741", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "740", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "742", + "value" : [ " + ", "0.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "739", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "743", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "744", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "741", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "742", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "747", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalAddNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "747", + "s" : [ { + "value" : [ "", "define ", "DecimalAddNearUnderflow", ": " ] + }, { + "r" : "748", + "s" : [ { + "r" : "750", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "749", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "751", + "value" : [ " + ", "0.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "748", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "752", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "753", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "750", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "751", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "756", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalSubtractOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "756", + "s" : [ { + "value" : [ "", "define ", "DecimalSubtractOverflow", ": " ] + }, { + "r" : "757", + "s" : [ { + "r" : "759", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "758", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "760", + "s" : [ { + "r" : "761", + "value" : [ "-", "1.0" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "757", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "763", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "764", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "759", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Negate", + "localId" : "760", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "762", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "761", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "767", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalSubtractUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "767", + "s" : [ { + "value" : [ "", "define ", "DecimalSubtractUnderflow", ": " ] + }, { + "r" : "768", + "s" : [ { + "r" : "770", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "769", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "771", + "value" : [ " - ", "1.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "768", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "772", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "773", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "770", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "771", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "776", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalSubtractNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "776", + "s" : [ { + "value" : [ "", "define ", "DecimalSubtractNearOverflow", ": " ] + }, { + "r" : "777", + "s" : [ { + "r" : "779", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "778", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "780", + "value" : [ " - ", "0.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "777", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "781", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "782", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "779", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "780", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "785", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalSubtractNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "785", + "s" : [ { + "value" : [ "", "define ", "DecimalSubtractNearUnderflow", ": " ] + }, { + "r" : "786", + "s" : [ { + "r" : "788", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "787", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "789", + "value" : [ " - ", "0.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "786", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "790", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "791", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "788", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "789", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "794", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalMultiplyOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "794", + "s" : [ { + "value" : [ "", "define ", "DecimalMultiplyOverflow", ": " ] + }, { + "r" : "795", + "s" : [ { + "r" : "797", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "796", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "798", + "value" : [ " * ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "795", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "802", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "803", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "797", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "800", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "801", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "798", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "806", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalMultiplyUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "806", + "s" : [ { + "value" : [ "", "define ", "DecimalMultiplyUnderflow", ": " ] + }, { + "r" : "807", + "s" : [ { + "r" : "809", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "808", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "810", + "value" : [ " * ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "807", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "814", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "815", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "809", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "812", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "813", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "810", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "818", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalMultiplyNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "818", + "s" : [ { + "value" : [ "", "define ", "DecimalMultiplyNearOverflow", ": " ] + }, { + "r" : "819", + "s" : [ { + "r" : "821", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "820", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "822", + "value" : [ " * ", "1" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "819", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "826", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "827", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "821", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "824", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "825", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "822", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "830", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalMultiplyNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "830", + "s" : [ { + "value" : [ "", "define ", "DecimalMultiplyNearUnderflow", ": " ] + }, { + "r" : "831", + "s" : [ { + "r" : "833", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "832", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "834", + "value" : [ " * ", "1" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "831", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "838", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "839", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "833", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "836", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "837", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "834", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "842", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalDivideOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "842", + "s" : [ { + "value" : [ "", "define ", "DecimalDivideOverflow", ": " ] + }, { + "r" : "843", + "s" : [ { + "r" : "845", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "844", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "846", + "value" : [ " / ", "0.5" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "843", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "847", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "848", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "845", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "846", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.5", + "annotation" : [ ] + } ] + } + }, { + "localId" : "851", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalDivideUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "851", + "s" : [ { + "value" : [ "", "define ", "DecimalDivideUnderflow", ": " ] + }, { + "r" : "852", + "s" : [ { + "r" : "854", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "853", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "855", + "value" : [ " / ", "0.5" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "852", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "856", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "857", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "854", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "855", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.5", + "annotation" : [ ] + } ] + } + }, { + "localId" : "860", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalDivideNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "860", + "s" : [ { + "value" : [ "", "define ", "DecimalDivideNearOverflow", ": " ] + }, { + "r" : "861", + "s" : [ { + "r" : "863", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "862", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "864", + "value" : [ " / ", "1.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "861", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "865", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "866", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "863", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "864", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "869", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalDivideNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "869", + "s" : [ { + "value" : [ "", "define ", "DecimalDivideNearUnderflow", ": " ] + }, { + "r" : "870", + "s" : [ { + "r" : "872", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "871", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "873", + "value" : [ " / ", "1.0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "870", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "874", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "875", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "872", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "873", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + } ] + } + }, { + "localId" : "878", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalDivideByZero", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "878", + "s" : [ { + "value" : [ "", "define ", "DecimalDivideByZero", ": " ] + }, { + "r" : "879", + "s" : [ { + "r" : "880", + "value" : [ "1.0", " / ", "0" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "879", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "885", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "886", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "880", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "1.0", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "883", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "884", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "881", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "0", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "889", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalPowerOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "889", + "s" : [ { + "value" : [ "", "define ", "DecimalPowerOverflow", ": " ] + }, { + "r" : "890", + "s" : [ { + "r" : "892", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "892", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "891", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "893", + "value" : [ "^", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "890", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "897", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "898", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "892", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "895", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "896", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "893", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "901", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalPowerUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "901", + "s" : [ { + "value" : [ "", "define ", "DecimalPowerUnderflow", ": " ] + }, { + "r" : "902", + "s" : [ { + "r" : "904", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "904", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "903", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "905", + "value" : [ "^", "3" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "902", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "909", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "910", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "904", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "907", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "908", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "905", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "3", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "913", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalPowerNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "913", + "s" : [ { + "value" : [ "", "define ", "DecimalPowerNearOverflow", ": " ] + }, { + "r" : "914", + "s" : [ { + "r" : "916", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "916", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "915", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "917", + "value" : [ "^", "1" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "914", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "921", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "922", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "916", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "919", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "920", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "917", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "925", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalPowerNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "925", + "s" : [ { + "value" : [ "", "define ", "DecimalPowerNearUnderflow", ": " ] + }, { + "r" : "926", + "s" : [ { + "r" : "928", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "928", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "927", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "r" : "929", + "value" : [ "^", "1" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "926", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "933", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "934", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "928", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "ToDecimal", + "localId" : "931", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "932", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "929", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "937", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalSuccessorOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "937", + "s" : [ { + "value" : [ "", "define ", "DecimalSuccessorOverflow", ": " ] + }, { + "r" : "940", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "939", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "938", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "940", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "941", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "939", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } + } + }, { + "localId" : "944", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalPredecessorUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "944", + "s" : [ { + "value" : [ "", "define ", "DecimalPredecessorUnderflow", ": " ] + }, { + "r" : "947", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "946", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "945", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "947", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "948", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "946", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } + } + }, { + "localId" : "951", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalSuccessorNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "951", + "s" : [ { + "value" : [ "", "define ", "DecimalSuccessorNearOverflow", ": " ] + }, { + "r" : "958", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "952", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "952", + "s" : [ { + "r" : "954", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "953", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "955", + "value" : [ " - ", "0.00000001" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "958", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "959", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Subtract", + "localId" : "952", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "956", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "957", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "954", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "955", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.00000001", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "962", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalPredecessorNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "962", + "s" : [ { + "value" : [ "", "define ", "DecimalPredecessorNearUnderflow", ": " ] + }, { + "r" : "969", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "963", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "963", + "s" : [ { + "r" : "965", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "964", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "966", + "value" : [ " + ", "0.00000001" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "969", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "970", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Add", + "localId" : "963", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "967", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "968", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "965", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "966", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.00000001", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "973", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "973", + "s" : [ { + "value" : [ "", "define ", "MaxQuantity", ": " ] + }, { + "r" : "974", + "s" : [ { + "value" : [ "Quantity", " { " ] + }, { + "s" : [ { + "value" : [ "value", ": " ] + }, { + "r" : "977", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "976", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + }, { + "value" : [ ", " ] + }, { + "s" : [ { + "value" : [ "unit", ": " ] + }, { + "r" : "978", + "s" : [ { + "value" : [ "'mm'" ] + } ] + } ] + }, { + "value" : [ " }" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Instance", + "localId" : "974", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "classType" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "element" : [ { + "name" : "value", + "value" : { + "type" : "MaxValue", + "localId" : "977", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } + }, { + "name" : "unit", + "value" : { + "type" : "Literal", + "localId" : "978", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "mm", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "982", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "982", + "s" : [ { + "value" : [ "", "define ", "MinQuantity", ": " ] + }, { + "r" : "983", + "s" : [ { + "value" : [ "Quantity", " { " ] + }, { + "s" : [ { + "value" : [ "value", ": " ] + }, { + "r" : "986", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "985", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + }, { + "value" : [ ", " ] + }, { + "s" : [ { + "value" : [ "unit", ": " ] + }, { + "r" : "987", + "s" : [ { + "value" : [ "'mm'" ] + } ] + } ] + }, { + "value" : [ " }" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Instance", + "localId" : "983", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "classType" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "element" : [ { + "name" : "value", + "value" : { + "type" : "MinValue", + "localId" : "986", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } + }, { + "name" : "unit", + "value" : { + "type" : "Literal", + "localId" : "987", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "mm", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "991", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityAddOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "991", + "s" : [ { + "value" : [ "", "define ", "QuantityAddOverflow", ": " ] + }, { + "r" : "992", + "s" : [ { + "r" : "993", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "994", + "s" : [ { + "value" : [ "1.0 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "992", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "995", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "996", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "993", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "994", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1.0, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "999", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityAddUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "999", + "s" : [ { + "value" : [ "", "define ", "QuantityAddUnderflow", ": " ] + }, { + "r" : "1000", + "s" : [ { + "r" : "1001", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1002", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1002", + "s" : [ { + "value" : [ "-" ] + }, { + "r" : "1003", + "s" : [ { + "value" : [ "1.0 ", "'mm'" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1000", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1005", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1006", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1001", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Negate", + "localId" : "1002", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1004", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Quantity", + "localId" : "1003", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1.0, + "unit" : "mm", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "1009", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityAddNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1009", + "s" : [ { + "value" : [ "", "define ", "QuantityAddNearOverflow", ": " ] + }, { + "r" : "1010", + "s" : [ { + "r" : "1011", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1012", + "s" : [ { + "value" : [ "0.0 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1010", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1013", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1014", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1011", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1012", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0.0, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1017", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityAddNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1017", + "s" : [ { + "value" : [ "", "define ", "QuantityAddNearUnderflow", ": " ] + }, { + "r" : "1018", + "s" : [ { + "r" : "1019", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1020", + "s" : [ { + "value" : [ "0.0 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1018", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1021", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1022", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1019", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1020", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0.0, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1025", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantitySubtractOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1025", + "s" : [ { + "value" : [ "", "define ", "QuantitySubtractOverflow", ": " ] + }, { + "r" : "1026", + "s" : [ { + "r" : "1027", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1028", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1028", + "s" : [ { + "value" : [ "-" ] + }, { + "r" : "1029", + "s" : [ { + "value" : [ "1 ", "'mm'" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1026", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1031", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1032", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1027", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Negate", + "localId" : "1028", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1030", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Quantity", + "localId" : "1029", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "mm", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "1035", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantitySubtractUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1035", + "s" : [ { + "value" : [ "", "define ", "QuantitySubtractUnderflow", ": " ] + }, { + "r" : "1036", + "s" : [ { + "r" : "1037", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1038", + "s" : [ { + "value" : [ "1 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1036", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1039", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1040", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1037", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1038", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1043", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantitySubtractNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1043", + "s" : [ { + "value" : [ "", "define ", "QuantitySubtractNearOverflow", ": " ] + }, { + "r" : "1044", + "s" : [ { + "r" : "1045", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1046", + "s" : [ { + "value" : [ "0.0 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1044", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1047", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1048", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1045", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1046", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0.0, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1051", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantitySubtractNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1051", + "s" : [ { + "value" : [ "", "define ", "QuantitySubtractNearUnderflow", ": " ] + }, { + "r" : "1052", + "s" : [ { + "r" : "1053", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1054", + "s" : [ { + "value" : [ "0.0 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1052", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1055", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1056", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1053", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1054", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0.0, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1059", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityMultiplyOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1059", + "s" : [ { + "value" : [ "", "define ", "QuantityMultiplyOverflow", ": " ] + }, { + "r" : "1060", + "s" : [ { + "r" : "1061", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " * " ] + }, { + "r" : "1062", + "s" : [ { + "value" : [ "2 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "1060", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1063", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1064", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1061", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1062", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 2, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1067", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityMultiplyUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1067", + "s" : [ { + "value" : [ "", "define ", "QuantityMultiplyUnderflow", ": " ] + }, { + "r" : "1068", + "s" : [ { + "r" : "1069", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " * " ] + }, { + "r" : "1070", + "s" : [ { + "value" : [ "2 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "1068", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1071", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1072", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1069", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1070", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 2, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1075", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityMultiplyNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1075", + "s" : [ { + "value" : [ "", "define ", "QuantityMultiplyNearOverflow", ": " ] + }, { + "r" : "1076", + "s" : [ { + "r" : "1077", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " * " ] + }, { + "r" : "1078", + "s" : [ { + "value" : [ "1 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "1076", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1079", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1080", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1077", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1078", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1083", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityMultiplyNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1083", + "s" : [ { + "value" : [ "", "define ", "QuantityMultiplyNearUnderflow", ": " ] + }, { + "r" : "1084", + "s" : [ { + "r" : "1085", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " * " ] + }, { + "r" : "1086", + "s" : [ { + "value" : [ "1 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "1084", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1087", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1088", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1085", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1086", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1091", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityDivideOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1091", + "s" : [ { + "value" : [ "", "define ", "QuantityDivideOverflow", ": " ] + }, { + "r" : "1092", + "s" : [ { + "r" : "1093", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " / " ] + }, { + "r" : "1094", + "s" : [ { + "value" : [ "0.5 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "1092", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1095", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1096", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1093", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1094", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0.5, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1099", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityDivideUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1099", + "s" : [ { + "value" : [ "", "define ", "QuantityDivideUnderflow", ": " ] + }, { + "r" : "1100", + "s" : [ { + "r" : "1101", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " / " ] + }, { + "r" : "1102", + "s" : [ { + "value" : [ "0.5 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "1100", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1103", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1104", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1101", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1102", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0.5, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1107", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityDivideNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1107", + "s" : [ { + "value" : [ "", "define ", "QuantityDivideNearOverflow", ": " ] + }, { + "r" : "1108", + "s" : [ { + "r" : "1109", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + }, { + "value" : [ " / " ] + }, { + "r" : "1110", + "s" : [ { + "value" : [ "1 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "1108", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1111", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1112", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1109", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1110", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1115", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityDivideNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1115", + "s" : [ { + "value" : [ "", "define ", "QuantityDivideNearUnderflow", ": " ] + }, { + "r" : "1116", + "s" : [ { + "r" : "1117", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + }, { + "value" : [ " / " ] + }, { + "r" : "1118", + "s" : [ { + "value" : [ "1 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "1116", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1119", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1120", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ExpressionRef", + "localId" : "1117", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1118", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1123", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityDivideByZero", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1123", + "s" : [ { + "value" : [ "", "define ", "QuantityDivideByZero", ": " ] + }, { + "r" : "1124", + "s" : [ { + "r" : "1125", + "s" : [ { + "value" : [ "1.0 ", "'mm'" ] + } ] + }, { + "value" : [ " / " ] + }, { + "r" : "1126", + "s" : [ { + "value" : [ "0 ", "'mm'" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "1124", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1127", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1128", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Quantity", + "localId" : "1125", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1.0, + "unit" : "mm", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1126", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "mm", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1131", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantitySuccessorOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1131", + "s" : [ { + "value" : [ "", "define ", "QuantitySuccessorOverflow", ": " ] + }, { + "r" : "1133", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "1132", + "s" : [ { + "value" : [ "MaxQuantity" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "1133", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1134", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ExpressionRef", + "localId" : "1132", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MaxQuantity", + "annotation" : [ ] + } + } + }, { + "localId" : "1137", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityPredecessorUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1137", + "s" : [ { + "value" : [ "", "define ", "QuantityPredecessorUnderflow", ": " ] + }, { + "r" : "1139", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "1138", + "s" : [ { + "value" : [ "MinQuantity" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "1139", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1140", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ExpressionRef", + "localId" : "1138", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "MinQuantity", + "annotation" : [ ] + } + } + }, { + "localId" : "1143", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantitySuccessorNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1143", + "s" : [ { + "value" : [ "", "define ", "QuantitySuccessorNearOverflow", ": " ] + }, { + "r" : "1154", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "1144", + "s" : [ { + "value" : [ "Quantity", " { " ] + }, { + "s" : [ { + "value" : [ "value", ": " ] + }, { + "r" : "1146", + "s" : [ { + "r" : "1148", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1147", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "1149", + "value" : [ " - ", "0.00000001" ] + } ] + } ] + }, { + "value" : [ ", " ] + }, { + "s" : [ { + "value" : [ "unit", ": " ] + }, { + "r" : "1152", + "s" : [ { + "value" : [ "'mm'" ] + } ] + } ] + }, { + "value" : [ " }" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "1154", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1155", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Instance", + "localId" : "1144", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "classType" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "element" : [ { + "name" : "value", + "value" : { + "type" : "Subtract", + "localId" : "1146", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1150", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1151", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1148", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "1149", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.00000001", + "annotation" : [ ] + } ] + } + }, { + "name" : "unit", + "value" : { + "type" : "Literal", + "localId" : "1152", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "mm", + "annotation" : [ ] + } + } ] + } + } + }, { + "localId" : "1158", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "QuantityPredecessorNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1158", + "s" : [ { + "value" : [ "", "define ", "QuantityPredecessorNearUnderflow", ": " ] + }, { + "r" : "1169", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "1159", + "s" : [ { + "value" : [ "Quantity", " { " ] + }, { + "s" : [ { + "value" : [ "value", ": " ] + }, { + "r" : "1161", + "s" : [ { + "r" : "1163", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1162", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + }, { + "r" : "1164", + "value" : [ " + ", "0.00000001" ] + } ] + } ] + }, { + "value" : [ ", " ] + }, { + "s" : [ { + "value" : [ "unit", ": " ] + }, { + "r" : "1167", + "s" : [ { + "value" : [ "'mm'" ] + } ] + } ] + }, { + "value" : [ " }" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "1169", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1170", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Instance", + "localId" : "1159", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "classType" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "element" : [ { + "name" : "value", + "value" : { + "type" : "Add", + "localId" : "1161", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1165", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1166", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1163", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "1164", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "0.00000001", + "annotation" : [ ] + } ] + } + }, { + "name" : "unit", + "value" : { + "type" : "Literal", + "localId" : "1167", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "mm", + "annotation" : [ ] + } + } ] + } + } + }, { + "localId" : "1173", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeAddOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1173", + "s" : [ { + "value" : [ "", "define ", "DateTimeAddOverflow", ": " ] + }, { + "r" : "1174", + "s" : [ { + "r" : "1176", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1175", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1177", + "s" : [ { + "value" : [ "1 ", "day" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1174", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1178", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1179", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1176", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1177", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "day", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1182", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeAddUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1182", + "s" : [ { + "value" : [ "", "define ", "DateTimeAddUnderflow", ": " ] + }, { + "r" : "1183", + "s" : [ { + "r" : "1185", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1184", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1186", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1186", + "s" : [ { + "value" : [ "-" ] + }, { + "r" : "1187", + "s" : [ { + "value" : [ "1 ", "day" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1183", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1189", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1190", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1185", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Negate", + "localId" : "1186", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1188", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Quantity", + "localId" : "1187", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "day", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "1193", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeAddNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1193", + "s" : [ { + "value" : [ "", "define ", "DateTimeAddNearOverflow", ": " ] + }, { + "r" : "1194", + "s" : [ { + "r" : "1196", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1195", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1197", + "s" : [ { + "value" : [ "0 ", "days" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1194", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1198", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1199", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1196", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1197", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "days", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1202", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeAddNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1202", + "s" : [ { + "value" : [ "", "define ", "DateTimeAddNearUnderflow", ": " ] + }, { + "r" : "1203", + "s" : [ { + "r" : "1205", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1204", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1206", + "s" : [ { + "value" : [ "0 ", "days" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1203", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1207", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1208", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1205", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1206", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "days", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1211", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeSubtractOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1211", + "s" : [ { + "value" : [ "", "define ", "DateTimeSubtractOverflow", ": " ] + }, { + "r" : "1212", + "s" : [ { + "r" : "1214", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1213", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1215", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1215", + "s" : [ { + "value" : [ "-" ] + }, { + "r" : "1216", + "s" : [ { + "value" : [ "1 ", "day" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1212", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1218", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1219", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1214", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Negate", + "localId" : "1215", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1217", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Quantity", + "localId" : "1216", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "day", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "1222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeSubtractUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1222", + "s" : [ { + "value" : [ "", "define ", "DateTimeSubtractUnderflow", ": " ] + }, { + "r" : "1223", + "s" : [ { + "r" : "1225", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1224", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1226", + "s" : [ { + "value" : [ "1 ", "day" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1223", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1227", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1228", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "day", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1231", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeSubtractNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1231", + "s" : [ { + "value" : [ "", "define ", "DateTimeSubtractNearOverflow", ": " ] + }, { + "r" : "1232", + "s" : [ { + "r" : "1234", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1233", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1235", + "s" : [ { + "value" : [ "0 ", "days" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1236", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1237", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1234", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1235", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "days", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeSubtractNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1240", + "s" : [ { + "value" : [ "", "define ", "DateTimeSubtractNearUnderflow", ": " ] + }, { + "r" : "1241", + "s" : [ { + "r" : "1243", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1242", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1244", + "s" : [ { + "value" : [ "0 ", "days" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1245", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1246", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1243", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "days", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1249", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeSuccessorOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1249", + "s" : [ { + "value" : [ "", "define ", "DateTimeSuccessorOverflow", ": " ] + }, { + "r" : "1252", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "1251", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1250", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "1252", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1253", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "1251", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } + } + }, { + "localId" : "1256", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimePredecessorUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1256", + "s" : [ { + "value" : [ "", "define ", "DateTimePredecessorUnderflow", ": " ] + }, { + "r" : "1259", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "1258", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1257", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "1259", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1260", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "1258", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } + } + }, { + "localId" : "1263", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimeSuccessorNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1263", + "s" : [ { + "value" : [ "", "define ", "DateTimeSuccessorNearOverflow", ": " ] + }, { + "r" : "1270", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "1264", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1264", + "s" : [ { + "r" : "1266", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1265", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1267", + "s" : [ { + "value" : [ "1 ", "millisecond" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "1270", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1271", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Subtract", + "localId" : "1264", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1268", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1269", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1266", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1267", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "millisecond", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "1274", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "DateTimePredecessorNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1274", + "s" : [ { + "value" : [ "", "define ", "DateTimePredecessorNearUnderflow", ": " ] + }, { + "r" : "1281", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "1275", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1275", + "s" : [ { + "r" : "1277", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1276", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1278", + "s" : [ { + "value" : [ "1 ", "millisecond" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "1281", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1282", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Add", + "localId" : "1275", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1279", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1280", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1277", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1278", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "millisecond", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "1285", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateAddOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1285", + "s" : [ { + "value" : [ "", "define ", "DateAddOverflow", ": " ] + }, { + "r" : "1286", + "s" : [ { + "r" : "1288", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1287", + "s" : [ { + "value" : [ "Date" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1289", + "s" : [ { + "value" : [ "1 ", "day" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "1286", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1290", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1291", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1288", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1289", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "day", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1294", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateAddUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1294", + "s" : [ { + "value" : [ "", "define ", "DateAddUnderflow", ": " ] + }, { + "r" : "1295", + "s" : [ { + "r" : "1297", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1296", + "s" : [ { + "value" : [ "Date" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1298", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1298", + "s" : [ { + "value" : [ "-" ] + }, { + "r" : "1299", + "s" : [ { + "value" : [ "1 ", "day" ] + } ] + } ] + }, { + "value" : [ ")" ] } ] } ] } ] } } ], "expression" : { - "type" : "Predecessor", - "localId" : "585", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "type" : "Add", + "localId" : "1295", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "586", + "localId" : "1301", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1302", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { - "type" : "ExpressionRef", - "localId" : "584", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "MinQuantity", + "operand" : [ { + "type" : "MinValue", + "localId" : "1297", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - } + }, { + "type" : "Negate", + "localId" : "1298", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1300", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Quantity", + "localId" : "1299", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "day", + "annotation" : [ ] + } + } ] } }, { - "localId" : "589", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "DateTimeAddOverflow", + "localId" : "1305", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateAddNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "589", + "r" : "1305", "s" : [ { - "value" : [ "", "define ", "DateTimeAddOverflow", ": " ] + "value" : [ "", "define ", "DateAddNearOverflow", ": " ] }, { - "r" : "590", + "r" : "1306", "s" : [ { - "r" : "592", + "r" : "1308", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "591", + "r" : "1307", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] }, { "value" : [ " + " ] }, { - "r" : "593", + "r" : "1309", "s" : [ { - "value" : [ "1 ", "day" ] + "value" : [ "0 ", "days" ] } ] } ] } ] @@ -13352,78 +19499,66 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "590", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1306", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "594", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1310", + "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "595", + "localId" : "1311", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "592", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1308", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "593", + "localId" : "1309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "day", + "value" : 0, + "unit" : "days", "annotation" : [ ] } ] } }, { - "localId" : "598", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "DateTimeAddUnderflow", + "localId" : "1314", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateAddNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "598", + "r" : "1314", "s" : [ { - "value" : [ "", "define ", "DateTimeAddUnderflow", ": " ] + "value" : [ "", "define ", "DateAddNearUnderflow", ": " ] }, { - "r" : "599", + "r" : "1315", "s" : [ { - "r" : "601", + "r" : "1317", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "600", + "r" : "1316", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] }, { "value" : [ " + " ] }, { - "r" : "602", + "r" : "1318", "s" : [ { - "value" : [ "(" ] - }, { - "r" : "602", - "s" : [ { - "value" : [ "-" ] - }, { - "r" : "603", - "s" : [ { - "value" : [ "1 ", "day" ] - } ] - } ] - }, { - "value" : [ ")" ] + "value" : [ "0 ", "days" ] } ] } ] } ] @@ -13431,84 +19566,72 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "599", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1315", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "605", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1319", + "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "606", + "localId" : "1320", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "601", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1317", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { - "type" : "Negate", - "localId" : "602", + "type" : "Quantity", + "localId" : "1318", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "604", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Quantity", - "localId" : "603", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "day", - "annotation" : [ ] - } + "value" : 0, + "unit" : "days", + "annotation" : [ ] } ] } }, { - "localId" : "609", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "DateTimeSubtractOverflow", + "localId" : "1323", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateSubtractOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "609", + "r" : "1323", "s" : [ { - "value" : [ "", "define ", "DateTimeSubtractOverflow", ": " ] + "value" : [ "", "define ", "DateSubtractOverflow", ": " ] }, { - "r" : "610", + "r" : "1324", "s" : [ { - "r" : "612", + "r" : "1326", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "611", + "r" : "1325", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] }, { "value" : [ " - " ] }, { - "r" : "613", + "r" : "1327", "s" : [ { "value" : [ "(" ] }, { - "r" : "613", + "r" : "1327", "s" : [ { "value" : [ "-" ] }, { - "r" : "614", + "r" : "1328", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -13522,40 +19645,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "610", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1324", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "616", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1330", + "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "617", + "localId" : "1331", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "612", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1326", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "613", + "localId" : "1327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "615", + "localId" : "1329", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "614", + "localId" : "1328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -13564,34 +19687,34 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "620", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "DateTimeSubtractUnderflow", + "localId" : "1334", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateSubtractUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "620", + "r" : "1334", "s" : [ { - "value" : [ "", "define ", "DateTimeSubtractUnderflow", ": " ] + "value" : [ "", "define ", "DateSubtractUnderflow", ": " ] }, { - "r" : "621", + "r" : "1335", "s" : [ { - "r" : "623", + "r" : "1337", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "622", + "r" : "1336", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] }, { "value" : [ " - " ] }, { - "r" : "624", + "r" : "1338", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -13601,29 +19724,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "621", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1335", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "625", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1339", + "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "626", + "localId" : "1340", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "623", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1337", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "624", + "localId" : "1338", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -13631,209 +19754,276 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "629", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "DateTimeSuccessorOverflow", + "localId" : "1343", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateSubtractNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "629", + "r" : "1343", "s" : [ { - "value" : [ "", "define ", "DateTimeSuccessorOverflow", ": " ] + "value" : [ "", "define ", "DateSubtractNearOverflow", ": " ] }, { - "r" : "632", + "r" : "1344", "s" : [ { - "value" : [ "successor of " ] - }, { - "r" : "631", + "r" : "1346", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "630", + "r" : "1345", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1347", + "s" : [ { + "value" : [ "0 ", "days" ] + } ] } ] } ] } } ], "expression" : { - "type" : "Successor", - "localId" : "632", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "Subtract", + "localId" : "1344", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "633", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1348", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1349", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { "type" : "MaxValue", - "localId" : "631", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1346", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - } + }, { + "type" : "Quantity", + "localId" : "1347", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "days", + "annotation" : [ ] + } ] } }, { - "localId" : "636", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "DateTimePredecessorUnderflow", + "localId" : "1352", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DateSubtractNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "636", + "r" : "1352", "s" : [ { - "value" : [ "", "define ", "DateTimePredecessorUnderflow", ": " ] + "value" : [ "", "define ", "DateSubtractNearUnderflow", ": " ] }, { - "r" : "639", + "r" : "1353", "s" : [ { - "value" : [ "predecessor of " ] - }, { - "r" : "638", + "r" : "1355", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "637", + "r" : "1354", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1356", + "s" : [ { + "value" : [ "0 ", "days" ] + } ] } ] } ] } } ], "expression" : { - "type" : "Predecessor", - "localId" : "639", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "Subtract", + "localId" : "1353", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "640", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1357", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1358", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { "type" : "MinValue", - "localId" : "638", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "1355", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - } + }, { + "type" : "Quantity", + "localId" : "1356", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "days", + "annotation" : [ ] + } ] } }, { - "localId" : "643", + "localId" : "1361", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "DateAddOverflow", + "name" : "DateSuccessorOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "643", + "r" : "1361", "s" : [ { - "value" : [ "", "define ", "DateAddOverflow", ": " ] + "value" : [ "", "define ", "DateSuccessorOverflow", ": " ] }, { - "r" : "644", + "r" : "1364", "s" : [ { - "r" : "646", + "value" : [ "successor of " ] + }, { + "r" : "1363", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "645", + "r" : "1362", "s" : [ { "value" : [ "Date" ] } ] } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "1364", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1365", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "1363", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + } + } + }, { + "localId" : "1368", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "DatePredecessorUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1368", + "s" : [ { + "value" : [ "", "define ", "DatePredecessorUnderflow", ": " ] + }, { + "r" : "1371", + "s" : [ { + "value" : [ "predecessor of " ] }, { - "value" : [ " + " ] - }, { - "r" : "647", + "r" : "1370", "s" : [ { - "value" : [ "1 ", "day" ] + "value" : [ "minimum", " " ] + }, { + "r" : "1369", + "s" : [ { + "value" : [ "Date" ] + } ] } ] } ] } ] } } ], "expression" : { - "type" : "Add", - "localId" : "644", + "type" : "Predecessor", + "localId" : "1371", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "648", + "localId" : "1372", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "649", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] } ], - "operand" : [ { - "type" : "MaxValue", - "localId" : "646", + "operand" : { + "type" : "MinValue", + "localId" : "1370", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - }, { - "type" : "Quantity", - "localId" : "647", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "day", - "annotation" : [ ] - } ] + } } }, { - "localId" : "652", + "localId" : "1375", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "DateAddUnderflow", + "name" : "DateSuccessorNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "652", + "r" : "1375", "s" : [ { - "value" : [ "", "define ", "DateAddUnderflow", ": " ] + "value" : [ "", "define ", "DateSuccessorNearOverflow", ": " ] }, { - "r" : "653", + "r" : "1382", "s" : [ { - "r" : "655", - "s" : [ { - "value" : [ "minimum", " " ] - }, { - "r" : "654", - "s" : [ { - "value" : [ "Date" ] - } ] - } ] - }, { - "value" : [ " + " ] + "value" : [ "successor of " ] }, { - "r" : "656", + "r" : "1376", "s" : [ { "value" : [ "(" ] }, { - "r" : "656", + "r" : "1376", "s" : [ { - "value" : [ "-" ] + "r" : "1378", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1377", + "s" : [ { + "value" : [ "Date" ] + } ] + } ] }, { - "r" : "657", + "value" : [ " - " ] + }, { + "r" : "1379", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -13846,85 +20036,85 @@ module.exports['OutOfBounds'] = { } } ], "expression" : { - "type" : "Add", - "localId" : "653", + "type" : "Successor", + "localId" : "1382", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "659", + "localId" : "1383", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "660", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] } ], - "operand" : [ { - "type" : "MinValue", - "localId" : "655", + "operand" : { + "type" : "Subtract", + "localId" : "1376", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "valueType" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ] - }, { - "type" : "Negate", - "localId" : "656", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "658", + "localId" : "1380", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1381", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { + "type" : "MaxValue", + "localId" : "1378", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { "type" : "Quantity", - "localId" : "657", + "localId" : "1379", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", "annotation" : [ ] - } - } ] + } ] + } } }, { - "localId" : "663", + "localId" : "1386", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "DateSubtractOverflow", + "name" : "DatePredecessorNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "663", + "r" : "1386", "s" : [ { - "value" : [ "", "define ", "DateSubtractOverflow", ": " ] + "value" : [ "", "define ", "DatePredecessorNearUnderflow", ": " ] }, { - "r" : "664", + "r" : "1393", "s" : [ { - "r" : "666", - "s" : [ { - "value" : [ "maximum", " " ] - }, { - "r" : "665", - "s" : [ { - "value" : [ "Date" ] - } ] - } ] - }, { - "value" : [ " - " ] + "value" : [ "predecessor of " ] }, { - "r" : "667", + "r" : "1387", "s" : [ { "value" : [ "(" ] }, { - "r" : "667", + "r" : "1387", "s" : [ { - "value" : [ "-" ] + "r" : "1389", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1388", + "s" : [ { + "value" : [ "Date" ] + } ] + } ] }, { - "r" : "668", + "value" : [ " + " ] + }, { + "r" : "1390", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -13937,236 +20127,294 @@ module.exports['OutOfBounds'] = { } } ], "expression" : { - "type" : "Subtract", - "localId" : "664", + "type" : "Predecessor", + "localId" : "1393", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "670", + "localId" : "1394", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "671", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] } ], - "operand" : [ { - "type" : "MaxValue", - "localId" : "666", + "operand" : { + "type" : "Add", + "localId" : "1387", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "valueType" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ] - }, { - "type" : "Negate", - "localId" : "667", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "669", + "localId" : "1391", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1392", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { + "operand" : [ { + "type" : "MinValue", + "localId" : "1389", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + }, { "type" : "Quantity", - "localId" : "668", + "localId" : "1390", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", "annotation" : [ ] - } - } ] + } ] + } } }, { - "localId" : "674", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "DateSubtractUnderflow", + "localId" : "1397", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimeAddOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "674", + "r" : "1397", "s" : [ { - "value" : [ "", "define ", "DateSubtractUnderflow", ": " ] + "value" : [ "", "define ", "TimeAddOverflow", ": " ] }, { - "r" : "675", + "r" : "1398", "s" : [ { - "r" : "677", + "r" : "1400", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "maximum", " " ] }, { - "r" : "676", + "r" : "1399", "s" : [ { - "value" : [ "Date" ] + "value" : [ "Time" ] } ] } ] }, { - "value" : [ " - " ] + "value" : [ " + " ] }, { - "r" : "678", + "r" : "1401", "s" : [ { - "value" : [ "1 ", "day" ] + "value" : [ "1 ", "second" ] } ] } ] } ] } } ], "expression" : { - "type" : "Subtract", - "localId" : "675", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "type" : "Add", + "localId" : "1398", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "679", - "name" : "{urn:hl7-org:elm-types:r1}Date", + "localId" : "1402", + "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "680", + "localId" : "1403", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { - "type" : "MinValue", - "localId" : "677", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "type" : "MaxValue", + "localId" : "1400", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "678", + "localId" : "1401", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, - "unit" : "day", + "unit" : "second", "annotation" : [ ] } ] } }, { - "localId" : "683", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "DateSuccessorOverflow", + "localId" : "1406", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimeAddUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "683", + "r" : "1406", "s" : [ { - "value" : [ "", "define ", "DateSuccessorOverflow", ": " ] + "value" : [ "", "define ", "TimeAddUnderflow", ": " ] }, { - "r" : "686", + "r" : "1407", "s" : [ { - "value" : [ "successor of " ] + "r" : "1409", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1408", + "s" : [ { + "value" : [ "Time" ] + } ] + } ] + }, { + "value" : [ " + " ] }, { - "r" : "685", + "r" : "1410", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "(" ] }, { - "r" : "684", + "r" : "1410", "s" : [ { - "value" : [ "Date" ] + "value" : [ "-" ] + }, { + "r" : "1411", + "s" : [ { + "value" : [ "1 ", "second" ] + } ] } ] + }, { + "value" : [ ")" ] } ] } ] } ] } } ], "expression" : { - "type" : "Successor", - "localId" : "686", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "type" : "Add", + "localId" : "1407", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "687", - "name" : "{urn:hl7-org:elm-types:r1}Date", + "localId" : "1413", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1414", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { - "type" : "MaxValue", - "localId" : "685", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "operand" : [ { + "type" : "MinValue", + "localId" : "1409", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] - } + }, { + "type" : "Negate", + "localId" : "1410", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1412", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Quantity", + "localId" : "1411", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "second", + "annotation" : [ ] + } + } ] } }, { - "localId" : "690", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "DatePredecessorUnderflow", + "localId" : "1417", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimeAddNearOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "690", + "r" : "1417", "s" : [ { - "value" : [ "", "define ", "DatePredecessorUnderflow", ": " ] + "value" : [ "", "define ", "TimeAddNearOverflow", ": " ] }, { - "r" : "693", + "r" : "1418", "s" : [ { - "value" : [ "predecessor of " ] - }, { - "r" : "692", + "r" : "1420", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "maximum", " " ] }, { - "r" : "691", + "r" : "1419", "s" : [ { - "value" : [ "Date" ] + "value" : [ "Time" ] } ] } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1421", + "s" : [ { + "value" : [ "0 ", "seconds" ] + } ] } ] } ] } } ], "expression" : { - "type" : "Predecessor", - "localId" : "693", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "type" : "Add", + "localId" : "1418", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "694", - "name" : "{urn:hl7-org:elm-types:r1}Date", + "localId" : "1422", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1423", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], - "operand" : { - "type" : "MinValue", - "localId" : "692", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "valueType" : "{urn:hl7-org:elm-types:r1}Date", + "operand" : [ { + "type" : "MaxValue", + "localId" : "1420", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] - } + }, { + "type" : "Quantity", + "localId" : "1421", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 0, + "unit" : "seconds", + "annotation" : [ ] + } ] } }, { - "localId" : "697", + "localId" : "1426", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", - "name" : "TimeAddOverflow", + "name" : "TimeAddNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "697", + "r" : "1426", "s" : [ { - "value" : [ "", "define ", "TimeAddOverflow", ": " ] + "value" : [ "", "define ", "TimeAddNearUnderflow", ": " ] }, { - "r" : "698", + "r" : "1427", "s" : [ { - "r" : "700", + "r" : "1429", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "minimum", " " ] }, { - "r" : "699", + "r" : "1428", "s" : [ { "value" : [ "Time" ] } ] @@ -14174,9 +20422,9 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "701", + "r" : "1430", "s" : [ { - "value" : [ "1 ", "second" ] + "value" : [ "0 ", "seconds" ] } ] } ] } ] @@ -14184,72 +20432,72 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "698", + "localId" : "1427", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "702", + "localId" : "1431", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "703", + "localId" : "1432", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { - "type" : "MaxValue", - "localId" : "700", + "type" : "MinValue", + "localId" : "1429", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "701", + "localId" : "1430", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "second", + "value" : 0, + "unit" : "seconds", "annotation" : [ ] } ] } }, { - "localId" : "706", + "localId" : "1435", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", - "name" : "TimeAddUnderflow", + "name" : "TimeSubtractOverflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "706", + "r" : "1435", "s" : [ { - "value" : [ "", "define ", "TimeAddUnderflow", ": " ] + "value" : [ "", "define ", "TimeSubtractOverflow", ": " ] }, { - "r" : "707", + "r" : "1436", "s" : [ { - "r" : "709", + "r" : "1438", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "maximum", " " ] }, { - "r" : "708", + "r" : "1437", "s" : [ { "value" : [ "Time" ] } ] } ] }, { - "value" : [ " + " ] + "value" : [ " - " ] }, { - "r" : "710", + "r" : "1439", "s" : [ { "value" : [ "(" ] }, { - "r" : "710", + "r" : "1439", "s" : [ { "value" : [ "-" ] }, { - "r" : "711", + "r" : "1440", "s" : [ { "value" : [ "1 ", "second" ] } ] @@ -14262,41 +20510,41 @@ module.exports['OutOfBounds'] = { } } ], "expression" : { - "type" : "Add", - "localId" : "707", + "type" : "Subtract", + "localId" : "1436", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "713", + "localId" : "1442", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "714", + "localId" : "1443", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { - "type" : "MinValue", - "localId" : "709", + "type" : "MaxValue", + "localId" : "1438", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "710", + "localId" : "1439", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "712", + "localId" : "1441", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "711", + "localId" : "1440", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "second", @@ -14305,26 +20553,26 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "717", + "localId" : "1446", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", - "name" : "TimeSubtractOverflow", + "name" : "TimeSubtractUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "717", + "r" : "1446", "s" : [ { - "value" : [ "", "define ", "TimeSubtractOverflow", ": " ] + "value" : [ "", "define ", "TimeSubtractUnderflow", ": " ] }, { - "r" : "718", + "r" : "1447", "s" : [ { - "r" : "720", + "r" : "1449", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "minimum", " " ] }, { - "r" : "719", + "r" : "1448", "s" : [ { "value" : [ "Time" ] } ] @@ -14332,21 +20580,76 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "721", + "r" : "1450", "s" : [ { - "value" : [ "(" ] + "value" : [ "1 ", "second" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "1447", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1451", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1452", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1449", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "valueType" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1450", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "second", + "annotation" : [ ] + } ] + } + }, { + "localId" : "1455", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimeSubtractNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1455", + "s" : [ { + "value" : [ "", "define ", "TimeSubtractNearOverflow", ": " ] + }, { + "r" : "1456", + "s" : [ { + "r" : "1458", + "s" : [ { + "value" : [ "maximum", " " ] }, { - "r" : "721", + "r" : "1457", "s" : [ { - "value" : [ "-" ] - }, { - "r" : "722", - "s" : [ { - "value" : [ "1 ", "second" ] - } ] + "value" : [ "Time" ] } ] - }, { - "value" : [ ")" ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1459", + "s" : [ { + "value" : [ "0 ", "seconds" ] } ] } ] } ] @@ -14354,68 +20657,56 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "718", + "localId" : "1456", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "724", + "localId" : "1460", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "725", + "localId" : "1461", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "720", + "localId" : "1458", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { - "type" : "Negate", - "localId" : "721", + "type" : "Quantity", + "localId" : "1459", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "723", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Quantity", - "localId" : "722", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "second", - "annotation" : [ ] - } + "value" : 0, + "unit" : "seconds", + "annotation" : [ ] } ] } }, { - "localId" : "728", + "localId" : "1464", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", - "name" : "TimeSubtractUnderflow", + "name" : "TimeSubtractNearUnderflow", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "728", + "r" : "1464", "s" : [ { - "value" : [ "", "define ", "TimeSubtractUnderflow", ": " ] + "value" : [ "", "define ", "TimeSubtractNearUnderflow", ": " ] }, { - "r" : "729", + "r" : "1465", "s" : [ { - "r" : "731", + "r" : "1467", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "730", + "r" : "1466", "s" : [ { "value" : [ "Time" ] } ] @@ -14423,9 +20714,9 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "732", + "r" : "1468", "s" : [ { - "value" : [ "1 ", "second" ] + "value" : [ "0 ", "seconds" ] } ] } ] } ] @@ -14433,37 +20724,37 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "729", + "localId" : "1465", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "733", + "localId" : "1469", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "734", + "localId" : "1470", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "731", + "localId" : "1467", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "732", + "localId" : "1468", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 1, - "unit" : "second", + "value" : 0, + "unit" : "seconds", "annotation" : [ ] } ] } }, { - "localId" : "737", + "localId" : "1473", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSuccessorOverflow", "context" : "Patient", @@ -14472,19 +20763,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "737", + "r" : "1473", "s" : [ { "value" : [ "", "define ", "TimeSuccessorOverflow", ": " ] }, { - "r" : "740", + "r" : "1476", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "739", + "r" : "1475", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "738", + "r" : "1474", "s" : [ { "value" : [ "Time" ] } ] @@ -14495,25 +20786,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "740", + "localId" : "1476", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "741", + "localId" : "1477", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "739", + "localId" : "1475", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } } }, { - "localId" : "744", + "localId" : "1480", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimePredecessorUnderflow", "context" : "Patient", @@ -14522,19 +20813,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "744", + "r" : "1480", "s" : [ { "value" : [ "", "define ", "TimePredecessorUnderflow", ": " ] }, { - "r" : "747", + "r" : "1483", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "746", + "r" : "1482", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "745", + "r" : "1481", "s" : [ { "value" : [ "Time" ] } ] @@ -14545,25 +20836,207 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "747", + "localId" : "1483", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "748", + "localId" : "1484", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } ], "operand" : { "type" : "MinValue", - "localId" : "746", + "localId" : "1482", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } } }, { - "localId" : "751", + "localId" : "1487", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimeSuccessorNearOverflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1487", + "s" : [ { + "value" : [ "", "define ", "TimeSuccessorNearOverflow", ": " ] + }, { + "r" : "1494", + "s" : [ { + "value" : [ "successor of " ] + }, { + "r" : "1488", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1488", + "s" : [ { + "r" : "1490", + "s" : [ { + "value" : [ "maximum", " " ] + }, { + "r" : "1489", + "s" : [ { + "value" : [ "Time" ] + } ] + } ] + }, { + "value" : [ " - " ] + }, { + "r" : "1491", + "s" : [ { + "value" : [ "1 ", "millisecond" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Successor", + "localId" : "1494", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1495", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Subtract", + "localId" : "1488", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1492", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1493", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MaxValue", + "localId" : "1490", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "valueType" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1491", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "millisecond", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "1498", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimePredecessorNearUnderflow", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "1498", + "s" : [ { + "value" : [ "", "define ", "TimePredecessorNearUnderflow", ": " ] + }, { + "r" : "1505", + "s" : [ { + "value" : [ "predecessor of " ] + }, { + "r" : "1499", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "1499", + "s" : [ { + "r" : "1501", + "s" : [ { + "value" : [ "minimum", " " ] + }, { + "r" : "1500", + "s" : [ { + "value" : [ "Time" ] + } ] + } ] + }, { + "value" : [ " + " ] + }, { + "r" : "1502", + "s" : [ { + "value" : [ "1 ", "millisecond" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Predecessor", + "localId" : "1505", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1506", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Add", + "localId" : "1499", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "1503", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "1504", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "MinValue", + "localId" : "1501", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "valueType" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + }, { + "type" : "Quantity", + "localId" : "1502", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 1, + "unit" : "millisecond", + "annotation" : [ ] + } ] + } + } + }, { + "localId" : "1509", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "ExpOverflow", "context" : "Patient", @@ -14572,19 +21045,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "751", + "r" : "1509", "s" : [ { "value" : [ "", "define ", "ExpOverflow", ": " ] }, { - "r" : "757", + "r" : "1515", "s" : [ { "value" : [ "Exp", "(" ] }, { - "r" : "753", + "r" : "1511", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "752", + "r" : "1510", "s" : [ { "value" : [ "Decimal" ] } ] @@ -14597,18 +21070,18 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Exp", - "localId" : "757", + "localId" : "1515", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "758", + "localId" : "1516", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "753", + "localId" : "1511", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] diff --git a/test/elm/convert/convert-test.ts b/test/elm/convert/convert-test.ts index 4a1e2dbf1..3913025f6 100644 --- a/test/elm/convert/convert-test.ts +++ b/test/elm/convert/convert-test.ts @@ -47,6 +47,18 @@ describe('FromString', () => { should(await this.integerInvalid.exec(this.ctx)).be.null(); }); + it("should convert '10' to Long", async function () { + (await this.longValid.exec(this.ctx)).should.equal(10); + }); + + it("should convert '10.2' to Long 10", async function () { + (await this.longDropDecimal.exec(this.ctx)).should.equal(10); + }); + + it("should be null trying to convert 'abc' to Long", async function () { + should(await this.longInvalid.exec(this.ctx)).be.null(); + }); + it('should convert "10 \'A\'" to Quantity', async function () { const quantity = await this.quantityStr.exec(this.ctx); quantity.value.should.equal(10); @@ -111,6 +123,10 @@ describe('FromInteger', () => { (await this.string10.exec(this.ctx)).should.equal('10'); }); + it('should convert 10 to 10L', async function () { + (await this.long10.exec(this.ctx)).should.equal(10); + }); + it('should convert 10 to 10.0', async function () { (await this.decimal10.exec(this.ctx)).should.equal(10.0); }); @@ -124,6 +140,32 @@ describe('FromInteger', () => { }); }); +describe('FromLong', () => { + beforeEach(function () { + setup(this, data); + }); + + it("should convert 10L to '10'", async function () { + (await this.string10.exec(this.ctx)).should.equal('10'); + }); + + it('should convert 10L to 10', async function () { + (await this.integer10.exec(this.ctx)).should.equal(10); + }); + + it('should convert 10L to 10.0', async function () { + (await this.decimal10.exec(this.ctx)).should.equal(10.0); + }); + + it('should convert null to null', async function () { + isNull(await this.longNull.exec(this.ctx)).should.equal(true); + }); + + it('should convert 10L to 10L', async function () { + (await this.longLong.exec(this.ctx)).should.equal(10); + }); +}); + describe('FromQuantity', () => { beforeEach(function () { setup(this, data); @@ -360,6 +402,66 @@ describe('ToInteger', () => { should(await this.tooSmallInt.exec(this.ctx)).be.null(); }); + it('should return 20 for 20L', async function () { + (await this.longTwenty.exec(this.ctx)).should.equal(20); + }); + + it('should return null if long larger than max integer', async function () { + should(await this.tooLargeLong.exec(this.ctx)).be.null(); + }); + + it('should return null if long smaller than min integer', async function () { + should(await this.tooSmallLong.exec(this.ctx)).be.null(); + }); + + it('should return 1 for boolean true', async function () { + (await this.booleanTrue.exec(this.ctx)).should.equal(1); + }); + + it('should return 0 for boolean false', async function () { + (await this.booleanFalse.exec(this.ctx)).should.equal(0); + }); +}); + +describe('ToLong', () => { + beforeEach(function () { + setup(this, data); + }); + + it('should return positive long without polarity sign', async function () { + (await this.noSign.exec(this.ctx)).should.equal(12345); + }); + + it('should return positive long with polarity sign', async function () { + (await this.positiveSign.exec(this.ctx)).should.equal(12345); + }); + + it('should return negative long', async function () { + (await this.negativeSign.exec(this.ctx)).should.equal(-12345); + }); + + it('should return null if long larger than max by a significant amount', async function () { + should(await this.definitelyTooLargeLong.exec(this.ctx)).be.null(); + }); + + // skipping because js number is imprecise at long max + it.skip('should return null if long larger than max', async function () { + should(await this.tooLargeLong.exec(this.ctx)).be.null(); + }); + + it('should return null if long smaller than min by a significant amount', async function () { + should(await this.definitelyTooSmallLong.exec(this.ctx)).be.null(); + }); + + // skipping because js number is imprecise at long max + it.skip('should return null if long smaller than min', async function () { + should(await this.tooSmallLong.exec(this.ctx)).be.null(); + }); + + it('should return 12345 for integer 12345', async function () { + (await this.int.exec(this.ctx)).should.equal(12345); + }); + it('should return 1 for boolean true', async function () { (await this.booleanTrue.exec(this.ctx)).should.equal(1); }); diff --git a/test/elm/convert/data.cql b/test/elm/convert/data.cql index bfa8b99ae..9a377d306 100644 --- a/test/elm/convert/data.cql +++ b/test/elm/convert/data.cql @@ -8,6 +8,9 @@ define decimalInvalid: convert 'abc' to Decimal define integerValid: convert '10' to Integer define integerDropDecimal: convert '10.2' to Integer define integerInvalid: convert 'abc' to Integer +define longValid: convert '10' to Long +define longDropDecimal: convert '10.2' to Long +define longInvalid: convert 'abc' to Long define quantityStr: convert '10 \'A\'' to Quantity define posQuantityStr: convert '+10 \'A\'' to Quantity define negQuantityStr: convert '-10 \'A\'' to Quantity @@ -21,10 +24,18 @@ define TimezoneTime: convert '14:30:00.0-07:00' to Time // 2:30PM Mountain Stand // @Test: FromInteger define string10: convert 10 to String +define long10: convert 10 to Long define decimal10: convert 10 to Decimal -define intNull: convert null to Decimal +define intNull: convert (null as Integer) to Decimal define intInt: convert 10 to Integer +// @Test: FromLong +define string10: convert 10L to String +define integer10: convert 10L to Integer +define decimal10: convert 10L to Decimal +define longNull: convert (null as Long) to Decimal +define longLong: convert 10L to Long + // @Test: FromQuantity define quantityStr: convert 10 'A' to String define negQuantityStr: convert -10 'A' to String @@ -77,9 +88,24 @@ define PositiveSign: ToInteger('+12345') define NegativeSign: ToInteger('-12345') define TooLargeInt: ToInteger('2147483648') define TooSmallInt: ToInteger('-2147483649') +define LongTwenty: ToInteger(20L); +define TooLargeLong: ToInteger(2147483648L); +define TooSmallLong: ToInteger(-2147483649L) define BooleanTrue: ToInteger(true) define BooleanFalse: ToInteger(false) +// @Test: ToLong +define NoSign: ToLong('12345') +define PositiveSign: ToLong('+12345') +define NegativeSign: ToLong('-12345') +define TooLargeLong: ToLong('9223372036854775808') +define DefinitelyTooLargeLong: ToLong('9223372036854780000') +define TooSmallLong: ToLong('-9223372036854775809') +define DefinitelyTooSmallLong: ToLong('-92233720368547800000') +define Int: ToLong(12345) +define BooleanTrue: ToLong(true) +define BooleanFalse: ToLong(false) + // @Test: ToQuantity define DecimalOverload: ToQuantity(0.1) define IntegerOverload: ToQuantity(13) diff --git a/test/elm/convert/data.js b/test/elm/convert/data.js index 4bb8f8352..6112735ca 100644 --- a/test/elm/convert/data.js +++ b/test/elm/convert/data.js @@ -21,6 +21,9 @@ define decimalInvalid: convert 'abc' to Decimal define integerValid: convert '10' to Integer define integerDropDecimal: convert '10.2' to Integer define integerInvalid: convert 'abc' to Integer +define longValid: convert '10' to Long +define longDropDecimal: convert '10.2' to Long +define longInvalid: convert 'abc' to Long define quantityStr: convert '10 \'A\'' to Quantity define posQuantityStr: convert '+10 \'A\'' to Quantity define negQuantityStr: convert '-10 \'A\'' to Quantity @@ -45,7 +48,7 @@ module.exports['FromString'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "370", + "r" : "397", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -572,8 +575,8 @@ module.exports['FromString'] = { } }, { "localId" : "289", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "quantityStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "longValid", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -582,7 +585,7 @@ module.exports['FromString'] = { "s" : { "r" : "289", "s" : [ { - "value" : [ "", "define ", "quantityStr", ": " ] + "value" : [ "", "define ", "longValid", ": " ] }, { "r" : "294", "s" : [ { @@ -590,23 +593,23 @@ module.exports['FromString'] = { }, { "r" : "291", "s" : [ { - "value" : [ "'10 \\'A\\''" ] + "value" : [ "'10'" ] } ] }, { "value" : [ " to " ] }, { "r" : "290", "s" : [ { - "value" : [ "Quantity" ] + "value" : [ "Long" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToQuantity", + "type" : "ToLong", "localId" : "294", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -619,14 +622,14 @@ module.exports['FromString'] = { "localId" : "291", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "10 'A'", + "value" : "10", "annotation" : [ ] } } }, { "localId" : "298", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "posQuantityStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "longDropDecimal", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -635,7 +638,7 @@ module.exports['FromString'] = { "s" : { "r" : "298", "s" : [ { - "value" : [ "", "define ", "posQuantityStr", ": " ] + "value" : [ "", "define ", "longDropDecimal", ": " ] }, { "r" : "303", "s" : [ { @@ -643,23 +646,23 @@ module.exports['FromString'] = { }, { "r" : "300", "s" : [ { - "value" : [ "'+10 \\'A\\''" ] + "value" : [ "'10.2'" ] } ] }, { "value" : [ " to " ] }, { "r" : "299", "s" : [ { - "value" : [ "Quantity" ] + "value" : [ "Long" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToQuantity", + "type" : "ToLong", "localId" : "303", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -672,14 +675,14 @@ module.exports['FromString'] = { "localId" : "300", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "+10 'A'", + "value" : "10.2", "annotation" : [ ] } } }, { "localId" : "307", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "negQuantityStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "longInvalid", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -688,7 +691,7 @@ module.exports['FromString'] = { "s" : { "r" : "307", "s" : [ { - "value" : [ "", "define ", "negQuantityStr", ": " ] + "value" : [ "", "define ", "longInvalid", ": " ] }, { "r" : "312", "s" : [ { @@ -696,23 +699,23 @@ module.exports['FromString'] = { }, { "r" : "309", "s" : [ { - "value" : [ "'-10 \\'A\\''" ] + "value" : [ "'abc'" ] } ] }, { "value" : [ " to " ] }, { "r" : "308", "s" : [ { - "value" : [ "Quantity" ] + "value" : [ "Long" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToQuantity", + "type" : "ToLong", "localId" : "312", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -725,14 +728,14 @@ module.exports['FromString'] = { "localId" : "309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "-10 'A'", + "value" : "abc", "annotation" : [ ] } } }, { "localId" : "316", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "quantityStrDecimal", + "name" : "quantityStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -741,7 +744,7 @@ module.exports['FromString'] = { "s" : { "r" : "316", "s" : [ { - "value" : [ "", "define ", "quantityStrDecimal", ": " ] + "value" : [ "", "define ", "quantityStr", ": " ] }, { "r" : "321", "s" : [ { @@ -749,7 +752,7 @@ module.exports['FromString'] = { }, { "r" : "318", "s" : [ { - "value" : [ "'10.0 \\'mA\\''" ] + "value" : [ "'10 \\'A\\''" ] } ] }, { "value" : [ " to " ] @@ -778,14 +781,14 @@ module.exports['FromString'] = { "localId" : "318", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "10.0 'mA'", + "value" : "10 'A'", "annotation" : [ ] } } }, { "localId" : "325", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "dateTimeStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "posQuantityStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -794,7 +797,7 @@ module.exports['FromString'] = { "s" : { "r" : "325", "s" : [ { - "value" : [ "", "define ", "dateTimeStr", ": " ] + "value" : [ "", "define ", "posQuantityStr", ": " ] }, { "r" : "330", "s" : [ { @@ -802,23 +805,23 @@ module.exports['FromString'] = { }, { "r" : "327", "s" : [ { - "value" : [ "'2015-01-02'" ] + "value" : [ "'+10 \\'A\\''" ] } ] }, { "value" : [ " to " ] }, { "r" : "326", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Quantity" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDateTime", + "type" : "ToQuantity", "localId" : "330", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -831,14 +834,14 @@ module.exports['FromString'] = { "localId" : "327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "2015-01-02", + "value" : "+10 'A'", "annotation" : [ ] } } }, { "localId" : "334", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "dateStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "negQuantityStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -847,7 +850,7 @@ module.exports['FromString'] = { "s" : { "r" : "334", "s" : [ { - "value" : [ "", "define ", "dateStr", ": " ] + "value" : [ "", "define ", "negQuantityStr", ": " ] }, { "r" : "339", "s" : [ { @@ -855,23 +858,23 @@ module.exports['FromString'] = { }, { "r" : "336", "s" : [ { - "value" : [ "'2015-01-02'" ] + "value" : [ "'-10 \\'A\\''" ] } ] }, { "value" : [ " to " ] }, { "r" : "335", "s" : [ { - "value" : [ "Date" ] + "value" : [ "Quantity" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDate", + "type" : "ToQuantity", "localId" : "339", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -884,14 +887,14 @@ module.exports['FromString'] = { "localId" : "336", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "2015-01-02", + "value" : "-10 'A'", "annotation" : [ ] } } }, { "localId" : "343", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "NullConvert", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "quantityStrDecimal", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -900,7 +903,7 @@ module.exports['FromString'] = { "s" : { "r" : "343", "s" : [ { - "value" : [ "", "define ", "NullConvert", ": " ] + "value" : [ "", "define ", "quantityStrDecimal", ": " ] }, { "r" : "348", "s" : [ { @@ -908,23 +911,23 @@ module.exports['FromString'] = { }, { "r" : "345", "s" : [ { - "value" : [ "'foo'" ] + "value" : [ "'10.0 \\'mA\\''" ] } ] }, { "value" : [ " to " ] }, { "r" : "344", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Quantity" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDateTime", + "type" : "ToQuantity", "localId" : "348", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -937,14 +940,14 @@ module.exports['FromString'] = { "localId" : "345", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "foo", + "value" : "10.0 'mA'", "annotation" : [ ] } } }, { "localId" : "352", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "ZDateTime", + "name" : "dateTimeStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -953,7 +956,7 @@ module.exports['FromString'] = { "s" : { "r" : "352", "s" : [ { - "value" : [ "", "define ", "ZDateTime", ": " ] + "value" : [ "", "define ", "dateTimeStr", ": " ] }, { "r" : "357", "s" : [ { @@ -961,7 +964,7 @@ module.exports['FromString'] = { }, { "r" : "354", "s" : [ { - "value" : [ "'2014-01-01T14:30:00.0Z'" ] + "value" : [ "'2015-01-02'" ] } ] }, { "value" : [ " to " ] @@ -990,14 +993,14 @@ module.exports['FromString'] = { "localId" : "354", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "2014-01-01T14:30:00.0Z", + "value" : "2015-01-02", "annotation" : [ ] } } }, { "localId" : "361", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "TimezoneDateTime", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "dateStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1006,7 +1009,7 @@ module.exports['FromString'] = { "s" : { "r" : "361", "s" : [ { - "value" : [ "// January 1st, 2014, 2:30PM UTC\n", "define ", "TimezoneDateTime", ": " ] + "value" : [ "", "define ", "dateStr", ": " ] }, { "r" : "366", "s" : [ { @@ -1014,23 +1017,23 @@ module.exports['FromString'] = { }, { "r" : "363", "s" : [ { - "value" : [ "'2014-01-01T14:30:00.0-07:00'" ] + "value" : [ "'2015-01-02'" ] } ] }, { "value" : [ " to " ] }, { "r" : "362", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Date" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDateTime", + "type" : "ToDate", "localId" : "366", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -1043,14 +1046,14 @@ module.exports['FromString'] = { "localId" : "363", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "2014-01-01T14:30:00.0-07:00", + "value" : "2015-01-02", "annotation" : [ ] } } }, { "localId" : "370", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", - "name" : "TimezoneTime", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "NullConvert", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1059,7 +1062,7 @@ module.exports['FromString'] = { "s" : { "r" : "370", "s" : [ { - "value" : [ "// January 1st, 2014, 2:30PM Mountain Standard (GMT-7:00)\n", "define ", "TimezoneTime", ": " ] + "value" : [ "", "define ", "NullConvert", ": " ] }, { "r" : "375", "s" : [ { @@ -1067,23 +1070,23 @@ module.exports['FromString'] = { }, { "r" : "372", "s" : [ { - "value" : [ "'14:30:00.0-07:00'" ] + "value" : [ "'foo'" ] } ] }, { "value" : [ " to " ] }, { "r" : "371", "s" : [ { - "value" : [ "Time" ] + "value" : [ "DateTime" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToTime", + "type" : "ToDateTime", "localId" : "375", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -1096,295 +1099,186 @@ module.exports['FromString'] = { "localId" : "372", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "14:30:00.0-07:00", + "value" : "foo", "annotation" : [ ] } } - } ] - } - } -} - -/* FromInteger -library TestSnippet version '1' -using Simple version '1.0.0' -context Patient -define string10: convert 10 to String -define decimal10: convert 10 to Decimal -define intNull: convert null to Decimal -define intInt: convert 10 to Integer -*/ - -module.exports['FromInteger'] = { - "library" : { - "localId" : "0", - "annotation" : [ { - "type" : "CqlToElmInfo", - "translatorVersion" : "4.2.0", - "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", - "signatureLevel" : "All" - }, { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "236", - "s" : [ { - "value" : [ "", "library TestSnippet version '1'" ] - } ] - } - } ], - "identifier" : { - "id" : "TestSnippet", - "version" : "1" - }, - "schemaIdentifier" : { - "id" : "urn:hl7-org:elm", - "version" : "r1" - }, - "usings" : { - "def" : [ { - "localId" : "1", - "localIdentifier" : "System", - "uri" : "urn:hl7-org:elm-types:r1", - "annotation" : [ ] }, { - "localId" : "206", - "localIdentifier" : "Simple", - "uri" : "https://github.com/cqframework/cql-execution/simple", - "version" : "1.0.0", + "localId" : "379", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "ZDateTime", + "context" : "Patient", + "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "206", + "r" : "379", "s" : [ { - "value" : [ "", "using " ] + "value" : [ "", "define ", "ZDateTime", ": " ] }, { + "r" : "384", "s" : [ { - "value" : [ "Simple" ] + "value" : [ "convert " ] + }, { + "r" : "381", + "s" : [ { + "value" : [ "'2014-01-01T14:30:00.0Z'" ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "380", + "s" : [ { + "value" : [ "DateTime" ] + } ] } ] - }, { - "value" : [ " version '1.0.0'" ] } ] } - } ] - } ] - }, - "contexts" : { - "def" : [ { - "localId" : "211", - "name" : "Patient", - "annotation" : [ ] - } ] - }, - "statements" : { - "def" : [ { - "localId" : "209", - "name" : "Patient", - "context" : "Patient", - "annotation" : [ ], + } ], "expression" : { - "type" : "SingletonFrom", - "localId" : "210", + "type" : "ToDateTime", + "localId" : "384", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], - "signature" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "385", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], "operand" : { - "type" : "Retrieve", - "localId" : "208", - "dataType" : "{https://github.com/cqframework/cql-execution/simple}Patient", - "annotation" : [ ], - "include" : [ ], - "codeFilter" : [ ], - "dateFilter" : [ ], - "otherFilter" : [ ] + "type" : "Literal", + "localId" : "381", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "2014-01-01T14:30:00.0Z", + "annotation" : [ ] } } }, { - "localId" : "214", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "string10", + "localId" : "388", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "TimezoneDateTime", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "214", + "r" : "388", "s" : [ { - "value" : [ "", "define ", "string10", ": " ] + "value" : [ "// January 1st, 2014, 2:30PM UTC\n", "define ", "TimezoneDateTime", ": " ] }, { - "r" : "218", + "r" : "393", "s" : [ { - "r" : "216", - "value" : [ "convert ", "10", " to " ] + "value" : [ "convert " ] }, { - "r" : "215", + "r" : "390", "s" : [ { - "value" : [ "String" ] + "value" : [ "'2014-01-01T14:30:00.0-07:00'" ] } ] - } ] - } ] - } - } ], - "expression" : { - "type" : "ToString", - "localId" : "218", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "219", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "216", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "10", - "annotation" : [ ] - } - } - }, { - "localId" : "222", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "decimal10", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "222", - "s" : [ { - "value" : [ "", "define ", "decimal10", ": " ] - }, { - "r" : "226", - "s" : [ { - "r" : "224", - "value" : [ "convert ", "10", " to " ] }, { - "r" : "223", + "value" : [ " to " ] + }, { + "r" : "389", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "DateTime" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDecimal", - "localId" : "226", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "ToDateTime", + "localId" : "393", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "227", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + "localId" : "394", + "name" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "224", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "10", + "localId" : "390", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "2014-01-01T14:30:00.0-07:00", "annotation" : [ ] } } }, { - "localId" : "230", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "intNull", + "localId" : "397", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "TimezoneTime", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "230", + "r" : "397", "s" : [ { - "value" : [ "", "define ", "intNull", ": " ] + "value" : [ "// January 1st, 2014, 2:30PM Mountain Standard (GMT-7:00)\n", "define ", "TimezoneTime", ": " ] }, { - "r" : "233", + "r" : "402", "s" : [ { - "r" : "232", - "value" : [ "convert ", "null", " to " ] + "value" : [ "convert " ] }, { - "r" : "231", + "r" : "399", "s" : [ { - "value" : [ "Decimal" ] + "value" : [ "'14:30:00.0-07:00'" ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "398", + "s" : [ { + "value" : [ "Time" ] } ] } ] } ] } } ], "expression" : { - "type" : "As", - "localId" : "233", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "asType" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "ToTime", + "localId" : "402", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], - "signature" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "403", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], "operand" : { - "type" : "Null", - "localId" : "232", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Any", + "type" : "Literal", + "localId" : "399", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "14:30:00.0-07:00", "annotation" : [ ] } } - }, { - "localId" : "236", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "intInt", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "236", - "s" : [ { - "value" : [ "", "define ", "intInt", ": " ] - }, { - "r" : "238", - "s" : [ { - "r" : "238", - "value" : [ "convert ", "10", " to " ] - }, { - "r" : "237", - "s" : [ { - "value" : [ "Integer" ] - } ] - } ] - } ] - } - } ], - "expression" : { - "type" : "Literal", - "localId" : "238", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "10", - "annotation" : [ ] - } } ] } } } -/* FromQuantity +/* FromInteger library TestSnippet version '1' using Simple version '1.0.0' context Patient -define quantityStr: convert 10 'A' to String -define negQuantityStr: convert -10 'A' to String -define posQuantityStr: convert +10 'A' to String -define quantityQuantity: convert 10 'A' to Quantity +define string10: convert 10 to String +define long10: convert 10 to Long +define decimal10: convert 10 to Decimal +define intNull: convert (null as Integer) to Decimal +define intInt: convert 10 to Integer */ -module.exports['FromQuantity'] = { +module.exports['FromInteger'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -1396,7 +1290,7 @@ module.exports['FromQuantity'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "240", + "r" : "248", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -1471,7 +1365,7 @@ module.exports['FromQuantity'] = { }, { "localId" : "214", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "quantityStr", + "name" : "string10", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1480,18 +1374,12 @@ module.exports['FromQuantity'] = { "s" : { "r" : "214", "s" : [ { - "value" : [ "", "define ", "quantityStr", ": " ] + "value" : [ "", "define ", "string10", ": " ] }, { "r" : "218", "s" : [ { - "value" : [ "convert " ] - }, { "r" : "216", - "s" : [ { - "value" : [ "10 ", "'A'" ] - } ] - }, { - "value" : [ " to " ] + "value" : [ "convert ", "10", " to " ] }, { "r" : "215", "s" : [ { @@ -1509,22 +1397,22 @@ module.exports['FromQuantity'] = { "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "219", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { - "type" : "Quantity", + "type" : "Literal", "localId" : "216", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 10, - "unit" : "A", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", "annotation" : [ ] } } }, { "localId" : "222", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "negQuantityStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "long10", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1533,161 +1421,200 @@ module.exports['FromQuantity'] = { "s" : { "r" : "222", "s" : [ { - "value" : [ "", "define ", "negQuantityStr", ": " ] + "value" : [ "", "define ", "long10", ": " ] }, { - "r" : "228", + "r" : "226", "s" : [ { - "value" : [ "convert " ] - }, { "r" : "224", - "s" : [ { - "value" : [ "-" ] - }, { - "r" : "225", - "s" : [ { - "value" : [ "10 ", "'A'" ] - } ] - } ] - }, { - "value" : [ " to " ] + "value" : [ "convert ", "10", " to " ] }, { "r" : "223", "s" : [ { - "value" : [ "String" ] + "value" : [ "Long" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToString", - "localId" : "228", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "type" : "ToLong", + "localId" : "226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "229", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { - "type" : "Negate", + "type" : "Literal", "localId" : "224", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "226", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Quantity", - "localId" : "225", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 10, - "unit" : "A", - "annotation" : [ ] - } + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", + "annotation" : [ ] } } }, { - "localId" : "232", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "posQuantityStr", + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "decimal10", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "232", + "r" : "230", "s" : [ { - "value" : [ "", "define ", "posQuantityStr", ": " ] + "value" : [ "", "define ", "decimal10", ": " ] }, { - "r" : "236", + "r" : "234", "s" : [ { - "value" : [ "convert " ] - }, { - "r" : "234", - "s" : [ { - "value" : [ "+" ] - }, { - "r" : "234", - "s" : [ { - "value" : [ "10 ", "'A'" ] - } ] - } ] - }, { - "value" : [ " to " ] + "r" : "232", + "value" : [ "convert ", "10", " to " ] }, { - "r" : "233", + "r" : "231", "s" : [ { - "value" : [ "String" ] + "value" : [ "Decimal" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToString", - "localId" : "236", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "type" : "ToDecimal", + "localId" : "234", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "237", - "name" : "{urn:hl7-org:elm-types:r1}Quantity", + "localId" : "235", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { - "type" : "Quantity", - "localId" : "234", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 10, - "unit" : "A", + "type" : "Literal", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", "annotation" : [ ] } } }, { - "localId" : "240", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "name" : "quantityQuantity", + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "intNull", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "240", + "r" : "238", "s" : [ { - "value" : [ "", "define ", "quantityQuantity", ": " ] + "value" : [ "", "define ", "intNull", ": " ] }, { - "r" : "242", + "r" : "244", "s" : [ { "value" : [ "convert " ] }, { - "r" : "242", + "r" : "240", "s" : [ { - "value" : [ "10 ", "'A'" ] + "value" : [ "(" ] + }, { + "r" : "240", + "s" : [ { + "r" : "241", + "value" : [ "null", " as " ] + }, { + "r" : "242", + "s" : [ { + "value" : [ "Integer" ] + } ] + } ] + }, { + "value" : [ ")" ] } ] }, { "value" : [ " to " ] }, { - "r" : "241", + "r" : "239", "s" : [ { - "value" : [ "Quantity" ] + "value" : [ "Decimal" ] } ] } ] } ] } } ], "expression" : { - "type" : "Quantity", - "localId" : "242", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", - "value" : 10, - "unit" : "A", + "type" : "ToDecimal", + "localId" : "244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "245", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "As", + "localId" : "240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "strict" : false, + "annotation" : [ ], + "signature" : [ ], + "operand" : { + "type" : "Null", + "localId" : "241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Any", + "annotation" : [ ] + }, + "asTypeSpecifier" : { + "type" : "NamedTypeSpecifier", + "localId" : "242", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } + } + } + }, { + "localId" : "248", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "intInt", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "248", + "s" : [ { + "value" : [ "", "define ", "intInt", ": " ] + }, { + "r" : "250", + "s" : [ { + "r" : "250", + "value" : [ "convert ", "10", " to " ] + }, { + "r" : "249", + "s" : [ { + "value" : [ "Integer" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Literal", + "localId" : "250", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", "annotation" : [ ] } } ] @@ -1695,17 +1622,18 @@ module.exports['FromQuantity'] = { } } -/* FromBoolean +/* FromLong library TestSnippet version '1' using Simple version '1.0.0' context Patient -define booleanTrueStr: convert true to String -define booleanFalseStr: convert false to String -define booleanTrueBool: convert true to Boolean -define booleanFalseBool: convert false to Boolean +define string10: convert 10L to String +define integer10: convert 10L to Integer +define decimal10: convert 10L to Decimal +define longNull: convert (null as Long) to Decimal +define longLong: convert 10L to Long */ -module.exports['FromBoolean'] = { +module.exports['FromLong'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -1717,7 +1645,7 @@ module.exports['FromBoolean'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "235", + "r" : "248", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -1792,7 +1720,7 @@ module.exports['FromBoolean'] = { }, { "localId" : "214", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "booleanTrueStr", + "name" : "string10", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1801,12 +1729,12 @@ module.exports['FromBoolean'] = { "s" : { "r" : "214", "s" : [ { - "value" : [ "", "define ", "booleanTrueStr", ": " ] + "value" : [ "", "define ", "string10", ": " ] }, { "r" : "218", "s" : [ { "r" : "216", - "value" : [ "convert ", "true", " to " ] + "value" : [ "convert ", "10L", " to " ] }, { "r" : "215", "s" : [ { @@ -1824,22 +1752,22 @@ module.exports['FromBoolean'] = { "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "219", - "name" : "{urn:hl7-org:elm-types:r1}Boolean", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", "localId" : "216", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", - "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", - "value" : "true", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", "annotation" : [ ] } } }, { "localId" : "222", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "booleanFalseStr", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "integer10", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1848,45 +1776,45 @@ module.exports['FromBoolean'] = { "s" : { "r" : "222", "s" : [ { - "value" : [ "", "define ", "booleanFalseStr", ": " ] + "value" : [ "", "define ", "integer10", ": " ] }, { "r" : "226", "s" : [ { "r" : "224", - "value" : [ "convert ", "false", " to " ] + "value" : [ "convert ", "10L", " to " ] }, { "r" : "223", "s" : [ { - "value" : [ "String" ] + "value" : [ "Integer" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToString", + "type" : "ToInteger", "localId" : "226", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "227", - "name" : "{urn:hl7-org:elm-types:r1}Boolean", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", "localId" : "224", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", - "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", - "value" : "false", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", "annotation" : [ ] } } }, { "localId" : "230", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", - "name" : "booleanTrueBool", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "decimal10", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1895,51 +1823,142 @@ module.exports['FromBoolean'] = { "s" : { "r" : "230", "s" : [ { - "value" : [ "", "define ", "booleanTrueBool", ": " ] + "value" : [ "", "define ", "decimal10", ": " ] }, { - "r" : "232", + "r" : "234", "s" : [ { "r" : "232", - "value" : [ "convert ", "true", " to " ] + "value" : [ "convert ", "10L", " to " ] }, { "r" : "231", "s" : [ { - "value" : [ "Boolean" ] + "value" : [ "Decimal" ] } ] } ] } ] } } ], "expression" : { - "type" : "Literal", - "localId" : "232", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", - "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", - "value" : "true", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "234", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "235", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } } }, { - "localId" : "235", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", - "name" : "booleanFalseBool", + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "longNull", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "235", + "r" : "238", "s" : [ { - "value" : [ "", "define ", "booleanFalseBool", ": " ] + "value" : [ "", "define ", "longNull", ": " ] }, { - "r" : "237", + "r" : "244", "s" : [ { - "r" : "237", - "value" : [ "convert ", "false", " to " ] + "value" : [ "convert " ] }, { - "r" : "236", + "r" : "240", "s" : [ { - "value" : [ "Boolean" ] + "value" : [ "(" ] + }, { + "r" : "240", + "s" : [ { + "r" : "241", + "value" : [ "null", " as " ] + }, { + "r" : "242", + "s" : [ { + "value" : [ "Long" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "239", + "s" : [ { + "value" : [ "Decimal" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDecimal", + "localId" : "244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "245", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "As", + "localId" : "240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "strict" : false, + "annotation" : [ ], + "signature" : [ ], + "operand" : { + "type" : "Null", + "localId" : "241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Any", + "annotation" : [ ] + }, + "asTypeSpecifier" : { + "type" : "NamedTypeSpecifier", + "localId" : "242", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } + } + } + }, { + "localId" : "248", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "longLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "248", + "s" : [ { + "value" : [ "", "define ", "longLong", ": " ] + }, { + "r" : "250", + "s" : [ { + "r" : "250", + "value" : [ "convert ", "10L", " to " ] + }, { + "r" : "249", + "s" : [ { + "value" : [ "Long" ] } ] } ] } ] @@ -1947,10 +1966,10 @@ module.exports['FromBoolean'] = { } ], "expression" : { "type" : "Literal", - "localId" : "237", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", - "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", - "value" : "false", + "localId" : "250", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", "annotation" : [ ] } } ] @@ -1958,16 +1977,17 @@ module.exports['FromBoolean'] = { } } -/* FromDateTime +/* FromQuantity library TestSnippet version '1' using Simple version '1.0.0' context Patient -define dateTimeToStr: convert @2015-01-02T12:01:02.321-06:00 to String -define dateTimeToDate: convert @2015-01-02T12:01:02.321-06:00 to Date -define dateTimeToDateTime: convert @2015-01-02T12:01:02.321-06:00 to DateTime -*/ - -module.exports['FromDateTime'] = { +define quantityStr: convert 10 'A' to String +define negQuantityStr: convert -10 'A' to String +define posQuantityStr: convert +10 'A' to String +define quantityQuantity: convert 10 'A' to Quantity +*/ + +module.exports['FromQuantity'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -1979,7 +1999,7 @@ module.exports['FromDateTime'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "246", + "r" : "240", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -2054,7 +2074,7 @@ module.exports['FromDateTime'] = { }, { "localId" : "214", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "dateTimeToStr", + "name" : "quantityStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -2063,12 +2083,18 @@ module.exports['FromDateTime'] = { "s" : { "r" : "214", "s" : [ { - "value" : [ "", "define ", "dateTimeToStr", ": " ] + "value" : [ "", "define ", "quantityStr", ": " ] }, { - "r" : "226", + "r" : "218", "s" : [ { + "value" : [ "convert " ] + }, { "r" : "216", - "value" : [ "convert ", "@2015-01-02T12:01:02.321-06:00", " to " ] + "s" : [ { + "value" : [ "10 ", "'A'" ] + } ] + }, { + "value" : [ " to " ] }, { "r" : "215", "s" : [ { @@ -2080,288 +2106,209 @@ module.exports['FromDateTime'] = { } ], "expression" : { "type" : "ToString", - "localId" : "226", + "localId" : "218", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "227", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "219", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { - "type" : "DateTime", + "type" : "Quantity", "localId" : "216", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "217", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "218", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "day" : { - "type" : "Literal", - "localId" : "219", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - }, - "hour" : { - "type" : "Literal", - "localId" : "220", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "12", - "annotation" : [ ] - }, - "minute" : { - "type" : "Literal", - "localId" : "221", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "second" : { - "type" : "Literal", - "localId" : "222", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - }, - "millisecond" : { - "type" : "Literal", - "localId" : "223", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "321", - "annotation" : [ ] - }, - "timezoneOffset" : { - "type" : "Literal", - "localId" : "224", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "-6.0", - "annotation" : [ ] - } + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 10, + "unit" : "A", + "annotation" : [ ] } } }, { - "localId" : "230", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "dateTimeToDate", + "localId" : "222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "negQuantityStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "230", + "r" : "222", "s" : [ { - "value" : [ "", "define ", "dateTimeToDate", ": " ] + "value" : [ "", "define ", "negQuantityStr", ": " ] }, { - "r" : "242", + "r" : "228", "s" : [ { - "r" : "232", - "value" : [ "convert ", "@2015-01-02T12:01:02.321-06:00", " to " ] + "value" : [ "convert " ] }, { - "r" : "231", + "r" : "224", "s" : [ { - "value" : [ "Date" ] + "value" : [ "-" ] + }, { + "r" : "225", + "s" : [ { + "value" : [ "10 ", "'A'" ] + } ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "223", + "s" : [ { + "value" : [ "String" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDate", - "localId" : "242", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "type" : "ToString", + "localId" : "228", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "243", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "229", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { - "type" : "DateTime", - "localId" : "232", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "Negate", + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "233", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "234", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "day" : { - "type" : "Literal", - "localId" : "235", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - }, - "hour" : { - "type" : "Literal", - "localId" : "236", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "12", - "annotation" : [ ] - }, - "minute" : { - "type" : "Literal", - "localId" : "237", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "second" : { - "type" : "Literal", - "localId" : "238", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - }, - "millisecond" : { - "type" : "Literal", - "localId" : "239", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "321", + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "226", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] - }, - "timezoneOffset" : { - "type" : "Literal", - "localId" : "240", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "-6.0", + } ], + "operand" : { + "type" : "Quantity", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 10, + "unit" : "A", "annotation" : [ ] } } } }, { - "localId" : "246", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "dateTimeToDateTime", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "posQuantityStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "246", + "r" : "232", "s" : [ { - "value" : [ "", "define ", "dateTimeToDateTime", ": " ] + "value" : [ "", "define ", "posQuantityStr", ": " ] }, { - "r" : "248", + "r" : "236", "s" : [ { - "r" : "248", - "value" : [ "convert ", "@2015-01-02T12:01:02.321-06:00", " to " ] + "value" : [ "convert " ] }, { - "r" : "247", + "r" : "234", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "+" ] + }, { + "r" : "234", + "s" : [ { + "value" : [ "10 ", "'A'" ] + } ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "233", + "s" : [ { + "value" : [ "String" ] } ] } ] } ] } } ], "expression" : { - "type" : "DateTime", - "localId" : "248", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "ToString", + "localId" : "236", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "249", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "237", + "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "250", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "day" : { - "type" : "Literal", - "localId" : "251", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - }, - "hour" : { - "type" : "Literal", - "localId" : "252", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "12", - "annotation" : [ ] - }, - "minute" : { - "type" : "Literal", - "localId" : "253", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "second" : { - "type" : "Literal", - "localId" : "254", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", - "annotation" : [ ] - }, - "millisecond" : { - "type" : "Literal", - "localId" : "255", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "321", - "annotation" : [ ] - }, - "timezoneOffset" : { - "type" : "Literal", - "localId" : "256", - "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", - "value" : "-6.0", + } ], + "operand" : { + "type" : "Quantity", + "localId" : "234", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 10, + "unit" : "A", "annotation" : [ ] } } + }, { + "localId" : "240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "name" : "quantityQuantity", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "240", + "s" : [ { + "value" : [ "", "define ", "quantityQuantity", ": " ] + }, { + "r" : "242", + "s" : [ { + "value" : [ "convert " ] + }, { + "r" : "242", + "s" : [ { + "value" : [ "10 ", "'A'" ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "241", + "s" : [ { + "value" : [ "Quantity" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Quantity", + "localId" : "242", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", + "value" : 10, + "unit" : "A", + "annotation" : [ ] + } } ] } } } -/* FromDate +/* FromBoolean library TestSnippet version '1' using Simple version '1.0.0' context Patient -define dateYMDToDateTime: convert @2015-01-01 to DateTime -define dateYMToDateTime: convert @2015-01 to DateTime -define dateYToDateTime: convert @2015 to DateTime -define dateToDate: convert @2015-01-01 to Date -define dateToStr: convert @2015-01-01 to String +define booleanTrueStr: convert true to String +define booleanFalseStr: convert false to String +define booleanTrueBool: convert true to Boolean +define booleanFalseBool: convert false to Boolean */ -module.exports['FromDate'] = { +module.exports['FromBoolean'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -2373,7 +2320,7 @@ module.exports['FromDate'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "256", + "r" : "235", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -2447,8 +2394,8 @@ module.exports['FromDate'] = { } }, { "localId" : "214", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "dateYMDToDateTime", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "booleanTrueStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -2457,310 +2404,173 @@ module.exports['FromDate'] = { "s" : { "r" : "214", "s" : [ { - "value" : [ "", "define ", "dateYMDToDateTime", ": " ] + "value" : [ "", "define ", "booleanTrueStr", ": " ] }, { - "r" : "222", + "r" : "218", "s" : [ { - "r" : "220", - "value" : [ "convert ", "@2015-01-01", " to " ] + "r" : "216", + "value" : [ "convert ", "true", " to " ] }, { "r" : "215", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "String" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDateTime", - "localId" : "222", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "ToString", + "localId" : "218", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "223", - "name" : "{urn:hl7-org:elm-types:r1}Date", + "localId" : "219", + "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { - "type" : "Date", - "localId" : "220", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "217", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "218", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "day" : { - "type" : "Literal", - "localId" : "219", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "216", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", + "value" : "true", + "annotation" : [ ] } } }, { - "localId" : "226", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "dateYMToDateTime", + "localId" : "222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "booleanFalseStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "226", + "r" : "222", "s" : [ { - "value" : [ "", "define ", "dateYMToDateTime", ": " ] + "value" : [ "", "define ", "booleanFalseStr", ": " ] }, { - "r" : "233", + "r" : "226", "s" : [ { - "r" : "231", - "value" : [ "convert ", "@2015-01", " to " ] + "r" : "224", + "value" : [ "convert ", "false", " to " ] }, { - "r" : "227", + "r" : "223", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "String" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDateTime", - "localId" : "233", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "ToString", + "localId" : "226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "234", - "name" : "{urn:hl7-org:elm-types:r1}Date", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { - "type" : "Date", - "localId" : "231", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "229", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "230", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", + "value" : "false", + "annotation" : [ ] } } }, { - "localId" : "237", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "name" : "dateYToDateTime", + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "name" : "booleanTrueBool", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "237", + "r" : "230", "s" : [ { - "value" : [ "", "define ", "dateYToDateTime", ": " ] + "value" : [ "", "define ", "booleanTrueBool", ": " ] }, { - "r" : "243", + "r" : "232", "s" : [ { - "r" : "241", - "value" : [ "convert ", "@2015", " to " ] + "r" : "232", + "value" : [ "convert ", "true", " to " ] }, { - "r" : "238", + "r" : "231", "s" : [ { - "value" : [ "DateTime" ] + "value" : [ "Boolean" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToDateTime", - "localId" : "243", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "244", - "name" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Date", - "localId" : "241", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "240", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - } - } - } - }, { - "localId" : "247", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "name" : "dateToDate", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "247", - "s" : [ { - "value" : [ "", "define ", "dateToDate", ": " ] - }, { - "r" : "253", - "s" : [ { - "r" : "253", - "value" : [ "convert ", "@2015-01-01", " to " ] - }, { - "r" : "248", - "s" : [ { - "value" : [ "Date" ] - } ] - } ] - } ] - } - } ], - "expression" : { - "type" : "Date", - "localId" : "253", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "250", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "251", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "day" : { - "type" : "Literal", - "localId" : "252", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", + "value" : "true", + "annotation" : [ ] } }, { - "localId" : "256", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "dateToStr", + "localId" : "235", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "name" : "booleanFalseBool", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "256", + "r" : "235", "s" : [ { - "value" : [ "", "define ", "dateToStr", ": " ] + "value" : [ "", "define ", "booleanFalseBool", ": " ] }, { - "r" : "264", + "r" : "237", "s" : [ { - "r" : "262", - "value" : [ "convert ", "@2015-01-01", " to " ] + "r" : "237", + "value" : [ "convert ", "false", " to " ] }, { - "r" : "257", + "r" : "236", "s" : [ { - "value" : [ "String" ] + "value" : [ "Boolean" ] } ] } ] } ] } } ], "expression" : { - "type" : "ToString", - "localId" : "264", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "265", - "name" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Date", - "localId" : "262", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", - "annotation" : [ ], - "signature" : [ ], - "year" : { - "type" : "Literal", - "localId" : "259", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2015", - "annotation" : [ ] - }, - "month" : { - "type" : "Literal", - "localId" : "260", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - }, - "day" : { - "type" : "Literal", - "localId" : "261", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "1", - "annotation" : [ ] - } - } + "type" : "Literal", + "localId" : "237", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", + "value" : "false", + "annotation" : [ ] } } ] } } } -/* FromTime +/* FromDateTime library TestSnippet version '1' using Simple version '1.0.0' context Patient -define timeStr: convert @T11:57 to String -define timeTime: convert @T11:57 to Time +define dateTimeToStr: convert @2015-01-02T12:01:02.321-06:00 to String +define dateTimeToDate: convert @2015-01-02T12:01:02.321-06:00 to Date +define dateTimeToDateTime: convert @2015-01-02T12:01:02.321-06:00 to DateTime */ -module.exports['FromTime'] = { +module.exports['FromDateTime'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -2772,7 +2582,7 @@ module.exports['FromTime'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "224", + "r" : "246", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -2847,7 +2657,7 @@ module.exports['FromTime'] = { }, { "localId" : "214", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "timeStr", + "name" : "dateTimeToStr", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -2856,12 +2666,12 @@ module.exports['FromTime'] = { "s" : { "r" : "214", "s" : [ { - "value" : [ "", "define ", "timeStr", ": " ] + "value" : [ "", "define ", "dateTimeToStr", ": " ] }, { - "r" : "220", + "r" : "226", "s" : [ { "r" : "216", - "value" : [ "convert ", "@T11:57", " to " ] + "value" : [ "convert ", "@2015-01-02T12:01:02.321-06:00", " to " ] }, { "r" : "215", "s" : [ { @@ -2873,102 +2683,288 @@ module.exports['FromTime'] = { } ], "expression" : { "type" : "ToString", - "localId" : "220", + "localId" : "226", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "221", - "name" : "{urn:hl7-org:elm-types:r1}Time", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { - "type" : "Time", + "type" : "DateTime", "localId" : "216", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ ], - "hour" : { + "year" : { "type" : "Literal", "localId" : "217", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "11", + "value" : "2015", "annotation" : [ ] }, - "minute" : { + "month" : { "type" : "Literal", "localId" : "218", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "57", + "value" : "1", + "annotation" : [ ] + }, + "day" : { + "type" : "Literal", + "localId" : "219", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + }, + "hour" : { + "type" : "Literal", + "localId" : "220", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "12", + "annotation" : [ ] + }, + "minute" : { + "type" : "Literal", + "localId" : "221", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "second" : { + "type" : "Literal", + "localId" : "222", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + }, + "millisecond" : { + "type" : "Literal", + "localId" : "223", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "321", + "annotation" : [ ] + }, + "timezoneOffset" : { + "type" : "Literal", + "localId" : "224", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "-6.0", "annotation" : [ ] } } } }, { - "localId" : "224", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", - "name" : "timeTime", + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "dateTimeToDate", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "224", + "r" : "230", "s" : [ { - "value" : [ "", "define ", "timeTime", ": " ] + "value" : [ "", "define ", "dateTimeToDate", ": " ] }, { - "r" : "226", + "r" : "242", "s" : [ { - "r" : "226", - "value" : [ "convert ", "@T11:57", " to " ] + "r" : "232", + "value" : [ "convert ", "@2015-01-02T12:01:02.321-06:00", " to " ] }, { - "r" : "225", + "r" : "231", "s" : [ { - "value" : [ "Time" ] + "value" : [ "Date" ] } ] } ] } ] } } ], "expression" : { - "type" : "Time", - "localId" : "226", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "type" : "ToDate", + "localId" : "242", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], - "signature" : [ ], - "hour" : { - "type" : "Literal", - "localId" : "227", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "11", - "annotation" : [ ] - }, - "minute" : { - "type" : "Literal", - "localId" : "228", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "57", + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "243", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] - } + } ], + "operand" : { + "type" : "DateTime", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "233", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + }, + "month" : { + "type" : "Literal", + "localId" : "234", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "day" : { + "type" : "Literal", + "localId" : "235", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + }, + "hour" : { + "type" : "Literal", + "localId" : "236", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "12", + "annotation" : [ ] + }, + "minute" : { + "type" : "Literal", + "localId" : "237", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "second" : { + "type" : "Literal", + "localId" : "238", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + }, + "millisecond" : { + "type" : "Literal", + "localId" : "239", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "321", + "annotation" : [ ] + }, + "timezoneOffset" : { + "type" : "Literal", + "localId" : "240", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "-6.0", + "annotation" : [ ] + } + } + } + }, { + "localId" : "246", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "dateTimeToDateTime", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "246", + "s" : [ { + "value" : [ "", "define ", "dateTimeToDateTime", ": " ] + }, { + "r" : "248", + "s" : [ { + "r" : "248", + "value" : [ "convert ", "@2015-01-02T12:01:02.321-06:00", " to " ] + }, { + "r" : "247", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "DateTime", + "localId" : "248", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "249", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + }, + "month" : { + "type" : "Literal", + "localId" : "250", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "day" : { + "type" : "Literal", + "localId" : "251", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + }, + "hour" : { + "type" : "Literal", + "localId" : "252", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "12", + "annotation" : [ ] + }, + "minute" : { + "type" : "Literal", + "localId" : "253", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "second" : { + "type" : "Literal", + "localId" : "254", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + }, + "millisecond" : { + "type" : "Literal", + "localId" : "255", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "321", + "annotation" : [ ] + }, + "timezoneOffset" : { + "type" : "Literal", + "localId" : "256", + "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", + "value" : "-6.0", + "annotation" : [ ] + } } } ] } } } -/* FromCode +/* FromDate library TestSnippet version '1' using Simple version '1.0.0' -codesystem "SNOMED-CT": '2.16.840.1.113883.6.96' context Patient -define hepB: Code '66071002' from "SNOMED-CT" display 'Type B viral hepatitis' -define codeConcept: convert hepB to Concept -define codeCode: convert hepB to Code -define foo: 'bar' +define dateYMDToDateTime: convert @2015-01-01 to DateTime +define dateYMToDateTime: convert @2015-01 to DateTime +define dateYToDateTime: convert @2015 to DateTime +define dateToDate: convert @2015-01-01 to Date +define dateToStr: convert @2015-01-01 to String */ -module.exports['FromCode'] = { +module.exports['FromDate'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -2980,7 +2976,7 @@ module.exports['FromCode'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "256", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -3023,46 +3019,27 @@ module.exports['FromCode'] = { } ] } ] }, - "codeSystems" : { - "def" : [ { - "localId" : "208", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}CodeSystem", - "name" : "SNOMED-CT", - "id" : "2.16.840.1.113883.6.96", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "208", - "s" : [ { - "value" : [ "", "codesystem ", "\"SNOMED-CT\"", ": ", "'2.16.840.1.113883.6.96'" ] - } ] - } - } ] - } ] - }, "contexts" : { "def" : [ { - "localId" : "213", + "localId" : "211", "name" : "Patient", "annotation" : [ ] } ] }, "statements" : { "def" : [ { - "localId" : "211", + "localId" : "209", "name" : "Patient", "context" : "Patient", "annotation" : [ ], "expression" : { "type" : "SingletonFrom", - "localId" : "212", + "localId" : "210", "annotation" : [ ], "signature" : [ ], "operand" : { "type" : "Retrieve", - "localId" : "210", + "localId" : "208", "dataType" : "{https://github.com/cqframework/cql-execution/simple}Patient", "annotation" : [ ], "include" : [ ], @@ -3072,188 +3049,1334 @@ module.exports['FromCode'] = { } } }, { - "localId" : "216", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", - "name" : "hepB", + "localId" : "214", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "dateYMDToDateTime", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "216", + "r" : "214", "s" : [ { - "value" : [ "", "define ", "hepB", ": " ] + "value" : [ "", "define ", "dateYMDToDateTime", ": " ] }, { - "r" : "217", + "r" : "222", "s" : [ { - "value" : [ "Code ", "'66071002'", " from " ] + "r" : "220", + "value" : [ "convert ", "@2015-01-01", " to " ] }, { - "r" : "218", + "r" : "215", "s" : [ { - "value" : [ "\"SNOMED-CT\"" ] + "value" : [ "DateTime" ] } ] - }, { - "value" : [ " display ", "'Type B viral hepatitis'" ] } ] } ] } } ], "expression" : { - "type" : "Code", - "localId" : "217", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", - "code" : "66071002", - "display" : "Type B viral hepatitis", + "type" : "ToDateTime", + "localId" : "222", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], - "system" : { - "localId" : "218", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}CodeSystem", - "name" : "SNOMED-CT", + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "223", + "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] - } - } - }, { - "localId" : "221", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Concept", - "name" : "codeConcept", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "221", - "s" : [ { - "value" : [ "", "define ", "codeConcept", ": " ] - }, { - "r" : "225", - "s" : [ { - "value" : [ "convert " ] - }, { - "r" : "223", - "s" : [ { + } ], + "operand" : { + "type" : "Date", + "localId" : "220", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "217", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + }, + "month" : { + "type" : "Literal", + "localId" : "218", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "day" : { + "type" : "Literal", + "localId" : "219", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } + } + }, { + "localId" : "226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "dateYMToDateTime", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "226", + "s" : [ { + "value" : [ "", "define ", "dateYMToDateTime", ": " ] + }, { + "r" : "233", + "s" : [ { + "r" : "231", + "value" : [ "convert ", "@2015-01", " to " ] + }, { + "r" : "227", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDateTime", + "localId" : "233", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "234", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Date", + "localId" : "231", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "229", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + }, + "month" : { + "type" : "Literal", + "localId" : "230", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } + } + }, { + "localId" : "237", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "name" : "dateYToDateTime", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "237", + "s" : [ { + "value" : [ "", "define ", "dateYToDateTime", ": " ] + }, { + "r" : "243", + "s" : [ { + "r" : "241", + "value" : [ "convert ", "@2015", " to " ] + }, { + "r" : "238", + "s" : [ { + "value" : [ "DateTime" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDateTime", + "localId" : "243", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "244", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Date", + "localId" : "241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "240", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + } + } + } + }, { + "localId" : "247", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "name" : "dateToDate", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "247", + "s" : [ { + "value" : [ "", "define ", "dateToDate", ": " ] + }, { + "r" : "253", + "s" : [ { + "r" : "253", + "value" : [ "convert ", "@2015-01-01", " to " ] + }, { + "r" : "248", + "s" : [ { + "value" : [ "Date" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Date", + "localId" : "253", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "250", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + }, + "month" : { + "type" : "Literal", + "localId" : "251", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "day" : { + "type" : "Literal", + "localId" : "252", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } + }, { + "localId" : "256", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "dateToStr", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "256", + "s" : [ { + "value" : [ "", "define ", "dateToStr", ": " ] + }, { + "r" : "264", + "s" : [ { + "r" : "262", + "value" : [ "convert ", "@2015-01-01", " to " ] + }, { + "r" : "257", + "s" : [ { + "value" : [ "String" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToString", + "localId" : "264", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "265", + "name" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Date", + "localId" : "262", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", + "annotation" : [ ], + "signature" : [ ], + "year" : { + "type" : "Literal", + "localId" : "259", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2015", + "annotation" : [ ] + }, + "month" : { + "type" : "Literal", + "localId" : "260", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + }, + "day" : { + "type" : "Literal", + "localId" : "261", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + } + } + } ] + } + } +} + +/* FromTime +library TestSnippet version '1' +using Simple version '1.0.0' +context Patient +define timeStr: convert @T11:57 to String +define timeTime: convert @T11:57 to Time +*/ + +module.exports['FromTime'] = { + "library" : { + "localId" : "0", + "annotation" : [ { + "type" : "CqlToElmInfo", + "translatorVersion" : "4.2.0", + "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", + "signatureLevel" : "All" + }, { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "224", + "s" : [ { + "value" : [ "", "library TestSnippet version '1'" ] + } ] + } + } ], + "identifier" : { + "id" : "TestSnippet", + "version" : "1" + }, + "schemaIdentifier" : { + "id" : "urn:hl7-org:elm", + "version" : "r1" + }, + "usings" : { + "def" : [ { + "localId" : "1", + "localIdentifier" : "System", + "uri" : "urn:hl7-org:elm-types:r1", + "annotation" : [ ] + }, { + "localId" : "206", + "localIdentifier" : "Simple", + "uri" : "https://github.com/cqframework/cql-execution/simple", + "version" : "1.0.0", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "206", + "s" : [ { + "value" : [ "", "using " ] + }, { + "s" : [ { + "value" : [ "Simple" ] + } ] + }, { + "value" : [ " version '1.0.0'" ] + } ] + } + } ] + } ] + }, + "contexts" : { + "def" : [ { + "localId" : "211", + "name" : "Patient", + "annotation" : [ ] + } ] + }, + "statements" : { + "def" : [ { + "localId" : "209", + "name" : "Patient", + "context" : "Patient", + "annotation" : [ ], + "expression" : { + "type" : "SingletonFrom", + "localId" : "210", + "annotation" : [ ], + "signature" : [ ], + "operand" : { + "type" : "Retrieve", + "localId" : "208", + "dataType" : "{https://github.com/cqframework/cql-execution/simple}Patient", + "annotation" : [ ], + "include" : [ ], + "codeFilter" : [ ], + "dateFilter" : [ ], + "otherFilter" : [ ] + } + } + }, { + "localId" : "214", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "timeStr", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "214", + "s" : [ { + "value" : [ "", "define ", "timeStr", ": " ] + }, { + "r" : "220", + "s" : [ { + "r" : "216", + "value" : [ "convert ", "@T11:57", " to " ] + }, { + "r" : "215", + "s" : [ { + "value" : [ "String" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToString", + "localId" : "220", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "221", + "name" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Time", + "localId" : "216", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ ], + "hour" : { + "type" : "Literal", + "localId" : "217", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "11", + "annotation" : [ ] + }, + "minute" : { + "type" : "Literal", + "localId" : "218", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "57", + "annotation" : [ ] + } + } + } + }, { + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "name" : "timeTime", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "224", + "s" : [ { + "value" : [ "", "define ", "timeTime", ": " ] + }, { + "r" : "226", + "s" : [ { + "r" : "226", + "value" : [ "convert ", "@T11:57", " to " ] + }, { + "r" : "225", + "s" : [ { + "value" : [ "Time" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Time", + "localId" : "226", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", + "annotation" : [ ], + "signature" : [ ], + "hour" : { + "type" : "Literal", + "localId" : "227", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "11", + "annotation" : [ ] + }, + "minute" : { + "type" : "Literal", + "localId" : "228", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "57", + "annotation" : [ ] + } + } + } ] + } + } +} + +/* FromCode +library TestSnippet version '1' +using Simple version '1.0.0' +codesystem "SNOMED-CT": '2.16.840.1.113883.6.96' +context Patient +define hepB: Code '66071002' from "SNOMED-CT" display 'Type B viral hepatitis' +define codeConcept: convert hepB to Concept +define codeCode: convert hepB to Code +define foo: 'bar' +*/ + +module.exports['FromCode'] = { + "library" : { + "localId" : "0", + "annotation" : [ { + "type" : "CqlToElmInfo", + "translatorVersion" : "4.2.0", + "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", + "signatureLevel" : "All" + }, { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "234", + "s" : [ { + "value" : [ "", "library TestSnippet version '1'" ] + } ] + } + } ], + "identifier" : { + "id" : "TestSnippet", + "version" : "1" + }, + "schemaIdentifier" : { + "id" : "urn:hl7-org:elm", + "version" : "r1" + }, + "usings" : { + "def" : [ { + "localId" : "1", + "localIdentifier" : "System", + "uri" : "urn:hl7-org:elm-types:r1", + "annotation" : [ ] + }, { + "localId" : "206", + "localIdentifier" : "Simple", + "uri" : "https://github.com/cqframework/cql-execution/simple", + "version" : "1.0.0", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "206", + "s" : [ { + "value" : [ "", "using " ] + }, { + "s" : [ { + "value" : [ "Simple" ] + } ] + }, { + "value" : [ " version '1.0.0'" ] + } ] + } + } ] + } ] + }, + "codeSystems" : { + "def" : [ { + "localId" : "208", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}CodeSystem", + "name" : "SNOMED-CT", + "id" : "2.16.840.1.113883.6.96", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "208", + "s" : [ { + "value" : [ "", "codesystem ", "\"SNOMED-CT\"", ": ", "'2.16.840.1.113883.6.96'" ] + } ] + } + } ] + } ] + }, + "contexts" : { + "def" : [ { + "localId" : "213", + "name" : "Patient", + "annotation" : [ ] + } ] + }, + "statements" : { + "def" : [ { + "localId" : "211", + "name" : "Patient", + "context" : "Patient", + "annotation" : [ ], + "expression" : { + "type" : "SingletonFrom", + "localId" : "212", + "annotation" : [ ], + "signature" : [ ], + "operand" : { + "type" : "Retrieve", + "localId" : "210", + "dataType" : "{https://github.com/cqframework/cql-execution/simple}Patient", + "annotation" : [ ], + "include" : [ ], + "codeFilter" : [ ], + "dateFilter" : [ ], + "otherFilter" : [ ] + } + } + }, { + "localId" : "216", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", + "name" : "hepB", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "216", + "s" : [ { + "value" : [ "", "define ", "hepB", ": " ] + }, { + "r" : "217", + "s" : [ { + "value" : [ "Code ", "'66071002'", " from " ] + }, { + "r" : "218", + "s" : [ { + "value" : [ "\"SNOMED-CT\"" ] + } ] + }, { + "value" : [ " display ", "'Type B viral hepatitis'" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Code", + "localId" : "217", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", + "code" : "66071002", + "display" : "Type B viral hepatitis", + "annotation" : [ ], + "system" : { + "localId" : "218", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}CodeSystem", + "name" : "SNOMED-CT", + "annotation" : [ ] + } + } + }, { + "localId" : "221", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Concept", + "name" : "codeConcept", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "221", + "s" : [ { + "value" : [ "", "define ", "codeConcept", ": " ] + }, { + "r" : "225", + "s" : [ { + "value" : [ "convert " ] + }, { + "r" : "223", + "s" : [ { + "value" : [ "hepB" ] + } ] + }, { + "value" : [ " to " ] + }, { + "r" : "222", + "s" : [ { + "value" : [ "Concept" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToConcept", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Concept", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "226", + "name" : "{urn:hl7-org:elm-types:r1}Code", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ExpressionRef", + "localId" : "223", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", + "name" : "hepB", + "annotation" : [ ] + } + } + }, { + "localId" : "229", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", + "name" : "codeCode", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "229", + "s" : [ { + "value" : [ "", "define ", "codeCode", ": " ] + }, { + "r" : "231", + "s" : [ { + "value" : [ "convert " ] + }, { + "r" : "231", + "s" : [ { "value" : [ "hepB" ] } ] }, { - "value" : [ " to " ] + "value" : [ " to " ] + }, { + "r" : "230", + "s" : [ { + "value" : [ "Code" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ExpressionRef", + "localId" : "231", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", + "name" : "hepB", + "annotation" : [ ] + } + }, { + "localId" : "234", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "foo", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "234", + "s" : [ { + "value" : [ "", "define ", "foo", ": " ] + }, { + "r" : "235", + "s" : [ { + "value" : [ "'bar'" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Literal", + "localId" : "235", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "bar", + "annotation" : [ ] + } + } ] + } + } +} + +/* ToDecimal +library TestSnippet version '1' +using Simple version '1.0.0' +context Patient +define NoSign: ToDecimal('0.0') +define PositiveSign: ToDecimal('+1.1') +define NegativeSign: ToDecimal('-1.1') +define TooPrecise: ToDecimal('.444444444') +define TooLargeDec: ToDecimal('444444444444444444444444444444') +define TooSmallDec: ToDecimal('-444444444444444444444444444444') +define NullDecimal: ToDecimal((null as String)) +define WrongFormat: ToDecimal('+.1') +*/ + +module.exports['ToDecimal'] = { + "library" : { + "localId" : "0", + "annotation" : [ { + "type" : "CqlToElmInfo", + "translatorVersion" : "4.2.0", + "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", + "signatureLevel" : "All" + }, { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "285", + "s" : [ { + "value" : [ "", "library TestSnippet version '1'" ] + } ] + } + } ], + "identifier" : { + "id" : "TestSnippet", + "version" : "1" + }, + "schemaIdentifier" : { + "id" : "urn:hl7-org:elm", + "version" : "r1" + }, + "usings" : { + "def" : [ { + "localId" : "1", + "localIdentifier" : "System", + "uri" : "urn:hl7-org:elm-types:r1", + "annotation" : [ ] + }, { + "localId" : "206", + "localIdentifier" : "Simple", + "uri" : "https://github.com/cqframework/cql-execution/simple", + "version" : "1.0.0", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "206", + "s" : [ { + "value" : [ "", "using " ] + }, { + "s" : [ { + "value" : [ "Simple" ] + } ] + }, { + "value" : [ " version '1.0.0'" ] + } ] + } + } ] + } ] + }, + "contexts" : { + "def" : [ { + "localId" : "211", + "name" : "Patient", + "annotation" : [ ] + } ] + }, + "statements" : { + "def" : [ { + "localId" : "209", + "name" : "Patient", + "context" : "Patient", + "annotation" : [ ], + "expression" : { + "type" : "SingletonFrom", + "localId" : "210", + "annotation" : [ ], + "signature" : [ ], + "operand" : { + "type" : "Retrieve", + "localId" : "208", + "dataType" : "{https://github.com/cqframework/cql-execution/simple}Patient", + "annotation" : [ ], + "include" : [ ], + "codeFilter" : [ ], + "dateFilter" : [ ], + "otherFilter" : [ ] + } + } + }, { + "localId" : "214", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "NoSign", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "214", + "s" : [ { + "value" : [ "", "define ", "NoSign", ": " ] + }, { + "r" : "220", + "s" : [ { + "value" : [ "ToDecimal", "(" ] + }, { + "r" : "215", + "s" : [ { + "value" : [ "'0.0'" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDecimal", + "localId" : "220", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "221", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "215", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "0.0", + "annotation" : [ ] + } + } + }, { + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "PositiveSign", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "224", + "s" : [ { + "value" : [ "", "define ", "PositiveSign", ": " ] + }, { + "r" : "230", + "s" : [ { + "value" : [ "ToDecimal", "(" ] + }, { + "r" : "225", + "s" : [ { + "value" : [ "'+1.1'" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDecimal", + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "231", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "+1.1", + "annotation" : [ ] + } + } + }, { + "localId" : "234", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "NegativeSign", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "234", + "s" : [ { + "value" : [ "", "define ", "NegativeSign", ": " ] + }, { + "r" : "240", + "s" : [ { + "value" : [ "ToDecimal", "(" ] + }, { + "r" : "235", + "s" : [ { + "value" : [ "'-1.1'" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDecimal", + "localId" : "240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "241", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "235", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "-1.1", + "annotation" : [ ] + } + } + }, { + "localId" : "244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TooPrecise", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "244", + "s" : [ { + "value" : [ "", "define ", "TooPrecise", ": " ] + }, { + "r" : "250", + "s" : [ { + "value" : [ "ToDecimal", "(" ] }, { - "r" : "222", + "r" : "245", "s" : [ { - "value" : [ "Concept" ] + "value" : [ "'.444444444'" ] } ] + }, { + "value" : [ ")" ] } ] } ] } } ], "expression" : { - "type" : "ToConcept", - "localId" : "225", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Concept", + "type" : "ToDecimal", + "localId" : "250", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "226", - "name" : "{urn:hl7-org:elm-types:r1}Code", + "localId" : "251", + "name" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ] } ], "operand" : { - "type" : "ExpressionRef", - "localId" : "223", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", - "name" : "hepB", + "type" : "Literal", + "localId" : "245", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : ".444444444", "annotation" : [ ] } } }, { - "localId" : "229", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", - "name" : "codeCode", + "localId" : "254", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TooLargeDec", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "229", + "r" : "254", "s" : [ { - "value" : [ "", "define ", "codeCode", ": " ] + "value" : [ "", "define ", "TooLargeDec", ": " ] }, { - "r" : "231", + "r" : "260", "s" : [ { - "value" : [ "convert " ] + "value" : [ "ToDecimal", "(" ] }, { - "r" : "231", + "r" : "255", "s" : [ { - "value" : [ "hepB" ] + "value" : [ "'444444444444444444444444444444'" ] } ] }, { - "value" : [ " to " ] + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDecimal", + "localId" : "260", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "261", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "255", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "444444444444444444444444444444", + "annotation" : [ ] + } + } + }, { + "localId" : "264", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TooSmallDec", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "264", + "s" : [ { + "value" : [ "", "define ", "TooSmallDec", ": " ] + }, { + "r" : "270", + "s" : [ { + "value" : [ "ToDecimal", "(" ] }, { - "r" : "230", + "r" : "265", "s" : [ { - "value" : [ "Code" ] + "value" : [ "'-444444444444444444444444444444'" ] } ] + }, { + "value" : [ ")" ] } ] } ] } } ], "expression" : { - "type" : "ExpressionRef", - "localId" : "231", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Code", - "name" : "hepB", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "270", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "271", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "265", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "-444444444444444444444444444444", + "annotation" : [ ] + } + } + }, { + "localId" : "274", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "NullDecimal", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "274", + "s" : [ { + "value" : [ "", "define ", "NullDecimal", ": " ] + }, { + "r" : "281", + "s" : [ { + "value" : [ "ToDecimal", "(" ] + }, { + "r" : "275", + "s" : [ { + "value" : [ "(" ] + }, { + "r" : "275", + "s" : [ { + "r" : "276", + "value" : [ "null", " as " ] + }, { + "r" : "277", + "s" : [ { + "value" : [ "String" ] + } ] + } ] + }, { + "value" : [ ")" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToDecimal", + "localId" : "281", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "282", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "As", + "localId" : "275", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "strict" : false, + "annotation" : [ ], + "signature" : [ ], + "operand" : { + "type" : "Null", + "localId" : "276", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Any", + "annotation" : [ ] + }, + "asTypeSpecifier" : { + "type" : "NamedTypeSpecifier", + "localId" : "277", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } + } } }, { - "localId" : "234", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "foo", + "localId" : "285", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "WrongFormat", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "234", + "r" : "285", "s" : [ { - "value" : [ "", "define ", "foo", ": " ] + "value" : [ "", "define ", "WrongFormat", ": " ] }, { - "r" : "235", + "r" : "291", "s" : [ { - "value" : [ "'bar'" ] + "value" : [ "ToDecimal", "(" ] + }, { + "r" : "286", + "s" : [ { + "value" : [ "'+.1'" ] + } ] + }, { + "value" : [ ")" ] } ] } ] } } ], "expression" : { - "type" : "Literal", - "localId" : "235", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "bar", - "annotation" : [ ] + "type" : "ToDecimal", + "localId" : "291", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "292", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "286", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "+.1", + "annotation" : [ ] + } } } ] } } } -/* ToDecimal +/* ToInteger library TestSnippet version '1' using Simple version '1.0.0' context Patient -define NoSign: ToDecimal('0.0') -define PositiveSign: ToDecimal('+1.1') -define NegativeSign: ToDecimal('-1.1') -define TooPrecise: ToDecimal('.444444444') -define TooLargeDec: ToDecimal('444444444444444444444444444444') -define TooSmallDec: ToDecimal('-444444444444444444444444444444') -define NullDecimal: ToDecimal((null as String)) -define WrongFormat: ToDecimal('+.1') +define NoSign: ToInteger('12345') +define PositiveSign: ToInteger('+12345') +define NegativeSign: ToInteger('-12345') +define TooLargeInt: ToInteger('2147483648') +define TooSmallInt: ToInteger('-2147483649') +define LongTwenty: ToInteger(20L); +define TooLargeLong: ToInteger(2147483648L); +define TooSmallLong: ToInteger(-2147483649L) +define BooleanTrue: ToInteger(true) +define BooleanFalse: ToInteger(false) */ -module.exports['ToDecimal'] = { +/* +Translation Error(s): +[9:33, 9:33] Syntax error +[10:43, 10:43] Syntax error +*/ +module.exports['ToInteger'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -3261,11 +4384,33 @@ module.exports['ToDecimal'] = { "translatorVersion" : "4.2.0", "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", "signatureLevel" : "All" + }, { + "type" : "CqlToElmError", + "librarySystem" : "text/cql", + "libraryId" : "Anonymous", + "startLine" : 9, + "startChar" : 33, + "endLine" : 9, + "endChar" : 33, + "message" : "Syntax error", + "errorType" : "syntax", + "errorSeverity" : "error" + }, { + "type" : "CqlToElmError", + "librarySystem" : "text/cql", + "libraryId" : "Anonymous", + "startLine" : 10, + "startChar" : 43, + "endLine" : 10, + "endChar" : 43, + "message" : "Syntax error", + "errorType" : "syntax", + "errorSeverity" : "error" }, { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "285", + "r" : "302", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -3339,7 +4484,7 @@ module.exports['ToDecimal'] = { } }, { "localId" : "214", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "NoSign", "context" : "Patient", "accessLevel" : "Public", @@ -3353,11 +4498,11 @@ module.exports['ToDecimal'] = { }, { "r" : "220", "s" : [ { - "value" : [ "ToDecimal", "(" ] + "value" : [ "ToInteger", "(" ] }, { "r" : "215", "s" : [ { - "value" : [ "'0.0'" ] + "value" : [ "'12345'" ] } ] }, { "value" : [ ")" ] @@ -3366,9 +4511,9 @@ module.exports['ToDecimal'] = { } } ], "expression" : { - "type" : "ToDecimal", + "type" : "ToInteger", "localId" : "220", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3381,13 +4526,13 @@ module.exports['ToDecimal'] = { "localId" : "215", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "0.0", + "value" : "12345", "annotation" : [ ] } } }, { "localId" : "224", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "PositiveSign", "context" : "Patient", "accessLevel" : "Public", @@ -3401,11 +4546,11 @@ module.exports['ToDecimal'] = { }, { "r" : "230", "s" : [ { - "value" : [ "ToDecimal", "(" ] + "value" : [ "ToInteger", "(" ] }, { "r" : "225", "s" : [ { - "value" : [ "'+1.1'" ] + "value" : [ "'+12345'" ] } ] }, { "value" : [ ")" ] @@ -3414,9 +4559,9 @@ module.exports['ToDecimal'] = { } } ], "expression" : { - "type" : "ToDecimal", + "type" : "ToInteger", "localId" : "230", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3429,13 +4574,13 @@ module.exports['ToDecimal'] = { "localId" : "225", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "+1.1", + "value" : "+12345", "annotation" : [ ] } } }, { "localId" : "234", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "NegativeSign", "context" : "Patient", "accessLevel" : "Public", @@ -3449,11 +4594,11 @@ module.exports['ToDecimal'] = { }, { "r" : "240", "s" : [ { - "value" : [ "ToDecimal", "(" ] + "value" : [ "ToInteger", "(" ] }, { "r" : "235", "s" : [ { - "value" : [ "'-1.1'" ] + "value" : [ "'-12345'" ] } ] }, { "value" : [ ")" ] @@ -3462,9 +4607,9 @@ module.exports['ToDecimal'] = { } } ], "expression" : { - "type" : "ToDecimal", + "type" : "ToInteger", "localId" : "240", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3477,14 +4622,14 @@ module.exports['ToDecimal'] = { "localId" : "235", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "-1.1", + "value" : "-12345", "annotation" : [ ] } } }, { "localId" : "244", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "TooPrecise", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "TooLargeInt", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -3493,15 +4638,15 @@ module.exports['ToDecimal'] = { "s" : { "r" : "244", "s" : [ { - "value" : [ "", "define ", "TooPrecise", ": " ] + "value" : [ "", "define ", "TooLargeInt", ": " ] }, { "r" : "250", "s" : [ { - "value" : [ "ToDecimal", "(" ] + "value" : [ "ToInteger", "(" ] }, { "r" : "245", "s" : [ { - "value" : [ "'.444444444'" ] + "value" : [ "'2147483648'" ] } ] }, { "value" : [ ")" ] @@ -3510,9 +4655,9 @@ module.exports['ToDecimal'] = { } } ], "expression" : { - "type" : "ToDecimal", + "type" : "ToInteger", "localId" : "250", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3525,14 +4670,14 @@ module.exports['ToDecimal'] = { "localId" : "245", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : ".444444444", + "value" : "2147483648", "annotation" : [ ] } } }, { "localId" : "254", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "TooLargeDec", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "TooSmallInt", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -3541,15 +4686,15 @@ module.exports['ToDecimal'] = { "s" : { "r" : "254", "s" : [ { - "value" : [ "", "define ", "TooLargeDec", ": " ] + "value" : [ "", "define ", "TooSmallInt", ": " ] }, { "r" : "260", "s" : [ { - "value" : [ "ToDecimal", "(" ] + "value" : [ "ToInteger", "(" ] }, { "r" : "255", "s" : [ { - "value" : [ "'444444444444444444444444444444'" ] + "value" : [ "'-2147483649'" ] } ] }, { "value" : [ ")" ] @@ -3558,9 +4703,9 @@ module.exports['ToDecimal'] = { } } ], "expression" : { - "type" : "ToDecimal", + "type" : "ToInteger", "localId" : "260", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3573,14 +4718,14 @@ module.exports['ToDecimal'] = { "localId" : "255", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "444444444444444444444444444444", + "value" : "-2147483649", "annotation" : [ ] } } }, { "localId" : "264", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "TooSmallDec", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "LongTwenty", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -3589,76 +4734,100 @@ module.exports['ToDecimal'] = { "s" : { "r" : "264", "s" : [ { - "value" : [ "", "define ", "TooSmallDec", ": " ] + "value" : [ "", "define ", "LongTwenty", ": " ] }, { - "r" : "270", + "r" : "269", "s" : [ { - "value" : [ "ToDecimal", "(" ] - }, { "r" : "265", - "s" : [ { - "value" : [ "'-444444444444444444444444444444'" ] - } ] - }, { - "value" : [ ")" ] + "value" : [ "ToInteger", "(", "20L", ")" ] } ] } ] } } ], "expression" : { - "type" : "ToDecimal", - "localId" : "270", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "ToInteger", + "localId" : "269", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "271", - "name" : "{urn:hl7-org:elm-types:r1}String", + "localId" : "270", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", "localId" : "265", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "-444444444444444444444444444444", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "20", "annotation" : [ ] } } }, { - "localId" : "274", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "NullDecimal", + "localId" : "273", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "TooLargeLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "274", + "r" : "273", "s" : [ { - "value" : [ "", "define ", "NullDecimal", ": " ] + "value" : [ "", "define ", "TooLargeLong", ": " ] }, { - "r" : "281", + "r" : "278", "s" : [ { - "value" : [ "ToDecimal", "(" ] + "r" : "274", + "value" : [ "ToInteger", "(", "2147483648L", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToInteger", + "localId" : "278", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "279", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "274", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2147483648", + "annotation" : [ ] + } + } + }, { + "localId" : "282", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "TooSmallLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "282", + "s" : [ { + "value" : [ "", "define ", "TooSmallLong", ": " ] + }, { + "r" : "289", + "s" : [ { + "value" : [ "ToInteger", "(" ] }, { - "r" : "275", + "r" : "283", "s" : [ { - "value" : [ "(" ] - }, { - "r" : "275", - "s" : [ { - "r" : "276", - "value" : [ "null", " as " ] - }, { - "r" : "277", - "s" : [ { - "value" : [ "String" ] - } ] - } ] - }, { - "value" : [ ")" ] + "r" : "284", + "value" : [ "-", "2147483649L" ] } ] }, { "value" : [ ")" ] @@ -3667,83 +4836,118 @@ module.exports['ToDecimal'] = { } } ], "expression" : { - "type" : "ToDecimal", - "localId" : "281", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "ToInteger", + "localId" : "289", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "290", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Negate", + "localId" : "283", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "285", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "284", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2147483649", + "annotation" : [ ] + } + } + } + }, { + "localId" : "293", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "BooleanTrue", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "293", + "s" : [ { + "value" : [ "", "define ", "BooleanTrue", ": " ] + }, { + "r" : "298", + "s" : [ { + "r" : "294", + "value" : [ "ToInteger", "(", "true", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToInteger", + "localId" : "298", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "282", - "name" : "{urn:hl7-org:elm-types:r1}String", + "localId" : "299", + "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { - "type" : "As", - "localId" : "275", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "strict" : false, - "annotation" : [ ], - "signature" : [ ], - "operand" : { - "type" : "Null", - "localId" : "276", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Any", - "annotation" : [ ] - }, - "asTypeSpecifier" : { - "type" : "NamedTypeSpecifier", - "localId" : "277", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "name" : "{urn:hl7-org:elm-types:r1}String", - "annotation" : [ ] - } + "type" : "Literal", + "localId" : "294", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", + "value" : "true", + "annotation" : [ ] } } }, { - "localId" : "285", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "WrongFormat", + "localId" : "302", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "BooleanFalse", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "285", + "r" : "302", "s" : [ { - "value" : [ "", "define ", "WrongFormat", ": " ] + "value" : [ "", "define ", "BooleanFalse", ": " ] }, { - "r" : "291", + "r" : "307", "s" : [ { - "value" : [ "ToDecimal", "(" ] - }, { - "r" : "286", - "s" : [ { - "value" : [ "'+.1'" ] - } ] - }, { - "value" : [ ")" ] + "r" : "303", + "value" : [ "ToInteger", "(", "false", ")" ] } ] } ] } } ], "expression" : { - "type" : "ToDecimal", - "localId" : "291", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "type" : "ToInteger", + "localId" : "307", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "292", - "name" : "{urn:hl7-org:elm-types:r1}String", + "localId" : "308", + "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "286", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "+.1", + "localId" : "303", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", + "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", + "value" : "false", "annotation" : [ ] } } @@ -3752,20 +4956,23 @@ module.exports['ToDecimal'] = { } } -/* ToInteger +/* ToLong library TestSnippet version '1' using Simple version '1.0.0' context Patient -define NoSign: ToInteger('12345') -define PositiveSign: ToInteger('+12345') -define NegativeSign: ToInteger('-12345') -define TooLargeInt: ToInteger('2147483648') -define TooSmallInt: ToInteger('-2147483649') -define BooleanTrue: ToInteger(true) -define BooleanFalse: ToInteger(false) +define NoSign: ToLong('12345') +define PositiveSign: ToLong('+12345') +define NegativeSign: ToLong('-12345') +define TooLargeLong: ToLong('9223372036854775808') +define DefinitelyTooLargeLong: ToLong('9223372036854780000') +define TooSmallLong: ToLong('-9223372036854775809') +define DefinitelyTooSmallLong: ToLong('-92233720368547800000') +define Int: ToLong(12345) +define BooleanTrue: ToLong(true) +define BooleanFalse: ToLong(false) */ -module.exports['ToInteger'] = { +module.exports['ToLong'] = { "library" : { "localId" : "0", "annotation" : [ { @@ -3777,7 +4984,7 @@ module.exports['ToInteger'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "273", + "r" : "302", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -3851,7 +5058,7 @@ module.exports['ToInteger'] = { } }, { "localId" : "214", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "NoSign", "context" : "Patient", "accessLevel" : "Public", @@ -3865,7 +5072,7 @@ module.exports['ToInteger'] = { }, { "r" : "220", "s" : [ { - "value" : [ "ToInteger", "(" ] + "value" : [ "ToLong", "(" ] }, { "r" : "215", "s" : [ { @@ -3878,9 +5085,9 @@ module.exports['ToInteger'] = { } } ], "expression" : { - "type" : "ToInteger", + "type" : "ToLong", "localId" : "220", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3899,7 +5106,7 @@ module.exports['ToInteger'] = { } }, { "localId" : "224", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "PositiveSign", "context" : "Patient", "accessLevel" : "Public", @@ -3913,7 +5120,7 @@ module.exports['ToInteger'] = { }, { "r" : "230", "s" : [ { - "value" : [ "ToInteger", "(" ] + "value" : [ "ToLong", "(" ] }, { "r" : "225", "s" : [ { @@ -3926,9 +5133,9 @@ module.exports['ToInteger'] = { } } ], "expression" : { - "type" : "ToInteger", + "type" : "ToLong", "localId" : "230", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3947,7 +5154,7 @@ module.exports['ToInteger'] = { } }, { "localId" : "234", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "NegativeSign", "context" : "Patient", "accessLevel" : "Public", @@ -3961,7 +5168,7 @@ module.exports['ToInteger'] = { }, { "r" : "240", "s" : [ { - "value" : [ "ToInteger", "(" ] + "value" : [ "ToLong", "(" ] }, { "r" : "235", "s" : [ { @@ -3974,9 +5181,9 @@ module.exports['ToInteger'] = { } } ], "expression" : { - "type" : "ToInteger", + "type" : "ToLong", "localId" : "240", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -3995,8 +5202,8 @@ module.exports['ToInteger'] = { } }, { "localId" : "244", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "TooLargeInt", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "TooLargeLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -4005,15 +5212,15 @@ module.exports['ToInteger'] = { "s" : { "r" : "244", "s" : [ { - "value" : [ "", "define ", "TooLargeInt", ": " ] + "value" : [ "", "define ", "TooLargeLong", ": " ] }, { "r" : "250", "s" : [ { - "value" : [ "ToInteger", "(" ] + "value" : [ "ToLong", "(" ] }, { "r" : "245", "s" : [ { - "value" : [ "'2147483648'" ] + "value" : [ "'9223372036854775808'" ] } ] }, { "value" : [ ")" ] @@ -4022,9 +5229,9 @@ module.exports['ToInteger'] = { } } ], "expression" : { - "type" : "ToInteger", + "type" : "ToLong", "localId" : "250", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -4037,14 +5244,14 @@ module.exports['ToInteger'] = { "localId" : "245", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "2147483648", + "value" : "9223372036854775808", "annotation" : [ ] } } }, { "localId" : "254", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "TooSmallInt", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "DefinitelyTooLargeLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -4053,15 +5260,15 @@ module.exports['ToInteger'] = { "s" : { "r" : "254", "s" : [ { - "value" : [ "", "define ", "TooSmallInt", ": " ] + "value" : [ "", "define ", "DefinitelyTooLargeLong", ": " ] }, { "r" : "260", "s" : [ { - "value" : [ "ToInteger", "(" ] + "value" : [ "ToLong", "(" ] }, { "r" : "255", "s" : [ { - "value" : [ "'-2147483649'" ] + "value" : [ "'9223372036854780000'" ] } ] }, { "value" : [ ")" ] @@ -4070,9 +5277,9 @@ module.exports['ToInteger'] = { } } ], "expression" : { - "type" : "ToInteger", + "type" : "ToLong", "localId" : "260", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", @@ -4085,14 +5292,14 @@ module.exports['ToInteger'] = { "localId" : "255", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "-2147483649", + "value" : "9223372036854780000", "annotation" : [ ] } } }, { "localId" : "264", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "BooleanTrue", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "TooSmallLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -4101,30 +5308,168 @@ module.exports['ToInteger'] = { "s" : { "r" : "264", "s" : [ { - "value" : [ "", "define ", "BooleanTrue", ": " ] + "value" : [ "", "define ", "TooSmallLong", ": " ] }, { - "r" : "269", + "r" : "270", "s" : [ { + "value" : [ "ToLong", "(" ] + }, { "r" : "265", - "value" : [ "ToInteger", "(", "true", ")" ] + "s" : [ { + "value" : [ "'-9223372036854775809'" ] + } ] + }, { + "value" : [ ")" ] } ] } ] } } ], "expression" : { - "type" : "ToInteger", - "localId" : "269", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "type" : "ToLong", + "localId" : "270", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "270", - "name" : "{urn:hl7-org:elm-types:r1}Boolean", + "localId" : "271", + "name" : "{urn:hl7-org:elm-types:r1}String", "annotation" : [ ] } ], "operand" : { "type" : "Literal", "localId" : "265", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "-9223372036854775809", + "annotation" : [ ] + } + } + }, { + "localId" : "274", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "DefinitelyTooSmallLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "274", + "s" : [ { + "value" : [ "", "define ", "DefinitelyTooSmallLong", ": " ] + }, { + "r" : "280", + "s" : [ { + "value" : [ "ToLong", "(" ] + }, { + "r" : "275", + "s" : [ { + "value" : [ "'-92233720368547800000'" ] + } ] + }, { + "value" : [ ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToLong", + "localId" : "280", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "281", + "name" : "{urn:hl7-org:elm-types:r1}String", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "275", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", + "valueType" : "{urn:hl7-org:elm-types:r1}String", + "value" : "-92233720368547800000", + "annotation" : [ ] + } + } + }, { + "localId" : "284", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "Int", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "284", + "s" : [ { + "value" : [ "", "define ", "Int", ": " ] + }, { + "r" : "289", + "s" : [ { + "r" : "285", + "value" : [ "ToLong", "(", "12345", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToLong", + "localId" : "289", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "290", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "285", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "12345", + "annotation" : [ ] + } + } + }, { + "localId" : "293", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "BooleanTrue", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "293", + "s" : [ { + "value" : [ "", "define ", "BooleanTrue", ": " ] + }, { + "r" : "298", + "s" : [ { + "r" : "294", + "value" : [ "ToLong", "(", "true", ")" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "ToLong", + "localId" : "298", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "299", + "name" : "{urn:hl7-org:elm-types:r1}Boolean", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "294", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", "value" : "true", @@ -4132,8 +5477,8 @@ module.exports['ToInteger'] = { } } }, { - "localId" : "273", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "localId" : "302", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "BooleanFalse", "context" : "Patient", "accessLevel" : "Public", @@ -4141,32 +5486,32 @@ module.exports['ToInteger'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "273", + "r" : "302", "s" : [ { "value" : [ "", "define ", "BooleanFalse", ": " ] }, { - "r" : "278", + "r" : "307", "s" : [ { - "r" : "274", - "value" : [ "ToInteger", "(", "false", ")" ] + "r" : "303", + "value" : [ "ToLong", "(", "false", ")" ] } ] } ] } } ], "expression" : { - "type" : "ToInteger", - "localId" : "278", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "type" : "ToLong", + "localId" : "307", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "279", + "localId" : "308", "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "274", + "localId" : "303", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", "value" : "false", diff --git a/test/elm/literal/data.cql b/test/elm/literal/data.cql index 5dde4e750..d706f3cb4 100644 --- a/test/elm/literal/data.cql +++ b/test/elm/literal/data.cql @@ -2,6 +2,7 @@ define BoolTrue: true define BoolFalse: false define IntOne: 1 +define LongOne: 1L define DecimalTenth: 0.1 define StringTrue: 'true' define DateTimeX: @2012-02-15T12:10:59.456Z diff --git a/test/elm/literal/data.js b/test/elm/literal/data.js index c17db7b35..521e89bf8 100644 --- a/test/elm/literal/data.js +++ b/test/elm/literal/data.js @@ -15,6 +15,7 @@ context Patient define BoolTrue: true define BoolFalse: false define IntOne: 1 +define LongOne: 1L define DecimalTenth: 0.1 define StringTrue: 'true' define DateTimeX: @2012-02-15T12:10:59.456Z @@ -33,7 +34,7 @@ module.exports['Literal'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "247", + "r" : "251", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -182,8 +183,8 @@ module.exports['Literal'] = { } }, { "localId" : "226", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "DecimalTenth", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "LongOne", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -193,20 +194,45 @@ module.exports['Literal'] = { "r" : "226", "s" : [ { "r" : "227", - "value" : [ "", "define ", "DecimalTenth", ": ", "0.1" ] + "value" : [ "", "define ", "LongOne", ": ", "1L" ] } ] } } ], "expression" : { "type" : "Literal", "localId" : "227", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + } + }, { + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "DecimalTenth", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "230", + "s" : [ { + "r" : "231", + "value" : [ "", "define ", "DecimalTenth", ": ", "0.1" ] + } ] + } + } ], + "expression" : { + "type" : "Literal", + "localId" : "231", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.1", "annotation" : [ ] } }, { - "localId" : "230", + "localId" : "234", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "name" : "StringTrue", "context" : "Patient", @@ -215,11 +241,11 @@ module.exports['Literal'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "230", + "r" : "234", "s" : [ { "value" : [ "", "define ", "StringTrue", ": " ] }, { - "r" : "231", + "r" : "235", "s" : [ { "value" : [ "'true'" ] } ] @@ -228,14 +254,14 @@ module.exports['Literal'] = { } ], "expression" : { "type" : "Literal", - "localId" : "231", + "localId" : "235", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", "value" : "true", "annotation" : [ ] } }, { - "localId" : "235", + "localId" : "239", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeX", "context" : "Patient", @@ -244,78 +270,78 @@ module.exports['Literal'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "235", + "r" : "239", "s" : [ { - "r" : "236", + "r" : "240", "value" : [ "", "define ", "DateTimeX", ": ", "@2012-02-15T12:10:59.456Z" ] } ] } } ], "expression" : { "type" : "DateTime", - "localId" : "236", + "localId" : "240", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ ], "year" : { "type" : "Literal", - "localId" : "237", + "localId" : "241", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2012", "annotation" : [ ] }, "month" : { "type" : "Literal", - "localId" : "238", + "localId" : "242", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2", "annotation" : [ ] }, "day" : { "type" : "Literal", - "localId" : "239", + "localId" : "243", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "15", "annotation" : [ ] }, "hour" : { "type" : "Literal", - "localId" : "240", + "localId" : "244", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", "annotation" : [ ] }, "minute" : { "type" : "Literal", - "localId" : "241", + "localId" : "245", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, "second" : { "type" : "Literal", - "localId" : "242", + "localId" : "246", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "59", "annotation" : [ ] }, "millisecond" : { "type" : "Literal", - "localId" : "243", + "localId" : "247", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "456", "annotation" : [ ] }, "timezoneOffset" : { "type" : "Literal", - "localId" : "244", + "localId" : "248", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.0", "annotation" : [ ] } } }, { - "localId" : "247", + "localId" : "251", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeX", "context" : "Patient", @@ -324,43 +350,43 @@ module.exports['Literal'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "247", + "r" : "251", "s" : [ { - "r" : "248", + "r" : "252", "value" : [ "", "define ", "TimeX", ": ", "@T12:10:59.456" ] } ] } } ], "expression" : { "type" : "Time", - "localId" : "248", + "localId" : "252", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ ], "hour" : { "type" : "Literal", - "localId" : "249", + "localId" : "253", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", "annotation" : [ ] }, "minute" : { "type" : "Literal", - "localId" : "250", + "localId" : "254", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, "second" : { "type" : "Literal", - "localId" : "251", + "localId" : "255", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "59", "annotation" : [ ] }, "millisecond" : { "type" : "Literal", - "localId" : "252", + "localId" : "256", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "456", "annotation" : [ ] diff --git a/test/elm/literal/literal-test.ts b/test/elm/literal/literal-test.ts index 2ce16fcc3..ccd87ab42 100644 --- a/test/elm/literal/literal-test.ts +++ b/test/elm/literal/literal-test.ts @@ -31,6 +31,14 @@ describe('Literal', () => { (await this.intOne.exec(this.ctx)).should.equal(1); }); + it('should convert 1L to 1', function () { + this.longOne.value.should.equal(1); + }); + + it('should execute 1L as 1', async function () { + (await this.longOne.exec(this.ctx)).should.equal(1); + }); + it('should convert .1 to decimal .1', function () { this.decimalTenth.value.should.equal(0.1); }); diff --git a/test/spec-tests/cql/CqlAggregateFunctionsTest.cql b/test/spec-tests/cql/CqlAggregateFunctionsTest.cql index 1f2057d07..1cb789ef4 100644 --- a/test/spec-tests/cql/CqlAggregateFunctionsTest.cql +++ b/test/spec-tests/cql/CqlAggregateFunctionsTest.cql @@ -89,11 +89,9 @@ define "Avg": Tuple{ define "Product": Tuple{ "ProductLong": Tuple{ - skipped: 'Long not implemented' - /* expression: Product({5L, 4L, 5L}), output: 100L - */ } + } } define "Count": Tuple{ @@ -226,11 +224,9 @@ define "Sum": Tuple{ output: 20.0 }, "SumTestLong": Tuple{ - skipped: 'Long not implemented' - /* expression: Sum({ 6L, 2L, 3L, 4L, 5L }), output: 20L - */ }, + }, "SumTestQuantity": Tuple{ expression: Sum({1 'ml',2 'ml',3 'ml',4 'ml',5 'ml'}), output: 15 'ml' diff --git a/test/spec-tests/cql/CqlAggregateFunctionsTest.json b/test/spec-tests/cql/CqlAggregateFunctionsTest.json index e35d4724a..9f6bc64d9 100644 --- a/test/spec-tests/cql/CqlAggregateFunctionsTest.json +++ b/test/spec-tests/cql/CqlAggregateFunctionsTest.json @@ -1031,11 +1031,43 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Product", + "annotation": [], + "signature": [], + "source": { + "type": "List", + "annotation": [], + "element": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "5", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "4", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "5", + "annotation": [] + } + ] + } + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "100", "annotation": [] } } @@ -3452,11 +3484,55 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Sum", + "annotation": [], + "signature": [], + "source": { + "type": "List", + "annotation": [], + "element": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "6", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "3", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "4", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "5", + "annotation": [] + } + ] + } + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "20", "annotation": [] } } diff --git a/test/spec-tests/cql/CqlArithmeticFunctionsTest.cql b/test/spec-tests/cql/CqlArithmeticFunctionsTest.cql index 926ca05ab..0fc0bca68 100644 --- a/test/spec-tests/cql/CqlArithmeticFunctionsTest.cql +++ b/test/spec-tests/cql/CqlArithmeticFunctionsTest.cql @@ -28,11 +28,9 @@ define "Abs": Tuple{ output: 1.0'cm' }, "AbsLong": Tuple{ - skipped: 'Long not implemented' - /* expression: Abs(-1L), output: 1L - */ } + } } define "Add": Tuple{ @@ -45,11 +43,9 @@ define "Add": Tuple{ output: 2 }, "Add1L2L": Tuple{ - skipped: 'Long not implemented' - /* expression: 1L + 2L, output: 3L - */ }, + }, "Add1D1D": Tuple{ expression: 1.0 + 1.0, output: 2.0 @@ -63,11 +59,9 @@ define "Add": Tuple{ output: 3.0 }, "Add1L1L": Tuple{ - skipped: 'Long not implemented' - /* expression: 1L + 1L, output: 2L - */ } + } } define "Ceiling": Tuple{ @@ -356,11 +350,9 @@ define "MinValue": Tuple{ output: -2147483648 }, "LongMinValue": Tuple{ - skipped: 'Long not implemented' - /* expression: minimum Long, output: -9223372036854775808L - */ }, + }, "DecimalMinValue": Tuple{ expression: minimum Decimal, output: -99999999999999999999.99999999 @@ -389,11 +381,9 @@ define "MaxValue": Tuple{ output: 2147483647 }, "LongMaxValue": Tuple{ - skipped: 'Long not implemented' - /* expression: maximum Long, output: 9223372036854775807L - */ }, + }, "DecimalMaxValue": Tuple{ expression: maximum Decimal, output: 99999999999999999999.99999999 @@ -430,11 +420,9 @@ define "Modulo": Tuple{ output: 0 }, "Modulo4LBy2L": Tuple{ - skipped: 'Long not implemented' - /* expression: 4L mod 2L, output: 0L - */ }, + }, "Modulo4DBy2D": Tuple{ expression: 4.0 mod 2.0, output: 0.0 @@ -483,21 +471,17 @@ define "Multiply": Tuple{ output: 1 }, "Multiply2LBy3L": Tuple{ - skipped: 'Long not implemented' - /* expression: 2L * 3L, output: 6L - */ }, + }, "Multiply1DBy2D": Tuple{ expression: 1.0 * 2.0, output: 2.0 }, "Multiply1By1L": Tuple{ - skipped: 'Long not implemented' - /* expression: 1 * 1L, output: 1L - */ }, + }, "Multiply1IBy2D": Tuple{ expression: 1 * 2.0, output: 2.0 @@ -538,11 +522,9 @@ define "Negate": Tuple{ output: 1 }, "NegateNeg1L": Tuple{ - skipped: 'Long not implemented' - /* expression: -(-1L), output: 1L - */ }, + }, "Negate0D": Tuple{ expression: -(0.0), output: 0.0 @@ -604,11 +586,9 @@ define "Predecessor": Tuple{ output: 0 }, "PredecessorOf1L": Tuple{ - skipped: 'Long not implemented' - /* expression: predecessor of 1L, output: 0L - */ }, + }, "PredecessorOf1D": Tuple{ skipped: 'Wrong answer (doesn\'t recognize 1.0 as decimal)' /* @@ -665,11 +645,9 @@ define "Power": Tuple{ output: 0.25 }, "Power2LTo2L": Tuple{ - skipped: 'Long not implemented' - /* expression: Power(2L, 2L), output: 4L - */ }, + }, "Power2DTo2D": Tuple{ expression: Power(2.0, 2.0), output: 4.0 @@ -695,11 +673,9 @@ define "Power": Tuple{ output: 16 }, "Power2LTo3L": Tuple{ - skipped: 'Long not implemented' - /* expression: 2L^3L, output: 8L - */ }, + }, "Power2DTo4D": Tuple{ expression: 2.0^4.0, output: 16.0 @@ -767,11 +743,9 @@ define "Subtract": Tuple{ output: 0 }, "Subtract1LAnd1L": Tuple{ - skipped: 'Long not implemented' - /* expression: 1L - 1L, output: 0L - */ }, + }, "Subtract1DAnd2D": Tuple{ expression: 1.0 - 2.0, output: -1.0 @@ -800,11 +774,9 @@ define "Successor": Tuple{ output: 2 }, "SuccessorOf1L": Tuple{ - skipped: 'Long not implemented' - /* expression: successor of 1L, output: 2L - */ }, + }, "SuccessorOf1D": Tuple{ skipped: 'Wrong answer (doesn\'t recognize 1.0 as decimal)' /* @@ -902,11 +874,9 @@ define "Truncated Divide": Tuple{ output: 3 }, "TruncatedDivide10LBy3L": Tuple{ - skipped: 'Long not implemented' - /* expression: 10L div 3L, output: 3L - */ }, + }, "TruncatedDivide10LBy0L": Tuple{ expression: 10L div 0L, output: null diff --git a/test/spec-tests/cql/CqlArithmeticFunctionsTest.json b/test/spec-tests/cql/CqlArithmeticFunctionsTest.json index 5a898b491..13576eb27 100644 --- a/test/spec-tests/cql/CqlArithmeticFunctionsTest.json +++ b/test/spec-tests/cql/CqlArithmeticFunctionsTest.json @@ -291,11 +291,30 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Abs", + "annotation": [], + "signature": [], + "operand": { + "type": "Negate", + "annotation": [], + "signature": [], + "operand": { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + } + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", "annotation": [] } } @@ -403,11 +422,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Add", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "3", "annotation": [] } } @@ -546,11 +587,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Add", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", "annotation": [] } } @@ -3075,13 +3138,26 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", "value": { - "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "type": "MinValue", + "valueType": "{urn:hl7-org:elm-types:r1}Long", "annotation": [] } + }, + { + "name": "output", + "value": { + "type": "Negate", + "annotation": [], + "signature": [], + "operand": { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "9223372036854775808", + "annotation": [] + } + } } ] } @@ -3353,11 +3429,19 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "MaxValue", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "annotation": [] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "9223372036854775807", "annotation": [] } } @@ -3720,11 +3804,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Modulo", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "4", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "0", "annotation": [] } } @@ -4116,11 +4222,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Multiply", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "3", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "6", "annotation": [] } } @@ -4174,11 +4302,38 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Multiply", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "ToLong", + "annotation": [], + "signature": [], + "operand": { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Integer", + "value": "1", + "annotation": [] + } + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", "annotation": [] } } @@ -4545,11 +4700,30 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Negate", + "annotation": [], + "signature": [], + "operand": { + "type": "Negate", + "annotation": [], + "signature": [], + "operand": { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + } + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", "annotation": [] } } @@ -5101,11 +5275,25 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Predecessor", + "annotation": [], + "signature": [], + "operand": { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "0", "annotation": [] } } @@ -5697,11 +5885,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Power", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "4", "annotation": [] } } @@ -5975,11 +6185,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Power", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "3", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "8", "annotation": [] } } @@ -6622,11 +6854,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Subtract", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "0", "annotation": [] } } @@ -6890,11 +7144,25 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "Successor", + "annotation": [], + "signature": [], + "operand": { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "1", + "annotation": [] + } + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "2", "annotation": [] } } @@ -7874,11 +8142,33 @@ "annotation": [], "element": [ { - "name": "skipped", + "name": "expression", + "value": { + "type": "TruncatedDivide", + "annotation": [], + "signature": [], + "operand": [ + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "10", + "annotation": [] + }, + { + "type": "Literal", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "3", + "annotation": [] + } + ] + } + }, + { + "name": "output", "value": { "type": "Literal", - "valueType": "{urn:hl7-org:elm-types:r1}String", - "value": "Long not implemented", + "valueType": "{urn:hl7-org:elm-types:r1}Long", + "value": "3", "annotation": [] } } diff --git a/test/spec-tests/skip-list.txt b/test/spec-tests/skip-list.txt index 74120b094..bf44f90b9 100644 --- a/test/spec-tests/skip-list.txt +++ b/test/spec-tests/skip-list.txt @@ -69,23 +69,23 @@ CqlListOperatorsTest.ProperIn ProperIn not implemented CqlListOperatorsTest.ProperlyIncludedIn.ProperlyIncludedInNulRight ProperIn not implemented # Unimplemented (New in CQL 1.5) -CqlAggregateFunctionsTest.Product.ProductLong Long not implemented -CqlAggregateFunctionsTest.Sum.SumTestLong Long not implemented -CqlArithmeticFunctionsTest.Abs.AbsLong Long not implemented -CqlArithmeticFunctionsTest.Add.Add1L1L Long not implemented -CqlArithmeticFunctionsTest.Add.Add1L2L Long not implemented -CqlArithmeticFunctionsTest.MinValue.LongMinValue Long not implemented -CqlArithmeticFunctionsTest.MaxValue.LongMaxValue Long not implemented -CqlArithmeticFunctionsTest.Modulo.Modulo4LBy2L Long not implemented -CqlArithmeticFunctionsTest.Multiply.Multiply1By1L Long not implemented -CqlArithmeticFunctionsTest.Multiply.Multiply2LBy3L Long not implemented -CqlArithmeticFunctionsTest.Negate.NegateNeg1L Long not implemented -CqlArithmeticFunctionsTest.Predecessor.PredecessorOf1L Long not implemented -CqlArithmeticFunctionsTest.Power.Power2LTo2L Long not implemented -CqlArithmeticFunctionsTest.Power.Power2LTo3L Long not implemented -CqlArithmeticFunctionsTest.Subtract.Subtract1LAnd1L Long not implemented -CqlArithmeticFunctionsTest.Successor.SuccessorOf1L Long not implemented -"CqlArithmeticFunctionsTest.Truncated Divide.TruncatedDivide10LBy3L" Long not implemented +# CqlAggregateFunctionsTest.Product.ProductLong Long not implemented +# CqlAggregateFunctionsTest.Sum.SumTestLong Long not implemented +# CqlArithmeticFunctionsTest.Abs.AbsLong Long not implemented +# CqlArithmeticFunctionsTest.Add.Add1L1L Long not implemented +# CqlArithmeticFunctionsTest.Add.Add1L2L Long not implemented +# CqlArithmeticFunctionsTest.MinValue.LongMinValue Long not implemented +# CqlArithmeticFunctionsTest.MaxValue.LongMaxValue Long not implemented +# CqlArithmeticFunctionsTest.Modulo.Modulo4LBy2L Long not implemented +# CqlArithmeticFunctionsTest.Multiply.Multiply1By1L Long not implemented +# CqlArithmeticFunctionsTest.Multiply.Multiply2LBy3L Long not implemented +# CqlArithmeticFunctionsTest.Negate.NegateNeg1L Long not implemented +# CqlArithmeticFunctionsTest.Predecessor.PredecessorOf1L Long not implemented +# CqlArithmeticFunctionsTest.Power.Power2LTo2L Long not implemented +# CqlArithmeticFunctionsTest.Power.Power2LTo3L Long not implemented +# CqlArithmeticFunctionsTest.Subtract.Subtract1LAnd1L Long not implemented +# CqlArithmeticFunctionsTest.Successor.SuccessorOf1L Long not implemented +# "CqlArithmeticFunctionsTest.Truncated Divide.TruncatedDivide10LBy3L" Long not implemented CqlArithmeticFunctionsTest.Modulo.ModuloQuantity Modulo not implemented for Quantity CqlArithmeticFunctionsTest.Modulo.Modulo10By3Quantity Modulo not implemented for Quantity "CqlArithmeticFunctionsTest.Truncated Divide.TruncatedDivide10d1ByNeg3D1Quantity" Truncated divide not implemented for Quantity From d67ec1fb9c6bd10ffddc0c7141344722a5006583 Mon Sep 17 00:00:00 2001 From: Chris Moesel Date: Thu, 23 Apr 2026 09:14:51 -0400 Subject: [PATCH 2/2] Support for Long as JS BigInt Update support for Long to use BigInt so we can distinguish between decimal/integer (JS Number) and long (JS BigInt). --- README.md | 2 - examples/browser/cql4browsers.js | 422 +- src/datatypes/bigint.ts | 17 + src/datatypes/datatypes.ts | 1 + src/elm/arithmetic.ts | 23 +- src/elm/literal.ts | 2 +- src/elm/type.ts | 20 +- src/runtime/context.ts | 5 +- src/util/math.ts | 43 +- test-server/src/convert/convert.ts | 2 + test-server/tests/convert/convert.test.ts | 2 +- test/datatypes/bigint-test.ts | 8 + test/elm/arithmetic/arithmetic-test.ts | 148 +- test/elm/arithmetic/data.cql | 26 +- test/elm/arithmetic/data.js | 4265 +++++++++++++-------- test/elm/convert/convert-test.ts | 40 +- test/elm/convert/data.cql | 10 +- test/elm/convert/data.js | 191 +- test/elm/literal/literal-test.ts | 4 +- tsconfig.json | 4 +- 20 files changed, 3262 insertions(+), 1973 deletions(-) create mode 100644 src/datatypes/bigint.ts create mode 100644 test/datatypes/bigint-test.ts diff --git a/README.md b/README.md index e70f4eed8..5cc8320d5 100644 --- a/README.md +++ b/README.md @@ -42,8 +42,6 @@ Implementors should be aware of the following limitations and gaps in `cql-execu * Issues typically associated with floating point arithmetic * Decimals without a decimal portion (e.g., `2.0`) may be treated as CQL `Integer`s * The following STU (non-normative) features introduced in CQL 1.5 are not yet supported: - * `Long` datatype - * Fluent functions * Retrieve search paths * Retrieve includes * In addition the following features defined prior to CQL 1.5 are also not yet supported: diff --git a/examples/browser/cql4browsers.js b/examples/browser/cql4browsers.js index 1f6dfa962..ceee06ae5 100644 --- a/examples/browser/cql4browsers.js +++ b/examples/browser/cql4browsers.js @@ -77,7 +77,7 @@ class CodeService { } exports.CodeService = CodeService; -},{"./datatypes/datatypes":6}],3:[function(require,module,exports){ +},{"./datatypes/datatypes":7}],3:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -244,7 +244,7 @@ class PatientSource { } exports.PatientSource = PatientSource; -},{"./datatypes/datatypes":6}],4:[function(require,module,exports){ +},{"./datatypes/datatypes":7}],4:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -331,7 +331,21 @@ exports.default = { ValueSet: datatypes_1.ValueSet }; -},{"./cql-code-service":2,"./cql-patient":3,"./datatypes/datatypes":6,"./elm/expression":22,"./elm/library":27,"./runtime/context":42,"./runtime/executor":43,"./runtime/messageListeners":44,"./runtime/repository":45,"./runtime/results":46,"./types":49,"./util/customErrors":53}],5:[function(require,module,exports){ +},{"./cql-code-service":2,"./cql-patient":3,"./datatypes/datatypes":7,"./elm/expression":23,"./elm/library":28,"./runtime/context":43,"./runtime/executor":44,"./runtime/messageListeners":45,"./runtime/repository":46,"./runtime/results":47,"./types":50,"./util/customErrors":54}],5:[function(require,module,exports){ +"use strict"; +// By default, BigInt throws a TypeError if you attempt to JSON.stringify it. +// You can avoid the TypeError by defining a `toJSON()` function for BigInt. +// We will use the same serialization approach as FHIR uses for integer64: a string. +// See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt#use_within_json +// See: https://hl7.org/fhir/R5/json.html#primitive +Object.defineProperty(exports, "__esModule", { value: true }); +if (BigInt.prototype.toJSON === undefined) { + BigInt.prototype.toJSON = function () { + return this.toString(); + }; +} + +},{}],6:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ValueSet = exports.CQLValueSet = exports.CodeSystem = exports.Vocabulary = exports.Concept = exports.Code = void 0; @@ -507,7 +521,7 @@ function codesMatch(code1, code2) { return code1.code === code2.code && code1.system === code2.system; } -},{"../util/util":57}],6:[function(require,module,exports){ +},{"../util/util":58}],7:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -524,6 +538,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) { for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); +__exportStar(require("./bigint"), exports); __exportStar(require("./logic"), exports); __exportStar(require("./clinical"), exports); __exportStar(require("./uncertainty"), exports); @@ -532,9 +547,8 @@ __exportStar(require("./interval"), exports); __exportStar(require("./quantity"), exports); __exportStar(require("./ratio"), exports); -},{"./clinical":5,"./datetime":7,"./interval":9,"./logic":10,"./quantity":11,"./ratio":12,"./uncertainty":13}],7:[function(require,module,exports){ +},{"./bigint":5,"./clinical":6,"./datetime":8,"./interval":10,"./logic":11,"./quantity":12,"./ratio":13,"./uncertainty":14}],8:[function(require,module,exports){ "use strict"; -var _a, _b; Object.defineProperty(exports, "__esModule", { value: true }); exports.MAX_TIME_VALUE = exports.MIN_TIME_VALUE = exports.MAX_DATE_VALUE = exports.MIN_DATE_VALUE = exports.MAX_DATETIME_VALUE = exports.MIN_DATETIME_VALUE = exports.Date = exports.DateTime = void 0; /* eslint-disable @typescript-eslint/ban-ts-comment */ @@ -1294,18 +1308,17 @@ class DateTime extends AbstractDate { : DATETIME_PRECISION_VALUE_MAP.get(this.getPrecision()); } toLuxonDateTime() { - var _a, _b, _c, _d, _e, _f, _g; const offsetMins = this.timezoneOffset != null ? this.timezoneOffset * 60 : new util_1.jsDate().getTimezoneOffset() * -1; return luxon_1.DateTime.fromObject({ - year: (_a = this.year) !== null && _a !== void 0 ? _a : undefined, - month: (_b = this.month) !== null && _b !== void 0 ? _b : undefined, - day: (_c = this.day) !== null && _c !== void 0 ? _c : undefined, - hour: (_d = this.hour) !== null && _d !== void 0 ? _d : undefined, - minute: (_e = this.minute) !== null && _e !== void 0 ? _e : undefined, - second: (_f = this.second) !== null && _f !== void 0 ? _f : undefined, - millisecond: (_g = this.millisecond) !== null && _g !== void 0 ? _g : undefined + year: this.year ?? undefined, + month: this.month ?? undefined, + day: this.day ?? undefined, + hour: this.hour ?? undefined, + minute: this.minute ?? undefined, + second: this.second ?? undefined, + millisecond: this.millisecond ?? undefined }, { zone: luxon_1.FixedOffsetZone.instance(offsetMins) }); @@ -1549,11 +1562,10 @@ class Date extends AbstractDate { return DATETIME_PRECISION_VALUE_MAP.get(this.getPrecision()); } toLuxonDateTime() { - var _a, _b, _c; return luxon_1.DateTime.fromObject({ - year: (_a = this.year) !== null && _a !== void 0 ? _a : undefined, - month: (_b = this.month) !== null && _b !== void 0 ? _b : undefined, - day: (_c = this.day) !== null && _c !== void 0 ? _c : undefined + year: this.year ?? undefined, + month: this.month ?? undefined, + day: this.day ?? undefined }, { zone: luxon_1.FixedOffsetZone.utcInstance }); @@ -1635,8 +1647,8 @@ exports.MIN_DATETIME_VALUE = DateTime.parse('0001-01-01T00:00:00.000'); exports.MAX_DATETIME_VALUE = DateTime.parse('9999-12-31T23:59:59.999'); exports.MIN_DATE_VALUE = Date.parse('0001-01-01'); exports.MAX_DATE_VALUE = Date.parse('9999-12-31'); -exports.MIN_TIME_VALUE = (_a = DateTime.parse('0000-01-01T00:00:00.000')) === null || _a === void 0 ? void 0 : _a.getTime(); -exports.MAX_TIME_VALUE = (_b = DateTime.parse('0000-01-01T23:59:59.999')) === null || _b === void 0 ? void 0 : _b.getTime(); +exports.MIN_TIME_VALUE = DateTime.parse('0000-01-01T00:00:00.000')?.getTime(); +exports.MAX_TIME_VALUE = DateTime.parse('0000-01-01T23:59:59.999')?.getTime(); const DATETIME_PRECISION_VALUE_MAP = (() => { const dtpvMap = new Map(); dtpvMap.set(DateTime.Unit.YEAR, 4); @@ -1734,7 +1746,7 @@ function isPrecisionUnspecifiedOrGreaterThanDay(precision) { return precision == null || /^h|mi|s/.test(precision); } -},{"../util/util":57,"./uncertainty":13,"luxon":75}],8:[function(require,module,exports){ +},{"../util/util":58,"./uncertainty":14,"luxon":76}],9:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Exception = void 0; @@ -1746,7 +1758,7 @@ class Exception { } exports.Exception = Exception; -},{}],9:[function(require,module,exports){ +},{}],10:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -2171,7 +2183,7 @@ class Interval { return cmp.equals(this.toClosed().low, (0, math_1.successor)(other.toClosed().high)); } } - catch (_a) { + catch { return false; } } @@ -2184,7 +2196,7 @@ class Interval { return cmp.equals(this.toClosed().high, (0, math_1.predecessor)(other.toClosed().low)); } } - catch (_a) { + catch { return false; } } @@ -2402,7 +2414,7 @@ function highestNumericUncertainty(x, y) { } } -},{"../util/comparison":52,"../util/math":55,"./logic":10,"./quantity":11,"./uncertainty":13}],10:[function(require,module,exports){ +},{"../util/comparison":53,"../util/math":56,"./logic":11,"./quantity":12,"./uncertainty":14}],11:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ThreeValuedLogic = void 0; @@ -2461,7 +2473,7 @@ class ThreeValuedLogic { } exports.ThreeValuedLogic = ThreeValuedLogic; -},{}],11:[function(require,module,exports){ +},{}],12:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Quantity = void 0; @@ -2665,7 +2677,7 @@ function doMultiplication(a, b) { } } -},{"../util/math":55,"../util/units":56}],12:[function(require,module,exports){ +},{"../util/math":56,"../util/units":57}],13:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Ratio = void 0; @@ -2693,7 +2705,7 @@ class Ratio { if (other != null && other.isRatio) { const divided_this = this.numerator.dividedBy(this.denominator); const divided_other = other.numerator.dividedBy(other.denominator); - return divided_this === null || divided_this === void 0 ? void 0 : divided_this.equals(divided_other); + return divided_this?.equals(divided_other); } else { return false; @@ -2706,7 +2718,7 @@ class Ratio { } exports.Ratio = Ratio; -},{}],13:[function(require,module,exports){ +},{}],14:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Uncertainty = void 0; @@ -2725,7 +2737,7 @@ class Uncertainty { this.low = low; this.high = high; const gt = (a, b) => { - if (typeof a !== typeof b || (a === null || a === void 0 ? void 0 : a.constructor) !== (b === null || b === void 0 ? void 0 : b.constructor)) { + if (typeof a !== typeof b || a?.constructor !== b?.constructor) { // TODO: This should probably throw rather than return false. // Uncertainties with different types probably shouldn't be supported. return false; @@ -2763,11 +2775,10 @@ class Uncertainty { return new Uncertainty(newLow, newHigh); } isPoint() { - var _a, _b; // Note: Can't use normal equality, as that fails for Javascript dates // TODO: Fix after we don't need to support Javascript date uncertainties anymore const lte = (a, b) => { - if (typeof a !== typeof b || (a === null || a === void 0 ? void 0 : a.constructor) !== (b === null || b === void 0 ? void 0 : b.constructor)) { + if (typeof a !== typeof b || a?.constructor !== b?.constructor) { return null; } if (typeof a.sameOrBefore === 'function') { @@ -2778,7 +2789,7 @@ class Uncertainty { } }; const gte = (a, b) => { - if (typeof a !== typeof b || (a === null || a === void 0 ? void 0 : a.constructor) !== (b === null || b === void 0 ? void 0 : b.constructor)) { + if (typeof a !== typeof b || a?.constructor !== b?.constructor) { return null; } if (typeof a.sameOrBefore === 'function') { @@ -2790,8 +2801,8 @@ class Uncertainty { }; return (this.low != null && this.high != null && - ((_a = lte(this.low, this.high)) !== null && _a !== void 0 ? _a : false) && - ((_b = gte(this.low, this.high)) !== null && _b !== void 0 ? _b : false)); + (lte(this.low, this.high) ?? false) && + (gte(this.low, this.high) ?? false)); } equals(other) { // if this is a point, and other is not an uncertainty or a point, then we can compare directly @@ -2808,7 +2819,7 @@ class Uncertainty { } lessThan(other) { const lt = (a, b) => { - if (typeof a !== typeof b || (a === null || a === void 0 ? void 0 : a.constructor) !== (b === null || b === void 0 ? void 0 : b.constructor)) { + if (typeof a !== typeof b || a?.constructor !== b?.constructor) { return null; } if (typeof a.before === 'function') { @@ -2840,7 +2851,7 @@ class Uncertainty { } exports.Uncertainty = Uncertainty; -},{"../util/comparison":52,"./logic":10}],14:[function(require,module,exports){ +},{"../util/comparison":53,"./logic":11}],15:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.AnyTrue = exports.AllTrue = exports.PopulationVariance = exports.Variance = exports.PopulationStdDev = exports.GeometricMean = exports.Product = exports.StdDev = exports.Mode = exports.Median = exports.Avg = exports.Max = exports.Min = exports.Sum = exports.Count = void 0; @@ -2881,7 +2892,7 @@ class Sum extends AggregateExpression { try { items = processQuantities(items); } - catch (_a) { + catch { return null; } if (items.length === 0) { @@ -2913,7 +2924,7 @@ class Min extends AggregateExpression { try { processQuantities(list); } - catch (_a) { + catch { return null; } if (listWithoutNulls.length === 0) { @@ -2945,7 +2956,7 @@ class Max extends AggregateExpression { try { processQuantities(items); } - catch (_a) { + catch { return null; } if (listWithoutNulls.length === 0) { @@ -2974,7 +2985,7 @@ class Avg extends AggregateExpression { try { items = processQuantities(items); } - catch (_a) { + catch { return null; } if (items.length === 0) { @@ -3007,7 +3018,7 @@ class Median extends AggregateExpression { try { items = processQuantities(items); } - catch (_a) { + catch { return null; } if (!hasOnlyQuantities(items)) { @@ -3035,7 +3046,7 @@ class Mode extends AggregateExpression { try { filtered = processQuantities(items); } - catch (_a) { + catch { return null; } if (hasOnlyQuantities(filtered)) { @@ -3087,7 +3098,7 @@ class StdDev extends AggregateExpression { try { items = processQuantities(items); } - catch (_a) { + catch { return null; } if (items.length === 0) { @@ -3140,7 +3151,7 @@ class Product extends AggregateExpression { try { items = processQuantities(items); } - catch (_a) { + catch { return null; } if (items.length === 0) { @@ -3170,7 +3181,7 @@ class GeometricMean extends AggregateExpression { try { items = processQuantities(items); } - catch (_a) { + catch { return null; } if (items.length === 0) { @@ -3273,7 +3284,7 @@ function medianOfNumbers(numbers) { } } -},{"../datatypes/datatypes":6,"../datatypes/exception":8,"../util/comparison":52,"../util/util":57,"./builder":16,"./expression":22}],15:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"../datatypes/exception":9,"../util/comparison":53,"../util/util":58,"./builder":17,"./expression":23}],16:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -3481,8 +3492,21 @@ class TruncatedDivide extends expression_1.Expression { if (args == null || args.some((x) => x == null)) { return null; } - const quotient = args.reduce((x, y) => x / y); - const truncatedQuotient = quotient >= 0 ? Math.floor(quotient) : Math.ceil(quotient); + let truncatedQuotient; + if (typeof args[0] === 'bigint') { + // bigint division always truncates + try { + truncatedQuotient = args.reduce((x, y) => x / y); + } + catch { + // bigint divide by 0 throws an error + return null; + } + } + else { + const quotient = args.reduce((x, y) => x / y); + truncatedQuotient = quotient >= 0 ? Math.floor(quotient) : Math.ceil(quotient); + } if (MathUtil.overflowsOrUnderflows(truncatedQuotient)) { return null; } @@ -3500,7 +3524,7 @@ class Modulo extends expression_1.Expression { return null; } const modulo = args.reduce((x, y) => x % y); - return MathUtil.decimalOrNull(modulo); + return MathUtil.decimalLongOrNull(modulo); } } exports.Modulo = Modulo; @@ -3555,6 +3579,9 @@ class Abs extends expression_1.Expression { else if (arg.isQuantity) { return new quantity_1.Quantity(Math.abs(arg.value), arg.unit); } + else if (typeof arg === 'bigint') { + return arg < 0n ? -arg : arg; + } else { return Math.abs(arg); } @@ -3573,6 +3600,9 @@ class Negate extends expression_1.Expression { else if (arg.isQuantity) { return new quantity_1.Quantity(arg.value * -1, arg.unit); } + else if (typeof arg === 'bigint') { + return arg * -1n; + } else { return arg * -1; } @@ -3648,7 +3678,7 @@ class Power extends expression_1.Expression { if (args == null || args.some((x) => x == null)) { return null; } - const power = args.reduce((x, y) => Math.pow(x, y)); + const power = args.reduce((x, y) => x ** y); if (MathUtil.overflowsOrUnderflows(power)) { return null; } @@ -3771,7 +3801,7 @@ class Predecessor extends expression_1.Expression { } exports.Predecessor = Predecessor; -},{"../datatypes/quantity":11,"../datatypes/uncertainty":13,"../util/math":55,"./builder":16,"./expression":22}],16:[function(require,module,exports){ +},{"../datatypes/quantity":12,"../datatypes/uncertainty":14,"../util/math":56,"./builder":17,"./expression":23}],17:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -3840,7 +3870,7 @@ function constructByName(name, json) { return new E[name](json); } -},{"../util/util":57,"./expressions":23}],17:[function(require,module,exports){ +},{"../util/util":58,"./expressions":24}],18:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -3883,12 +3913,11 @@ const builder_1 = require("./builder"); const util_1 = require("../util/util"); class ValueSetDef extends expression_1.Expression { constructor(json) { - var _a; super(json); this.name = json.name; this.id = json.id; this.version = json.version; - this.codesystems = (_a = json.codeSystem) === null || _a === void 0 ? void 0 : _a.map((cs) => new CodeSystemRef(cs)); + this.codesystems = json.codeSystem?.map((cs) => new CodeSystemRef(cs)); } async exec(ctx) { let codeSystems; @@ -4157,7 +4186,7 @@ function calculateAge(precision, birthDate, asOf, timeZoneOffset) { birthDate = birthDate.getDateTime(timeZoneOffset); } const result = birthDate.durationBetween(asOf, precision.toLowerCase()); - if (result === null || result === void 0 ? void 0 : result.isPoint()) { + if (result?.isPoint()) { return result.low; } else { @@ -4167,7 +4196,7 @@ function calculateAge(precision, birthDate, asOf, timeZoneOffset) { return null; } -},{"../datatypes/datatypes":6,"../util/util":57,"./builder":16,"./expression":22}],18:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"../util/util":58,"./builder":17,"./expression":23}],19:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.GreaterOrEqual = exports.Greater = exports.LessOrEqual = exports.Less = void 0; @@ -4228,7 +4257,7 @@ class GreaterOrEqual extends expression_1.Expression { } exports.GreaterOrEqual = GreaterOrEqual; -},{"../datatypes/datatypes":6,"./expression":22}],19:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"./expression":23}],20:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Case = exports.CaseItem = exports.If = void 0; @@ -4295,7 +4324,7 @@ class Case extends expression_1.Expression { } exports.Case = Case; -},{"../util/comparison":52,"./builder":16,"./expression":22}],20:[function(require,module,exports){ +},{"../util/comparison":53,"./builder":17,"./expression":23}],21:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -4561,7 +4590,7 @@ class DurationBetween extends expression_1.Expression { } exports.DurationBetween = DurationBetween; -},{"../datatypes/datatypes":6,"./builder":16,"./expression":22,"./literal":29}],21:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"./builder":17,"./expression":23,"./literal":30}],22:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.VersionedIdentifier = exports.IncludeDef = exports.UsingDef = void 0; @@ -4576,7 +4605,7 @@ class VersionedIdentifier extends expression_1.UnimplementedExpression { } exports.VersionedIdentifier = VersionedIdentifier; -},{"./expression":22}],22:[function(require,module,exports){ +},{"./expression":23}],23:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.UnimplementedExpression = exports.Expression = void 0; @@ -4648,8 +4677,8 @@ class Expression { * library identifier and version are found. */ getRecursiveLibraryIdentifier(ctx) { - var _a, _b, _c; - const identifier = (_c = (_b = (_a = ctx.library) === null || _a === void 0 ? void 0 : _a.source) === null || _b === void 0 ? void 0 : _b.library) === null || _c === void 0 ? void 0 : _c.identifier; + const identifier = ctx.library?.source?.library + ?.identifier; if (identifier) { return `${identifier.id}${identifier.version ? `|${identifier.version}` : ''}`; } @@ -4670,7 +4699,7 @@ class UnimplementedExpression extends Expression { } exports.UnimplementedExpression = UnimplementedExpression; -},{"../util/customErrors":53,"../util/util":57,"./builder":16}],23:[function(require,module,exports){ +},{"../util/customErrors":54,"../util/util":58,"./builder":17}],24:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -4727,7 +4756,7 @@ Object.defineProperty(exports, "doIncludes", { enumerable: true, get: function ( Object.defineProperty(exports, "doExcept", { enumerable: true, get: function () { return interval_1.doExcept; } }); Object.defineProperty(exports, "doContains", { enumerable: true, get: function () { return interval_1.doContains; } }); -},{"./aggregate":14,"./arithmetic":15,"./clinical":17,"./comparison":18,"./conditional":19,"./datetime":20,"./declaration":21,"./expression":22,"./external":24,"./instance":25,"./interval":26,"./list":28,"./literal":29,"./logical":30,"./message":31,"./nullological":32,"./overloaded":33,"./parameters":34,"./quantity":35,"./query":36,"./ratio":37,"./reusable":38,"./string":39,"./structured":40,"./type":41}],24:[function(require,module,exports){ +},{"./aggregate":15,"./arithmetic":16,"./clinical":18,"./comparison":19,"./conditional":20,"./datetime":21,"./declaration":22,"./expression":23,"./external":25,"./instance":26,"./interval":27,"./list":29,"./literal":30,"./logical":31,"./message":32,"./nullological":33,"./overloaded":34,"./parameters":35,"./quantity":36,"./query":37,"./ratio":38,"./reusable":39,"./string":40,"./structured":41,"./type":42}],25:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Retrieve = void 0; @@ -4747,7 +4776,11 @@ class Retrieve extends expression_1.Expression { async exec(ctx) { // Object with retrieve information to pass back to patient source // Always assign datatype. Assign codeProperty and dateProperty if present - const retrieveDetails = Object.assign(Object.assign({ datatype: this.datatype }, (this.codeProperty ? { codeProperty: this.codeProperty } : {})), (this.dateProperty ? { dateProperty: this.dateProperty } : {})); + const retrieveDetails = { + datatype: this.datatype, + ...(this.codeProperty ? { codeProperty: this.codeProperty } : {}), + ...(this.dateProperty ? { dateProperty: this.dateProperty } : {}) + }; if (this.codes) { const executedCodes = await this.codes.execute(ctx); if (executedCodes == null) { @@ -4772,7 +4805,7 @@ class Retrieve extends expression_1.Expression { records = records.filter((r) => this.recordMatchesCodesOrVS(r, retrieveDetails.codes)); } if (retrieveDetails.dateRange && this.dateProperty) { - records = records.filter((r) => { var _a; return (_a = retrieveDetails.dateRange) === null || _a === void 0 ? void 0 : _a.includes(r.getDateOrInterval(this.dateProperty)); }); + records = records.filter((r) => retrieveDetails.dateRange?.includes(r.getDateOrInterval(this.dateProperty))); } if (Array.isArray(records)) { ctx.evaluatedRecords.push(...records); @@ -4793,7 +4826,7 @@ class Retrieve extends expression_1.Expression { } exports.Retrieve = Retrieve; -},{"../util/util":57,"./builder":16,"./expression":22}],25:[function(require,module,exports){ +},{"../util/util":58,"./builder":17,"./expression":23}],26:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Instance = void 0; @@ -4835,7 +4868,7 @@ class Instance extends expression_1.Expression { } exports.Instance = Instance; -},{"../datatypes/datatypes":6,"../datatypes/quantity":11,"./builder":16,"./expression":22}],26:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"../datatypes/quantity":12,"./builder":17,"./expression":23}],27:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -5070,8 +5103,7 @@ class Width extends expression_1.Expression { super(json); } async exec(ctx) { - var _a; - const interval = await ((_a = this.arg) === null || _a === void 0 ? void 0 : _a.execute(ctx)); + const interval = await this.arg?.execute(ctx); if (interval == null) { return null; } @@ -5084,8 +5116,7 @@ class Size extends expression_1.Expression { super(json); } async exec(ctx) { - var _a; - const interval = await ((_a = this.arg) === null || _a === void 0 ? void 0 : _a.execute(ctx)); + const interval = await this.arg?.execute(ctx); if (interval == null) { return null; } @@ -5098,8 +5129,7 @@ class Start extends expression_1.Expression { super(json); } async exec(ctx) { - var _a; - const interval = await ((_a = this.arg) === null || _a === void 0 ? void 0 : _a.execute(ctx)); + const interval = await this.arg?.execute(ctx); if (interval == null) { return null; } @@ -5117,8 +5147,7 @@ class End extends expression_1.Expression { super(json); } async exec(ctx) { - var _a; - const interval = await ((_a = this.arg) === null || _a === void 0 ? void 0 : _a.execute(ctx)); + const interval = await this.arg?.execute(ctx); if (interval == null) { return null; } @@ -5581,18 +5610,17 @@ function truncateDecimal(decimal, decimalPlaces) { return parseFloat(decimal.toString().match(re)[0]); } -},{"../datatypes/interval":9,"../datatypes/quantity":11,"../util/math":55,"../util/units":56,"./builder":16,"./expression":22}],27:[function(require,module,exports){ +},{"../datatypes/interval":10,"../datatypes/quantity":12,"../util/math":56,"../util/units":57,"./builder":17,"./expression":23}],28:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Library = void 0; const expressions_1 = require("./expressions"); class Library { constructor(json, libraryManager) { - var _a, _b; this.source = json; // identifier - this.name = (_a = json.library.identifier) === null || _a === void 0 ? void 0 : _a.id; - this.version = (_b = json.library.identifier) === null || _b === void 0 ? void 0 : _b.version; + this.name = json.library.identifier?.id; + this.version = json.library.identifier?.version; // usings const usingDefs = (json.library.usings && json.library.usings.def) || []; this.usings = usingDefs @@ -5688,7 +5716,7 @@ class Library { } exports.Library = Library; -},{"./expressions":23}],28:[function(require,module,exports){ +},{"./expressions":24}],29:[function(require,module,exports){ "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; @@ -5966,7 +5994,7 @@ class Slice extends expression_1.Expression { exports.Slice = Slice; // Length is completely handled by overloaded#Length -},{"../util/comparison":52,"../util/immutableUtil":54,"../util/util":57,"./builder":16,"./expression":22,"immutable":72}],29:[function(require,module,exports){ +},{"../util/comparison":53,"../util/immutableUtil":55,"../util/util":58,"./builder":17,"./expression":23,"immutable":73}],30:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.StringLiteral = exports.DecimalLiteral = exports.LongLiteral = exports.IntegerLiteral = exports.BooleanLiteral = exports.Literal = void 0; @@ -6032,7 +6060,7 @@ exports.IntegerLiteral = IntegerLiteral; class LongLiteral extends Literal { constructor(json) { super(json); - this.value = parseInt(this.value, 10); + this.value = BigInt(this.value); } // Define a simple getter to allow type-checking of this class without instanceof // and in a way that survives minification (as opposed to checking constructor.name) @@ -6075,7 +6103,7 @@ class StringLiteral extends Literal { } exports.StringLiteral = StringLiteral; -},{"./expression":22}],30:[function(require,module,exports){ +},{"./expression":23}],31:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.IsFalse = exports.IsTrue = exports.Xor = exports.Not = exports.Or = exports.Implies = exports.And = void 0; @@ -6146,7 +6174,7 @@ class IsFalse extends expression_1.Expression { } exports.IsFalse = IsFalse; -},{"../datatypes/datatypes":6,"./expression":22}],31:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"./expression":23}],32:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Message = void 0; @@ -6178,7 +6206,7 @@ class Message extends expression_1.Expression { } exports.Message = Message; -},{"./builder":16,"./expression":22}],32:[function(require,module,exports){ +},{"./builder":17,"./expression":23}],33:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Coalesce = exports.IsNull = exports.Null = void 0; @@ -6228,7 +6256,7 @@ class Coalesce extends expression_1.Expression { } exports.Coalesce = Coalesce; -},{"./expression":22}],33:[function(require,module,exports){ +},{"./expression":23}],34:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -6354,8 +6382,7 @@ class Union extends expression_1.Expression { return lib.doUnion(a, b); } listTypeArgs() { - var _a; - return (_a = this.args) === null || _a === void 0 ? void 0 : _a.some((arg) => { + return this.args?.some((arg) => { return arg.asTypeSpecifier != null && arg.asTypeSpecifier.type === 'ListTypeSpecifier'; }); } @@ -6628,7 +6655,7 @@ class Precision extends expression_1.Expression { } exports.Precision = Precision; -},{"../datatypes/datetime":7,"../datatypes/logic":10,"../util/comparison":52,"../util/util":57,"./datetime":20,"./expression":22,"./interval":26,"./list":28}],34:[function(require,module,exports){ +},{"../datatypes/datetime":8,"../datatypes/logic":11,"../util/comparison":53,"../util/util":58,"./datetime":21,"./expression":23,"./interval":27,"./list":29}],35:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ParameterRef = exports.ParameterDef = void 0; @@ -6672,7 +6699,7 @@ class ParameterRef extends expression_1.Expression { } exports.ParameterRef = ParameterRef; -},{"./builder":16,"./expression":22}],35:[function(require,module,exports){ +},{"./builder":17,"./expression":23}],36:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -6725,7 +6752,7 @@ class Quantity extends expression_1.Expression { } exports.Quantity = Quantity; -},{"../datatypes/datatypes":6,"./expression":22}],36:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"./expression":23}],37:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.QueryLetRef = exports.AliasRef = exports.Query = exports.SortClause = exports.ReturnClause = exports.ByColumn = exports.ByExpression = exports.ByDirection = exports.Sort = exports.Without = exports.With = exports.LetClause = exports.AliasedQuerySource = void 0; @@ -7020,7 +7047,7 @@ function cartesianProductOf(sources) { }, [[]]); } -},{"../util/util":57,"./builder":16,"./expression":22,"./list":28}],37:[function(require,module,exports){ +},{"../util/util":58,"./builder":17,"./expression":23,"./list":29}],38:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -7082,7 +7109,7 @@ class Ratio extends expression_1.Expression { } exports.Ratio = Ratio; -},{"../datatypes/datatypes":6,"../datatypes/quantity":11,"./expression":22}],38:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"../datatypes/quantity":12,"./expression":23}],39:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.IdentifierRef = exports.OperandRef = exports.FunctionRef = exports.FunctionDef = exports.ExpressionRef = exports.ExpressionDef = void 0; @@ -7240,7 +7267,7 @@ class IdentifierRef extends expression_1.Expression { } exports.IdentifierRef = IdentifierRef; -},{"./builder":16,"./expression":22}],39:[function(require,module,exports){ +},{"./builder":17,"./expression":23}],40:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ReplaceMatches = exports.EndsWith = exports.StartsWith = exports.Substring = exports.Matches = exports.LastPositionOf = exports.PositionOf = exports.Lower = exports.Upper = exports.SplitOnMatches = exports.Split = exports.Combine = exports.Concatenate = void 0; @@ -7471,7 +7498,7 @@ class ReplaceMatches extends expression_1.Expression { } exports.ReplaceMatches = ReplaceMatches; -},{"./builder":16,"./expression":22}],40:[function(require,module,exports){ +},{"./builder":17,"./expression":23}],41:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.TupleElementDefinition = exports.TupleElement = exports.Tuple = exports.Property = void 0; @@ -7548,7 +7575,7 @@ class TupleElementDefinition extends expression_1.UnimplementedExpression { } exports.TupleElementDefinition = TupleElementDefinition; -},{"./builder":16,"./expression":22}],41:[function(require,module,exports){ +},{"./builder":17,"./expression":23}],42:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.TupleTypeSpecifier = exports.NamedTypeSpecifier = exports.ListTypeSpecifier = exports.IntervalTypeSpecifier = exports.Is = exports.CanConvertQuantity = exports.ConvertQuantity = exports.ConvertsToTime = exports.ConvertsToString = exports.ConvertsToRatio = exports.ConvertsToQuantity = exports.ConvertsToInteger = exports.ConvertsToDecimal = exports.ConvertsToDateTime = exports.ConvertsToDate = exports.ConvertsToBoolean = exports.Convert = exports.ToTime = exports.ToString = exports.ToRatio = exports.ToQuantity = exports.ToLong = exports.ToInteger = exports.ToDecimal = exports.ToDateTime = exports.ToDate = exports.ToConcept = exports.ToBoolean = exports.As = void 0; @@ -7702,8 +7729,8 @@ class ToInteger extends expression_1.Expression { return arg; } } - else if (typeof arg === 'string') { - const integer = parseInt(arg); + else if (typeof arg === 'string' || typeof arg === 'bigint') { + const integer = Number(arg); if ((0, math_1.isValidInteger)(integer)) { return integer; } @@ -7721,19 +7748,24 @@ class ToLong extends expression_1.Expression { } async exec(ctx) { const arg = await this.execArgs(ctx); - if (typeof arg === 'number') { + if (typeof arg === 'bigint') { if ((0, math_1.isValidLong)(arg)) { return arg; } } - else if (typeof arg === 'string') { - const long = parseInt(arg); - if ((0, math_1.isValidLong)(long)) { - return long; + else if (typeof arg === 'number' || typeof arg === 'string') { + try { + const long = BigInt(arg); + if ((0, math_1.isValidLong)(long)) { + return long; + } + } + catch { + return null; } } else if (typeof arg === 'boolean') { - return arg ? 1 : 0; + return arg ? 1n : 0n; } return null; } @@ -7787,7 +7819,7 @@ class ToRatio extends expression_1.Expression { numerator = (0, quantity_1.parseQuantity)(splitRatioString[1]); denominator = (0, quantity_1.parseQuantity)(splitRatioString[4]); } - catch (_a) { + catch { // If the input string is not formatted correctly, or cannot be // interpreted as a valid Quantity value, the result is null. return null; @@ -8055,7 +8087,7 @@ async function canConvertToType(ConversionClass, operand, ctx) { return false; } } - catch (_a) { + catch { return false; } } @@ -8069,7 +8101,7 @@ class ConvertQuantity extends expression_1.Expression { try { return quantity.convertUnit(newUnit); } - catch (_a) { + catch { // Cannot convert input to target unit, spec says to return null return null; } @@ -8088,7 +8120,7 @@ class CanConvertQuantity extends expression_1.Expression { quantity.convertUnit(newUnit); return true; } - catch (_a) { + catch { return false; } } @@ -8238,7 +8270,7 @@ class TupleTypeSpecifier extends expression_1.UnimplementedExpression { } exports.TupleTypeSpecifier = TupleTypeSpecifier; -},{"../datatypes/clinical":5,"../datatypes/datetime":7,"../datatypes/quantity":11,"../datatypes/ratio":12,"../datatypes/uncertainty":13,"../util/math":55,"../util/util":57,"./expression":22}],42:[function(require,module,exports){ +},{"../datatypes/clinical":6,"../datatypes/datetime":8,"../datatypes/quantity":12,"../datatypes/ratio":13,"../datatypes/uncertainty":14,"../util/math":56,"../util/util":58,"./expression":23}],43:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -8288,7 +8320,7 @@ class Context { this.localId_context = {}; this.evaluatedRecords = []; // TODO: If there is an issue with number of parameters look into cql4browsers fix: 387ea77538182833283af65e6341e7a05192304c - this.checkParameters(_parameters !== null && _parameters !== void 0 ? _parameters : {}); // not crazy about possibly throwing an error in a constructor, but... + this.checkParameters(_parameters ?? {}); // not crazy about possibly throwing an error in a constructor, but... this._parameters = _parameters || {}; this.executionDateTime = executionDateTime; this.messageListener = messageListener; @@ -8327,7 +8359,7 @@ class Context { } childContext(context_values) { const ctx = new Context(this); - ctx.context_values = context_values !== null && context_values !== void 0 ? context_values : {}; + ctx.context_values = context_values ?? {}; return ctx; } getLibraryContext(library) { @@ -8538,8 +8570,9 @@ class Context { case '{urn:hl7-org:elm-types:r1}Decimal': return typeof val === 'number'; case '{urn:hl7-org:elm-types:r1}Integer': - case '{urn:hl7-org:elm-types:r1}Long': return typeof val === 'number' && Math.floor(val) === val; + case '{urn:hl7-org:elm-types:r1}Long': + return typeof val === 'bigint'; case '{urn:hl7-org:elm-types:r1}String': return typeof val === 'string'; case '{urn:hl7-org:elm-types:r1}Concept': @@ -8588,7 +8621,7 @@ class Context { return typeof val === 'number' && Math.floor(val) === val; } else if (inst.isLongLiteral) { - return typeof val === 'number' && Math.floor(val) === val; + return typeof val === 'bigint'; } else if (inst.isStringLiteral) { return typeof val === 'string'; @@ -8696,7 +8729,7 @@ class UnfilteredContext extends Context { } exports.UnfilteredContext = UnfilteredContext; -},{"../datatypes/datatypes":6,"../datatypes/exception":8,"../util/util":57,"./messageListeners":44}],43:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"../datatypes/exception":9,"../util/util":58,"./messageListeners":45}],44:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Executor = void 0; @@ -8776,7 +8809,7 @@ class Executor { } exports.Executor = Executor; -},{"./context":42,"./messageListeners":44,"./results":46}],44:[function(require,module,exports){ +},{"./context":43,"./messageListeners":45,"./results":47}],45:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ConsoleMessageListener = exports.NullMessageListener = void 0; @@ -8802,7 +8835,7 @@ class ConsoleMessageListener { } exports.ConsoleMessageListener = ConsoleMessageListener; -},{}],45:[function(require,module,exports){ +},{}],46:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Repository = void 0; @@ -8833,7 +8866,7 @@ class Repository { } exports.Repository = Repository; -},{"../elm/library":27}],46:[function(require,module,exports){ +},{"../elm/library":28}],47:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Results = void 0; @@ -8870,15 +8903,15 @@ class Results { } exports.Results = Results; -},{}],47:[function(require,module,exports){ +},{}],48:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -},{}],48:[function(require,module,exports){ +},{}],49:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -},{}],49:[function(require,module,exports){ +},{}],50:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -8900,16 +8933,16 @@ __exportStar(require("./cql-patient.interfaces"), exports); __exportStar(require("./runtime.types"), exports); __exportStar(require("./type-specifiers.interfaces"), exports); -},{"./cql-code-service.interfaces":47,"./cql-patient.interfaces":48,"./runtime.types":50,"./type-specifiers.interfaces":51}],50:[function(require,module,exports){ +},{"./cql-code-service.interfaces":48,"./cql-patient.interfaces":49,"./runtime.types":51,"./type-specifiers.interfaces":52}],51:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -},{}],51:[function(require,module,exports){ +},{}],52:[function(require,module,exports){ "use strict"; // Types derived from http://cql.hl7.org/04-logicalspecification.html#typespecifier Object.defineProperty(exports, "__esModule", { value: true }); -},{}],52:[function(require,module,exports){ +},{}],53:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.lessThan = lessThan; @@ -9153,7 +9186,7 @@ function equals(a, b) { return false; } -},{"../datatypes/datatypes":6}],53:[function(require,module,exports){ +},{"../datatypes/datatypes":7}],54:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.AnnotatedError = void 0; @@ -9173,7 +9206,7 @@ class AnnotatedError extends Error { } exports.AnnotatedError = AnnotatedError; -},{}],54:[function(require,module,exports){ +},{}],55:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -9224,7 +9257,6 @@ const ucumUtilInstance = ucum.UcumLhcUtils.getInstance(); * A key is normalized such that representations for quantities, dates, intervals, etc. are comparable. */ const toNormalizedKey = (js) => { - var _a, _b, _c, _d, _e; // This is necessary because of the oddities of CQL // It allows ignoring non-set values in tuples to be compared correctly with set as null values in tuples if (js === null || js === undefined) { @@ -9281,7 +9313,7 @@ const toNormalizedKey = (js) => { case datatypes_1.Quantity: if (!js.unit) { return immutable_1.default.Map({ - value: (_a = js.value) !== null && _a !== void 0 ? _a : null, + value: js.value ?? null, unit: null, __instance: js.constructor }); @@ -9291,8 +9323,8 @@ const toNormalizedKey = (js) => { if (!baseUnitKey) { // No units found - normalization not possible and use provided values return immutable_1.default.Map({ - value: (_b = js.value) !== null && _b !== void 0 ? _b : null, - unit: (_c = js.unit) !== null && _c !== void 0 ? _c : null, + value: js.value ?? null, + unit: js.unit ?? null, __instance: js.constructor }); } @@ -9302,8 +9334,8 @@ const toNormalizedKey = (js) => { const conversionValue = (0, units_1.convertUnit)(js.value, js.unit, baseUnitKeyCode); const finalValue = conversionValue ? (0, math_1.decimalAdjust)('round', conversionValue, -8) : null; return immutable_1.default.Map({ - value: finalValue !== null && finalValue !== void 0 ? finalValue : null, - unit: baseUnitKeyCode !== null && baseUnitKeyCode !== void 0 ? baseUnitKeyCode : null, + value: finalValue ?? null, + unit: baseUnitKeyCode ?? null, __instance: js.constructor }); } @@ -9338,12 +9370,12 @@ const toNormalizedKey = (js) => { return immutable_1.default.Seq(js) .map((x) => (0, exports.toNormalizedKey)(x)) .toMap() - .set('__instance', (_e = (0, exports.toNormalizedKey)((_d = js._typeHierarchy) === null || _d === void 0 ? void 0 : _d.call(js))) !== null && _e !== void 0 ? _e : js.constructor); + .set('__instance', (0, exports.toNormalizedKey)(js._typeHierarchy?.()) ?? js.constructor); } }; exports.toNormalizedKey = toNormalizedKey; -},{"../datatypes/datatypes":6,"./math":55,"./units":56,"@lhncbc/ucum-lhc":68,"immutable":72}],55:[function(require,module,exports){ +},{"../datatypes/datatypes":7,"./math":56,"./units":57,"@lhncbc/ucum-lhc":69,"immutable":73}],56:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.OverFlowException = exports.MAX_TIME_VALUE = exports.MIN_TIME_VALUE = exports.MAX_DATE_VALUE = exports.MIN_DATE_VALUE = exports.MAX_DATETIME_VALUE = exports.MIN_DATETIME_VALUE = exports.MIN_FLOAT_PRECISION_VALUE = exports.MIN_FLOAT_VALUE = exports.MAX_FLOAT_VALUE = exports.MIN_LONG_VALUE = exports.MAX_LONG_VALUE = exports.MIN_INT_VALUE = exports.MAX_INT_VALUE = void 0; @@ -9360,13 +9392,14 @@ exports.minValueForInstance = minValueForInstance; exports.minValueForType = minValueForType; exports.decimalAdjust = decimalAdjust; exports.decimalOrNull = decimalOrNull; +exports.decimalLongOrNull = decimalLongOrNull; const exception_1 = require("../datatypes/exception"); const datetime_1 = require("../datatypes/datetime"); const uncertainty_1 = require("../datatypes/uncertainty"); exports.MAX_INT_VALUE = Math.pow(2, 31) - 1; exports.MIN_INT_VALUE = Math.pow(-2, 31); -exports.MAX_LONG_VALUE = Math.pow(2, 63) - 1; -exports.MIN_LONG_VALUE = Math.pow(-2, 63); +exports.MAX_LONG_VALUE = 9223372036854775807n; +exports.MIN_LONG_VALUE = -9223372036854775808n; exports.MAX_FLOAT_VALUE = 99999999999999999999.99999999; exports.MIN_FLOAT_VALUE = -99999999999999999999.99999999; exports.MIN_FLOAT_PRECISION_VALUE = Math.pow(10, -8); @@ -9409,8 +9442,12 @@ function overflowsOrUnderflows(value) { return true; } } + else if (typeof value === 'bigint') { + if (!isValidLong(value)) { + return true; + } + } else if (Number.isInteger(value)) { - // TODO: Somehow distinguish Integer from Long if (!isValidInteger(value)) { return true; } @@ -9426,7 +9463,7 @@ function overflowsOrUnderflows(value) { return false; } function isValidInteger(integer) { - if (isNaN(integer)) { + if (!Number.isInteger(integer)) { return false; } if (integer > exports.MAX_INT_VALUE) { @@ -9438,7 +9475,7 @@ function isValidInteger(integer) { return true; } function isValidLong(long) { - if (isNaN(long)) { + if (typeof long !== 'bigint') { return false; } if (long > exports.MAX_LONG_VALUE) { @@ -9453,6 +9490,9 @@ function isValidDecimal(decimal) { if (isNaN(decimal)) { return false; } + if (typeof decimal !== 'number') { + return false; + } if (decimal > exports.MAX_FLOAT_VALUE) { return false; } @@ -9482,7 +9522,6 @@ exports.OverFlowException = OverFlowException; function successor(val) { if (typeof val === 'number') { if (Number.isInteger(val)) { - // TODO: Somehow distinguish Integer from Long if (val >= exports.MAX_INT_VALUE) { throw new OverFlowException(); } @@ -9499,6 +9538,14 @@ function successor(val) { } } } + else if (typeof val === 'bigint') { + if (val >= exports.MAX_LONG_VALUE) { + throw new OverFlowException(); + } + else { + return val + 1n; + } + } else if (val && val.isTime && val.isTime()) { if (val.sameAs(exports.MAX_TIME_VALUE)) { throw new OverFlowException(); @@ -9529,7 +9576,7 @@ function successor(val) { try { return successor(val.high); } - catch (_a) { + catch { return val.high; } })(); @@ -9547,7 +9594,6 @@ function successor(val) { function predecessor(val) { if (typeof val === 'number') { if (Number.isInteger(val)) { - // TODO: Somehow distinguish Integer from Long if (val <= exports.MIN_INT_VALUE) { throw new OverFlowException(); } @@ -9564,6 +9610,14 @@ function predecessor(val) { } } } + else if (typeof val === 'bigint') { + if (val <= exports.MIN_LONG_VALUE) { + throw new OverFlowException(); + } + else { + return val - 1n; + } + } else if (val && val.isTime && val.isTime()) { if (val.sameAs(exports.MIN_TIME_VALUE)) { throw new OverFlowException(); @@ -9594,7 +9648,7 @@ function predecessor(val) { try { return predecessor(val.low); } - catch (_a) { + catch { return val.low; } })(); @@ -9611,7 +9665,6 @@ function predecessor(val) { } function maxValueForInstance(val) { if (typeof val === 'number') { - // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return exports.MAX_INT_VALUE; } @@ -9619,14 +9672,17 @@ function maxValueForInstance(val) { return exports.MAX_FLOAT_VALUE; } } + else if (typeof val === 'bigint') { + return exports.MAX_LONG_VALUE; + } else if (val && val.isTime && val.isTime()) { - return exports.MAX_TIME_VALUE === null || exports.MAX_TIME_VALUE === void 0 ? void 0 : exports.MAX_TIME_VALUE.copy(); + return exports.MAX_TIME_VALUE?.copy(); } else if (val && val.isDateTime) { - return exports.MAX_DATETIME_VALUE === null || exports.MAX_DATETIME_VALUE === void 0 ? void 0 : exports.MAX_DATETIME_VALUE.copy(); + return exports.MAX_DATETIME_VALUE?.copy(); } else if (val && val.isDate) { - return exports.MAX_DATE_VALUE === null || exports.MAX_DATE_VALUE === void 0 ? void 0 : exports.MAX_DATE_VALUE.copy(); + return exports.MAX_DATE_VALUE?.copy(); } else if (val && val.isQuantity) { const val2 = val.clone(); @@ -9646,11 +9702,11 @@ function maxValueForType(type, quantityInstance) { case '{urn:hl7-org:elm-types:r1}Decimal': return exports.MAX_FLOAT_VALUE; case '{urn:hl7-org:elm-types:r1}DateTime': - return exports.MAX_DATETIME_VALUE === null || exports.MAX_DATETIME_VALUE === void 0 ? void 0 : exports.MAX_DATETIME_VALUE.copy(); + return exports.MAX_DATETIME_VALUE?.copy(); case '{urn:hl7-org:elm-types:r1}Date': - return exports.MAX_DATE_VALUE === null || exports.MAX_DATE_VALUE === void 0 ? void 0 : exports.MAX_DATE_VALUE.copy(); + return exports.MAX_DATE_VALUE?.copy(); case '{urn:hl7-org:elm-types:r1}Time': - return exports.MAX_TIME_VALUE === null || exports.MAX_TIME_VALUE === void 0 ? void 0 : exports.MAX_TIME_VALUE.copy(); + return exports.MAX_TIME_VALUE?.copy(); case '{urn:hl7-org:elm-types:r1}Quantity': { if (quantityInstance == null) { // can't infer a quantity unit type from nothing] @@ -9665,7 +9721,6 @@ function maxValueForType(type, quantityInstance) { } function minValueForInstance(val) { if (typeof val === 'number') { - // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return exports.MIN_INT_VALUE; } @@ -9673,14 +9728,17 @@ function minValueForInstance(val) { return exports.MIN_FLOAT_VALUE; } } + else if (typeof val === 'bigint') { + return exports.MIN_LONG_VALUE; + } else if (val && val.isTime && val.isTime()) { - return exports.MIN_TIME_VALUE === null || exports.MIN_TIME_VALUE === void 0 ? void 0 : exports.MIN_TIME_VALUE.copy(); + return exports.MIN_TIME_VALUE?.copy(); } else if (val && val.isDateTime) { - return exports.MIN_DATETIME_VALUE === null || exports.MIN_DATETIME_VALUE === void 0 ? void 0 : exports.MIN_DATETIME_VALUE.copy(); + return exports.MIN_DATETIME_VALUE?.copy(); } else if (val && val.isDate) { - return exports.MIN_DATE_VALUE === null || exports.MIN_DATE_VALUE === void 0 ? void 0 : exports.MIN_DATE_VALUE.copy(); + return exports.MIN_DATE_VALUE?.copy(); } else if (val && val.isQuantity) { const val2 = val.clone(); @@ -9700,11 +9758,11 @@ function minValueForType(type, quantityInstance) { case '{urn:hl7-org:elm-types:r1}Decimal': return exports.MIN_FLOAT_VALUE; case '{urn:hl7-org:elm-types:r1}DateTime': - return exports.MIN_DATETIME_VALUE === null || exports.MIN_DATETIME_VALUE === void 0 ? void 0 : exports.MIN_DATETIME_VALUE.copy(); + return exports.MIN_DATETIME_VALUE?.copy(); case '{urn:hl7-org:elm-types:r1}Date': - return exports.MIN_DATE_VALUE === null || exports.MIN_DATE_VALUE === void 0 ? void 0 : exports.MIN_DATE_VALUE.copy(); + return exports.MIN_DATE_VALUE?.copy(); case '{urn:hl7-org:elm-types:r1}Time': - return exports.MIN_TIME_VALUE === null || exports.MIN_TIME_VALUE === void 0 ? void 0 : exports.MIN_TIME_VALUE.copy(); + return exports.MIN_TIME_VALUE?.copy(); case '{urn:hl7-org:elm-types:r1}Quantity': { if (quantityInstance == null) { // can't infer a quantity unit type from nothing] @@ -9740,8 +9798,14 @@ function decimalAdjust(type, value, exp) { function decimalOrNull(value) { return isValidDecimal(value) ? value : null; } +function decimalLongOrNull(value) { + return (typeof value === 'number' && isValidDecimal(value)) || + (typeof value === 'bigint' && isValidLong(value)) + ? value + : null; +} -},{"../datatypes/datetime":7,"../datatypes/exception":8,"../datatypes/uncertainty":13}],56:[function(require,module,exports){ +},{"../datatypes/datetime":8,"../datatypes/exception":9,"../datatypes/uncertainty":14}],57:[function(require,module,exports){ "use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; @@ -9908,7 +9972,7 @@ function compareUnits(unit1, unit2) { //units are the same return 0; } - catch (_a) { + catch { return null; } } @@ -10042,7 +10106,7 @@ function fixUnit(unit) { return fixCQLDateUnit(fixEmptyUnit(unit)); } -},{"./math":55,"@lhncbc/ucum-lhc":68}],57:[function(require,module,exports){ +},{"./math":56,"@lhncbc/ucum-lhc":69}],58:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.jsDate = exports.typeIsArray = void 0; @@ -10158,10 +10222,10 @@ async function resolveValueSet(vs, ctx) { return vsExpansion; } -},{}],58:[function(require,module,exports){ +},{}],59:[function(require,module,exports){ module.exports={"license":"The following data (prefixes and units) was generated by the UCUM LHC code from the UCUM data and selected LOINC combinations of UCUM units. The license for the UCUM LHC code (demo and library code as well as the combined units) is located at https://github.com/lhncbc/ucum-lhc/blob/LICENSE.md.","prefixes":{"config":["code_","ciCode_","name_","printSymbol_","value_","exp_"],"data":[["E","EX","exa","E",1000000000000000000,"18"],["G","GA","giga","G",1000000000,"9"],["Gi","GIB","gibi","Gi",1073741824,null],["Ki","KIB","kibi","Ki",1024,null],["M","MA","mega","M",1000000,"6"],["Mi","MIB","mebi","Mi",1048576,null],["P","PT","peta","P",1000000000000000,"15"],["T","TR","tera","T",1000000000000,"12"],["Ti","TIB","tebi","Ti",1099511627776,null],["Y","YA","yotta","Y",1e+24,"24"],["Z","ZA","zetta","Z",1e+21,"21"],["a","A","atto","a",1e-18,"-18"],["c","C","centi","c",0.01,"-2"],["d","D","deci","d",0.1,"-1"],["da","DA","deka","da",10,"1"],["f","F","femto","f",1e-15,"-15"],["h","H","hecto","h",100,"2"],["k","K","kilo","k",1000,"3"],["m","M","milli","m",0.001,"-3"],["n","N","nano","n",1e-9,"-9"],["p","P","pico","p",1e-12,"-12"],["u","U","micro","μ",0.000001,"-6"],["y","YO","yocto","y",1e-24,"-24"],["z","ZO","zepto","z",1e-21,"-21"]]},"units":{"config":["isBase_","name_","csCode_","ciCode_","property_","magnitude_",["dim_","dimVec_"],"printSymbol_","class_","isMetric_","variable_","cnv_","cnvPfx_","isSpecial_","isArbitrary_","moleExp_","equivalentExp_","synonyms_","source_","loincProperty_","category_","guidance_","csUnitString_","ciUnitString_","baseFactorStr_","baseFactor_","defError_"],"data":[[true,"meter","m","M","length",1,[1,0,0,0,0,0,0],"m",null,false,"L",null,1,false,false,0,0,"meters; metres; distance","UCUM","Len","Clinical","unit of length = 1.09361 yards",null,null,null,null,false],[true,"second - time","s","S","time",1,[0,1,0,0,0,0,0],"s",null,false,"T",null,1,false,false,0,0,"seconds","UCUM","Time","Clinical","",null,null,null,null,false],[true,"gram","g","G","mass",1,[0,0,1,0,0,0,0],"g",null,false,"M",null,1,false,false,0,0,"grams; gm","UCUM","Mass","Clinical","",null,null,null,null,false],[true,"radian","rad","RAD","plane angle",1,[0,0,0,1,0,0,0],"rad",null,false,"A",null,1,false,false,0,0,"radians","UCUM","Angle","Clinical","unit of angular measure where 1 radian = 1/2π turn = 57.296 degrees. ",null,null,null,null,false],[true,"degree Kelvin","K","K","temperature",1,[0,0,0,0,1,0,0],"K",null,false,"C",null,1,false,false,0,0,"Kelvin; degrees","UCUM","Temp","Clinical","absolute, thermodynamic temperature scale ",null,null,null,null,false],[true,"coulomb","C","C","electric charge",1,[0,0,0,0,0,1,0],"C",null,false,"Q",null,1,false,false,0,0,"coulombs","UCUM","","Clinical","defined as amount of 1 electron charge = 6.2415093×10^18 e, and equivalent to 1 Ampere-second",null,null,null,null,false],[true,"candela","cd","CD","luminous intensity",1,[0,0,0,0,0,0,1],"cd",null,false,"F",null,1,false,false,0,0,"candelas","UCUM","","Clinical","SI base unit of luminous intensity",null,null,null,null,false],[false,"the number ten for arbitrary powers","10*","10*","number",10,[0,0,0,0,0,0,0],"10","dimless",false,null,null,1,false,false,0,0,"10^; 10 to the arbitrary powers","UCUM","Num","Clinical","10* by itself is the same as 10, but users can add digits after the *. For example, 10*3 = 1000.","1","1","10",10,false],[false,"the number ten for arbitrary powers","10^","10^","number",10,[0,0,0,0,0,0,0],"10","dimless",false,null,null,1,false,false,0,0,"10*; 10 to the arbitrary power","UCUM","Num","Clinical","10* by itself is the same as 10, but users can add digits after the *. For example, 10*3 = 1000.","1","1","10",10,false],[false,"the number pi","[pi]","[PI]","number",3.141592653589793,[0,0,0,0,0,0,0],"π","dimless",false,null,null,1,false,false,0,0,"π","UCUM","","Constant","a mathematical constant; the ratio of a circle's circumference to its diameter ≈ 3.14159","1","1","3.1415926535897932384626433832795028841971693993751058209749445923",3.141592653589793,false],[false,"","%","%","fraction",0.01,[0,0,0,0,0,0,0],"%","dimless",false,null,null,1,false,false,0,0,"percents","UCUM","FR; NFR; MFR; CFR; SFR Rto; etc. ","Clinical","","10*-2","10*-2","1",1,false],[false,"parts per thousand","[ppth]","[PPTH]","fraction",0.001,[0,0,0,0,0,0,0],"ppth","dimless",false,null,null,1,false,false,0,0,"ppth; 10^-3","UCUM","MCnc; MCnt","Clinical","[ppth] is often used in solution concentrations as 1 g/L or 1 g/kg.\n\nCan be ambigous and would be better if the metric units was used directly. ","10*-3","10*-3","1",1,false],[false,"parts per million","[ppm]","[PPM]","fraction",0.000001,[0,0,0,0,0,0,0],"ppm","dimless",false,null,null,1,false,false,0,0,"ppm; 10^-6","UCUM","MCnt; MCnc; SFr","Clinical","[ppm] is often used in solution concentrations as 1 mg/L or 1 mg/kg. Also used to express mole fractions as 1 mmol/mol.\n\n[ppm] is also used in nuclear magnetic resonance (NMR) to represent chemical shift - the difference of a measured frequency in parts per million from the reference frequency.\n\nCan be ambigous and would be better if the metric units was used directly. ","10*-6","10*-6","1",1,false],[false,"parts per billion","[ppb]","[PPB]","fraction",1e-9,[0,0,0,0,0,0,0],"ppb","dimless",false,null,null,1,false,false,0,0,"ppb; 10^-9","UCUM","MCnt; MCnc; SFr","Clinical","[ppb] is often used in solution concentrations as 1 ug/L or 1 ug/kg. Also used to express mole fractions as 1 umol/mol.\n\nCan be ambigous and would be better if the metric units was used directly. ","10*-9","10*-9","1",1,false],[false,"parts per trillion","[pptr]","[PPTR]","fraction",1e-12,[0,0,0,0,0,0,0],"pptr","dimless",false,null,null,1,false,false,0,0,"pptr; 10^-12","UCUM","MCnt; MCnc; SFr","Clinical","[pptr] is often used in solution concentrations as 1 ng/L or 1 ng/kg. Also used to express mole fractions as 1 nmol/mol.\n\nCan be ambigous and would be better if the metric units was used directly. ","10*-12","10*-12","1",1,false],[false,"mole","mol","MOL","amount of substance",6.0221367e+23,[0,0,0,0,0,0,0],"mol","si",true,null,null,1,false,false,1,0,"moles","UCUM","Sub","Clinical","Measure the number of molecules ","10*23","10*23","6.0221367",6.0221367,false],[false,"steradian - solid angle","sr","SR","solid angle",1,[0,0,0,2,0,0,0],"sr","si",true,null,null,1,false,false,0,0,"square radian; rad2; rad^2","UCUM","Angle","Clinical","unit of solid angle in three-dimensional geometry analagous to radian; used in photometry which measures the perceived brightness of object by human eye (e.g. radiant intensity = watt/steradian)","rad2","RAD2","1",1,false],[false,"hertz","Hz","HZ","frequency",1,[0,-1,0,0,0,0,0],"Hz","si",true,null,null,1,false,false,0,0,"Herz; frequency; frequencies","UCUM","Freq; Num","Clinical","equal to one cycle per second","s-1","S-1","1",1,false],[false,"newton","N","N","force",1000,[1,-2,1,0,0,0,0],"N","si",true,null,null,1,false,false,0,0,"Newtons","UCUM","Force","Clinical","unit of force with base units kg.m/s2","kg.m/s2","KG.M/S2","1",1,false],[false,"pascal","Pa","PAL","pressure",1000,[-1,-2,1,0,0,0,0],"Pa","si",true,null,null,1,false,false,0,0,"pascals","UCUM","Pres","Clinical","standard unit of pressure equal to 1 newton per square meter (N/m2)","N/m2","N/M2","1",1,false],[false,"joule","J","J","energy",1000,[2,-2,1,0,0,0,0],"J","si",true,null,null,1,false,false,0,0,"joules","UCUM","Enrg","Clinical","unit of energy defined as the work required to move an object 1 m with a force of 1 N (N.m) or an electric charge of 1 C through 1 V (C.V), or to produce 1 W for 1 s (W.s) ","N.m","N.M","1",1,false],[false,"watt","W","W","power",1000,[2,-3,1,0,0,0,0],"W","si",true,null,null,1,false,false,0,0,"watts","UCUM","EngRat","Clinical","unit of power equal to 1 Joule per second (J/s) = kg⋅m2⋅s−3","J/s","J/S","1",1,false],[false,"Ampere","A","A","electric current",1,[0,-1,0,0,0,1,0],"A","si",true,null,null,1,false,false,0,0,"Amperes","UCUM","ElpotRat","Clinical","unit of electric current equal to flow rate of electrons equal to 6.2415×10^18 elementary charges moving past a boundary in one second or 1 Coulomb/second","C/s","C/S","1",1,false],[false,"volt","V","V","electric potential",1000,[2,-2,1,0,0,-1,0],"V","si",true,null,null,1,false,false,0,0,"volts","UCUM","Elpot","Clinical","unit of electric potential (voltage) = 1 Joule per Coulomb (J/C)","J/C","J/C","1",1,false],[false,"farad","F","F","electric capacitance",0.001,[-2,2,-1,0,0,2,0],"F","si",true,null,null,1,false,false,0,0,"farads; electric capacitance","UCUM","","Clinical","CGS unit of electric capacitance with base units C/V (Coulomb per Volt)","C/V","C/V","1",1,false],[false,"ohm","Ohm","OHM","electric resistance",1000,[2,-1,1,0,0,-2,0],"Ω","si",true,null,null,1,false,false,0,0,"Ω; resistance; ohms","UCUM","","Clinical","unit of electrical resistance with units of Volt per Ampere","V/A","V/A","1",1,false],[false,"siemens","S","SIE","electric conductance",0.001,[-2,1,-1,0,0,2,0],"S","si",true,null,null,1,false,false,0,0,"Reciprocal ohm; mho; Ω−1; conductance","UCUM","","Clinical","unit of electric conductance (the inverse of electrical resistance) equal to ohm^-1","Ohm-1","OHM-1","1",1,false],[false,"weber","Wb","WB","magnetic flux",1000,[2,-1,1,0,0,-1,0],"Wb","si",true,null,null,1,false,false,0,0,"magnetic flux; webers","UCUM","","Clinical","unit of magnetic flux equal to Volt second","V.s","V.S","1",1,false],[false,"degree Celsius","Cel","CEL","temperature",1,[0,0,0,0,1,0,0],"°C","si",true,null,"Cel",1,true,false,0,0,"°C; degrees","UCUM","Temp","Clinical","","K",null,null,1,false],[false,"tesla","T","T","magnetic flux density",1000,[0,-1,1,0,0,-1,0],"T","si",true,null,null,1,false,false,0,0,"Teslas; magnetic field","UCUM","","Clinical","SI unit of magnetic field strength for magnetic field B equal to 1 Weber/square meter = 1 kg/(s2*A)","Wb/m2","WB/M2","1",1,false],[false,"henry","H","H","inductance",1000,[2,0,1,0,0,-2,0],"H","si",true,null,null,1,false,false,0,0,"henries; inductance","UCUM","","Clinical","unit of electrical inductance; usually expressed in millihenrys (mH) or microhenrys (uH).","Wb/A","WB/A","1",1,false],[false,"lumen","lm","LM","luminous flux",1,[0,0,0,2,0,0,1],"lm","si",true,null,null,1,false,false,0,0,"luminous flux; lumens","UCUM","","Clinical","unit of luminous flux defined as 1 lm = 1 cd⋅sr (candela times sphere)","cd.sr","CD.SR","1",1,false],[false,"lux","lx","LX","illuminance",1,[-2,0,0,2,0,0,1],"lx","si",true,null,null,1,false,false,0,0,"illuminance; luxes","UCUM","","Clinical","unit of illuminance equal to one lumen per square meter. ","lm/m2","LM/M2","1",1,false],[false,"becquerel","Bq","BQ","radioactivity",1,[0,-1,0,0,0,0,0],"Bq","si",true,null,null,1,false,false,0,0,"activity; radiation; becquerels","UCUM","","Clinical","measure of the atomic radiation rate with units s^-1","s-1","S-1","1",1,false],[false,"gray","Gy","GY","energy dose",1,[2,-2,0,0,0,0,0],"Gy","si",true,null,null,1,false,false,0,0,"absorbed doses; ionizing radiation doses; kerma; grays","UCUM","EngCnt","Clinical","unit of ionizing radiation dose with base units of 1 joule of radiation energy per kilogram of matter","J/kg","J/KG","1",1,false],[false,"sievert","Sv","SV","dose equivalent",1,[2,-2,0,0,0,0,0],"Sv","si",true,null,null,1,false,false,0,0,"sieverts; radiation dose quantities; equivalent doses; effective dose; operational dose; committed dose","UCUM","","Clinical","SI unit for radiation dose equivalent equal to 1 Joule/kilogram.","J/kg","J/KG","1",1,false],[false,"degree - plane angle","deg","DEG","plane angle",0.017453292519943295,[0,0,0,1,0,0,0],"°","iso1000",false,null,null,1,false,false,0,0,"°; degree of arc; arc degree; arcdegree; angle","UCUM","Angle","Clinical","one degree is equivalent to π/180 radians.","[pi].rad/360","[PI].RAD/360","2",2,false],[false,"gon","gon","GON","plane angle",0.015707963267948967,[0,0,0,1,0,0,0],"□g","iso1000",false,null,null,1,false,false,0,0,"gon (grade); gons","UCUM","Angle","Nonclinical","unit of plane angle measurement equal to 1/400 circle","deg","DEG","0.9",0.9,false],[false,"arc minute","'","'","plane angle",0.0002908882086657216,[0,0,0,1,0,0,0],"'","iso1000",false,null,null,1,false,false,0,0,"arcminutes; arcmin; arc minutes; arc mins","UCUM","Angle","Clinical","equal to 1/60 degree; used in optometry and opthamology (e.g. visual acuity tests)","deg/60","DEG/60","1",1,false],[false,"arc second","''","''","plane angle",0.00000484813681109536,[0,0,0,1,0,0,0],"''","iso1000",false,null,null,1,false,false,0,0,"arcseconds; arcsecs","UCUM","Angle","Clinical","equal to 1/60 arcminute = 1/3600 degree; used in optometry and opthamology (e.g. visual acuity tests)","'/60","'/60","1",1,false],[false,"Liters","l","L","volume",0.001,[3,0,0,0,0,0,0],"l","iso1000",true,null,null,1,false,false,0,0,"cubic decimeters; decimeters cubed; decimetres; dm3; dm^3; litres; liters, LT ","UCUM","Vol","Clinical","Because lower case \"l\" can be read as the number \"1\", though this is a valid UCUM units. UCUM strongly reccomends using \"L\"","dm3","DM3","1",1,false],[false,"Liters","L","L","volume",0.001,[3,0,0,0,0,0,0],"L","iso1000",true,null,null,1,false,false,0,0,"cubic decimeters; decimeters cubed; decimetres; dm3; dm^3; litres; liters, LT ","UCUM","Vol","Clinical","Because lower case \"l\" can be read as the number \"1\", though this is a valid UCUM units. UCUM strongly reccomends using \"L\"","l",null,"1",1,false],[false,"are","ar","AR","area",100,[2,0,0,0,0,0,0],"a","iso1000",true,null,null,1,false,false,0,0,"100 m2; 100 m^2; 100 square meter; meters squared; metres","UCUM","Area","Clinical","metric base unit for area defined as 100 m^2","m2","M2","100",100,false],[false,"minute","min","MIN","time",60,[0,1,0,0,0,0,0],"min","iso1000",false,null,null,1,false,false,0,0,"minutes","UCUM","Time","Clinical","","s","S","60",60,false],[false,"hour","h","HR","time",3600,[0,1,0,0,0,0,0],"h","iso1000",false,null,null,1,false,false,0,0,"hours; hrs; age","UCUM","Time","Clinical","","min","MIN","60",60,false],[false,"day","d","D","time",86400,[0,1,0,0,0,0,0],"d","iso1000",false,null,null,1,false,false,0,0,"days; age; dy; 24 hours; 24 hrs","UCUM","Time","Clinical","","h","HR","24",24,false],[false,"tropical year","a_t","ANN_T","time",31556925.216,[0,1,0,0,0,0,0],"at","iso1000",false,null,null,1,false,false,0,0,"solar years; a tropical; years","UCUM","Time","Clinical","has an average of 365.242181 days but is constantly changing.","d","D","365.24219",365.24219,false],[false,"mean Julian year","a_j","ANN_J","time",31557600,[0,1,0,0,0,0,0],"aj","iso1000",false,null,null,1,false,false,0,0,"mean Julian yr; a julian; years","UCUM","Time","Clinical","has an average of 365.25 days, and in everyday use, has been replaced by the Gregorian year. However, this unit is used in astronomy to calculate light year. ","d","D","365.25",365.25,false],[false,"mean Gregorian year","a_g","ANN_G","time",31556952,[0,1,0,0,0,0,0],"ag","iso1000",false,null,null,1,false,false,0,0,"mean Gregorian yr; a gregorian; years","UCUM","Time","Clinical","has an average of 365.2425 days and is the most internationally used civil calendar.","d","D","365.2425",365.2425,false],[false,"year","a","ANN","time",31557600,[0,1,0,0,0,0,0],"a","iso1000",false,null,null,1,false,false,0,0,"years; a; yr, yrs; annum","UCUM","Time","Clinical","","a_j","ANN_J","1",1,false],[false,"week","wk","WK","time",604800,[0,1,0,0,0,0,0],"wk","iso1000",false,null,null,1,false,false,0,0,"weeks; wks","UCUM","Time","Clinical","","d","D","7",7,false],[false,"synodal month","mo_s","MO_S","time",2551442.976,[0,1,0,0,0,0,0],"mos","iso1000",false,null,null,1,false,false,0,0,"Moon; synodic month; lunar month; mo-s; mo s; months; moons","UCUM","Time","Nonclinical","has an average of 29.53 days per month, unit used in astronomy","d","D","29.53059",29.53059,false],[false,"mean Julian month","mo_j","MO_J","time",2629800,[0,1,0,0,0,0,0],"moj","iso1000",false,null,null,1,false,false,0,0,"mo-julian; mo Julian; months","UCUM","Time","Clinical","has an average of 30.435 days per month","a_j/12","ANN_J/12","1",1,false],[false,"mean Gregorian month","mo_g","MO_G","time",2629746,[0,1,0,0,0,0,0],"mog","iso1000",false,null,null,1,false,false,0,0,"months; month-gregorian; mo-gregorian","UCUM","Time","Clinical","has an average 30.436875 days per month and is from the most internationally used civil calendar.","a_g/12","ANN_G/12","1",1,false],[false,"month","mo","MO","time",2629800,[0,1,0,0,0,0,0],"mo","iso1000",false,null,null,1,false,false,0,0,"months; duration","UCUM","Time","Clinical","based on Julian calendar which has an average of 30.435 days per month (this unit is used in astronomy but not in everyday life - see mo_g)","mo_j","MO_J","1",1,false],[false,"metric ton","t","TNE","mass",1000000,[0,0,1,0,0,0,0],"t","iso1000",true,null,null,1,false,false,0,0,"tonnes; megagrams; tons","UCUM","Mass","Nonclinical","equal to 1000 kg used in the US (recognized by NIST as metric ton), and internationally (recognized as tonne)","kg","KG","1e3",1000,false],[false,"bar","bar","BAR","pressure",100000000,[-1,-2,1,0,0,0,0],"bar","iso1000",true,null,null,1,false,false,0,0,"bars","UCUM","Pres","Nonclinical","unit of pressure equal to 10^5 Pascals, primarily used by meteorologists and in weather forecasting","Pa","PAL","1e5",100000,false],[false,"unified atomic mass unit","u","AMU","mass",1.6605402e-24,[0,0,1,0,0,0,0],"u","iso1000",true,null,null,1,false,false,0,0,"unified atomic mass units; amu; Dalton; Da","UCUM","Mass","Clinical","the mass of 1/12 of an unbound Carbon-12 atom nuclide equal to 1.6606x10^-27 kg ","g","G","1.6605402e-24",1.6605402e-24,false],[false,"astronomic unit","AU","ASU","length",149597870691,[1,0,0,0,0,0,0],"AU","iso1000",false,null,null,1,false,false,0,0,"AU; units","UCUM","Len","Clinical","unit of length used in astronomy for measuring distance in Solar system","Mm","MAM","149597.870691",149597.870691,false],[false,"parsec","pc","PRS","length",30856780000000000,[1,0,0,0,0,0,0],"pc","iso1000",true,null,null,1,false,false,0,0,"parsecs","UCUM","Len","Clinical","unit of length equal to 3.26 light years, and used to measure large distances to objects outside our Solar System","m","M","3.085678e16",30856780000000000,false],[false,"velocity of light in a vacuum","[c]","[C]","velocity",299792458,[1,-1,0,0,0,0,0],"c","const",true,null,null,1,false,false,0,0,"speed of light","UCUM","Vel","Constant","equal to 299792458 m/s (approximately 3 x 10^8 m/s)","m/s","M/S","299792458",299792458,false],[false,"Planck constant","[h]","[H]","action",6.6260755e-31,[2,-1,1,0,0,0,0],"h","const",true,null,null,1,false,false,0,0,"Planck's constant","UCUM","","Constant","constant = 6.62607004 × 10-34 m2.kg/s; defined as quantum of action","J.s","J.S","6.6260755e-34",6.6260755e-34,false],[false,"Boltzmann constant","[k]","[K]","(unclassified)",1.380658e-20,[2,-2,1,0,-1,0,0],"k","const",true,null,null,1,false,false,0,0,"k; kB","UCUM","","Constant","physical constant relating energy at the individual particle level with temperature = 1.38064852 ×10^−23 J/K","J/K","J/K","1.380658e-23",1.380658e-23,false],[false,"permittivity of vacuum - electric","[eps_0]","[EPS_0]","electric permittivity",8.854187817000001e-15,[-3,2,-1,0,0,2,0],"ε0","const",true,null,null,1,false,false,0,0,"ε0; Electric Constant; vacuum permittivity; permittivity of free space ","UCUM","","Constant","approximately equal to 8.854 × 10^−12 F/m (farads per meter)","F/m","F/M","8.854187817e-12",8.854187817e-12,false],[false,"permeability of vacuum - magnetic","[mu_0]","[MU_0]","magnetic permeability",0.0012566370614359172,[1,0,1,0,0,-2,0],"μ0","const",true,null,null,1,false,false,0,0,"μ0; vacuum permeability; permeability of free space; magnetic constant","UCUM","","Constant","equal to 4π×10^−7 N/A2 (Newtons per square ampere) ≈ 1.2566×10^−6 H/m (Henry per meter)","N/A2","4.[PI].10*-7.N/A2","1",0.0000012566370614359173,false],[false,"elementary charge","[e]","[E]","electric charge",1.60217733e-19,[0,0,0,0,0,1,0],"e","const",true,null,null,1,false,false,0,0,"e; q; electric charges","UCUM","","Constant","the magnitude of the electric charge carried by a single electron or proton ≈ 1.60217×10^-19 Coulombs","C","C","1.60217733e-19",1.60217733e-19,false],[false,"electronvolt","eV","EV","energy",1.60217733e-16,[2,-2,1,0,0,0,0],"eV","iso1000",true,null,null,1,false,false,0,0,"Electron Volts; electronvolts","UCUM","Eng","Clinical","unit of kinetic energy = 1 V * 1.602×10^−19 C = 1.6×10−19 Joules","[e].V","[E].V","1",1,false],[false,"electron mass","[m_e]","[M_E]","mass",9.1093897e-28,[0,0,1,0,0,0,0],"me","const",true,null,null,1,false,false,0,0,"electron rest mass; me","UCUM","Mass","Constant","approximately equal to 9.10938356 × 10-31 kg; defined as the mass of a stationary electron","g","g","9.1093897e-28",9.1093897e-28,false],[false,"proton mass","[m_p]","[M_P]","mass",1.6726231e-24,[0,0,1,0,0,0,0],"mp","const",true,null,null,1,false,false,0,0,"mp; masses","UCUM","Mass","Constant","approximately equal to 1.672622×10−27 kg","g","g","1.6726231e-24",1.6726231e-24,false],[false,"Newtonian constant of gravitation","[G]","[GC]","(unclassified)",6.67259e-14,[3,-2,-1,0,0,0,0],"G","const",true,null,null,1,false,false,0,0,"G; gravitational constant; Newton's constant","UCUM","","Constant","gravitational constant = 6.674×10−11 N⋅m2/kg2","m3.kg-1.s-2","M3.KG-1.S-2","6.67259e-11",6.67259e-11,false],[false,"standard acceleration of free fall","[g]","[G]","acceleration",9.80665,[1,-2,0,0,0,0,0],"gn","const",true,null,null,1,false,false,0,0,"standard gravity; g; ɡ0; ɡn","UCUM","Accel","Constant","defined by standard = 9.80665 m/s2","m/s2","M/S2","980665e-5",9.80665,false],[false,"Torr","Torr","Torr","pressure",133322,[-1,-2,1,0,0,0,0],"Torr","const",false,null,null,1,false,false,0,0,"torrs","UCUM","Pres","Clinical","1 torr = 1 mmHg; unit used to measure blood pressure","Pa","PAL","133.322",133.322,false],[false,"standard atmosphere","atm","ATM","pressure",101325000,[-1,-2,1,0,0,0,0],"atm","const",false,null,null,1,false,false,0,0,"reference pressure; atmos; std atmosphere","UCUM","Pres","Clinical","defined as being precisely equal to 101,325 Pa","Pa","PAL","101325",101325,false],[false,"light-year","[ly]","[LY]","length",9460730472580800,[1,0,0,0,0,0,0],"l.y.","const",true,null,null,1,false,false,0,0,"light years; ly","UCUM","Len","Constant","unit of astronomal distance = 5.88×10^12 mi","[c].a_j","[C].ANN_J","1",1,false],[false,"gram-force","gf","GF","force",9.80665,[1,-2,1,0,0,0,0],"gf","const",true,null,null,1,false,false,0,0,"Newtons; gram forces","UCUM","Force","Clinical","May be specific to unit related to cardiac output","g.[g]","G.[G]","1",1,false],[false,"Kayser","Ky","KY","lineic number",100,[-1,0,0,0,0,0,0],"K","cgs",true,null,null,1,false,false,0,0,"wavenumbers; kaysers","UCUM","InvLen","Clinical","unit of wavelength equal to cm^-1","cm-1","CM-1","1",1,false],[false,"Gal","Gal","GL","acceleration",0.01,[1,-2,0,0,0,0,0],"Gal","cgs",true,null,null,1,false,false,0,0,"galileos; Gals","UCUM","Accel","Clinical","unit of acceleration used in gravimetry; equivalent to cm/s2 ","cm/s2","CM/S2","1",1,false],[false,"dyne","dyn","DYN","force",0.01,[1,-2,1,0,0,0,0],"dyn","cgs",true,null,null,1,false,false,0,0,"dynes","UCUM","Force","Clinical","unit of force equal to 10^-5 Newtons","g.cm/s2","G.CM/S2","1",1,false],[false,"erg","erg","ERG","energy",0.0001,[2,-2,1,0,0,0,0],"erg","cgs",true,null,null,1,false,false,0,0,"10^-7 Joules, 10-7 Joules; 100 nJ; 100 nanoJoules; 1 dyne cm; 1 g.cm2/s2","UCUM","Eng","Clinical","unit of energy = 1 dyne centimeter = 10^-7 Joules","dyn.cm","DYN.CM","1",1,false],[false,"Poise","P","P","dynamic viscosity",100.00000000000001,[-1,-1,1,0,0,0,0],"P","cgs",true,null,null,1,false,false,0,0,"dynamic viscosity; poises","UCUM","Visc","Clinical","unit of dynamic viscosity where 1 Poise = 1/10 Pascal second","dyn.s/cm2","DYN.S/CM2","1",1,false],[false,"Biot","Bi","BI","electric current",10,[0,-1,0,0,0,1,0],"Bi","cgs",true,null,null,1,false,false,0,0,"Bi; abamperes; abA","UCUM","ElpotRat","Clinical","equal to 10 amperes","A","A","10",10,false],[false,"Stokes","St","ST","kinematic viscosity",0.00009999999999999999,[2,-1,0,0,0,0,0],"St","cgs",true,null,null,1,false,false,0,0,"kinematic viscosity","UCUM","Visc","Clinical","unit of kimematic viscosity with units cm2/s","cm2/s","CM2/S","1",1,false],[false,"Maxwell","Mx","MX","flux of magnetic induction",0.00001,[2,-1,1,0,0,-1,0],"Mx","cgs",true,null,null,1,false,false,0,0,"magnetix flux; Maxwells","UCUM","","Clinical","unit of magnetic flux","Wb","WB","1e-8",1e-8,false],[false,"Gauss","G","GS","magnetic flux density",0.1,[0,-1,1,0,0,-1,0],"Gs","cgs",true,null,null,1,false,false,0,0,"magnetic fields; magnetic flux density; induction; B","UCUM","magnetic","Clinical","CGS unit of magnetic flux density, known as magnetic field B; defined as one maxwell unit per square centimeter (see Oersted for CGS unit for H field)","T","T","1e-4",0.0001,false],[false,"Oersted","Oe","OE","magnetic field intensity",79.57747154594767,[-1,-1,0,0,0,1,0],"Oe","cgs",true,null,null,1,false,false,0,0,"H magnetic B field; Oersteds","UCUM","","Clinical","CGS unit of the auxiliary magnetic field H defined as 1 dyne per unit pole = 1000/4π amperes per meter (see Gauss for CGS unit for B field)","A/m","/[PI].A/M","250",79.57747154594767,false],[false,"Gilbert","Gb","GB","magnetic tension",0.7957747154594768,[0,-1,0,0,0,1,0],"Gb","cgs",true,null,null,1,false,false,0,0,"Gi; magnetomotive force; Gilberts","UCUM","","Clinical","unit of magnetomotive force (magnetic potential)","Oe.cm","OE.CM","1",1,false],[false,"stilb","sb","SB","lum. intensity density",10000,[-2,0,0,0,0,0,1],"sb","cgs",true,null,null,1,false,false,0,0,"stilbs","UCUM","","Obsolete","unit of luminance; equal to and replaced by unit candela per square centimeter (cd/cm2)","cd/cm2","CD/CM2","1",1,false],[false,"Lambert","Lmb","LMB","brightness",3183.098861837907,[-2,0,0,0,0,0,1],"L","cgs",true,null,null,1,false,false,0,0,"luminance; lamberts","UCUM","","Clinical","unit of luminance defined as 1 lambert = 1/ π candela per square meter","cd/cm2/[pi]","CD/CM2/[PI]","1",1,false],[false,"phot","ph","PHT","illuminance",0.0001,[-2,0,0,2,0,0,1],"ph","cgs",true,null,null,1,false,false,0,0,"phots","UCUM","","Clinical","CGS photometric unit of illuminance, or luminous flux through an area equal to 10000 lumens per square meter = 10000 lux","lx","LX","1e-4",0.0001,false],[false,"Curie","Ci","CI","radioactivity",37000000000,[0,-1,0,0,0,0,0],"Ci","cgs",true,null,null,1,false,false,0,0,"curies","UCUM","","Obsolete","unit for measuring atomic disintegration rate; replaced by the Bequerel (Bq) unit","Bq","BQ","37e9",37000000000,false],[false,"Roentgen","R","ROE","ion dose",2.58e-7,[0,0,-1,0,0,1,0],"R","cgs",true,null,null,1,false,false,0,0,"röntgen; Roentgens","UCUM","","Clinical","unit of exposure of X-rays and gamma rays in air; unit used primarily in the US but strongly discouraged by NIST","C/kg","C/KG","2.58e-4",0.000258,false],[false,"radiation absorbed dose","RAD","[RAD]","energy dose",0.01,[2,-2,0,0,0,0,0],"RAD","cgs",true,null,null,1,false,false,0,0,"doses","UCUM","","Clinical","unit of radiation absorbed dose used primarily in the US with base units 100 ergs per gram of material. Also see the SI unit Gray (Gy).","erg/g","ERG/G","100",100,false],[false,"radiation equivalent man","REM","[REM]","dose equivalent",0.01,[2,-2,0,0,0,0,0],"REM","cgs",true,null,null,1,false,false,0,0,"Roentgen Equivalent in Man; rems; dose equivalents","UCUM","","Clinical","unit of equivalent dose which measures the effect of radiation on humans equal to 0.01 sievert. Used primarily in the US. Also see SI unit Sievert (Sv)","RAD","[RAD]","1",1,false],[false,"inch","[in_i]","[IN_I]","length",0.025400000000000002,[1,0,0,0,0,0,0],"in","intcust",false,null,null,1,false,false,0,0,"inches; in; international inch; body height","UCUM","Len","Clinical","standard unit for inch in the US and internationally","cm","CM","254e-2",2.54,false],[false,"foot","[ft_i]","[FT_I]","length",0.3048,[1,0,0,0,0,0,0],"ft","intcust",false,null,null,1,false,false,0,0,"ft; fts; foot; international foot; feet; international feet; height","UCUM","Len","Clinical","unit used in the US and internationally","[in_i]","[IN_I]","12",12,false],[false,"yard","[yd_i]","[YD_I]","length",0.9144000000000001,[1,0,0,0,0,0,0],"yd","intcust",false,null,null,1,false,false,0,0,"international yards; yds; distance","UCUM","Len","Clinical","standard unit used in the US and internationally","[ft_i]","[FT_I]","3",3,false],[false,"mile","[mi_i]","[MI_I]","length",1609.344,[1,0,0,0,0,0,0],"mi","intcust",false,null,null,1,false,false,0,0,"international miles; mi I; statute mile","UCUM","Len","Clinical","standard unit used in the US and internationally","[ft_i]","[FT_I]","5280",5280,false],[false,"fathom","[fth_i]","[FTH_I]","depth of water",1.8288000000000002,[1,0,0,0,0,0,0],"fth","intcust",false,null,null,1,false,false,0,0,"international fathoms","UCUM","Len","Nonclinical","unit used in the US and internationally to measure depth of water; same length as the US fathom","[ft_i]","[FT_I]","6",6,false],[false,"nautical mile","[nmi_i]","[NMI_I]","length",1852,[1,0,0,0,0,0,0],"n.mi","intcust",false,null,null,1,false,false,0,0,"nautical mile; nautical miles; international nautical mile; international nautical miles; nm; n.m.; nmi","UCUM","Len","Nonclinical","standard unit used in the US and internationally","m","M","1852",1852,false],[false,"knot","[kn_i]","[KN_I]","velocity",0.5144444444444445,[1,-1,0,0,0,0,0],"knot","intcust",false,null,null,1,false,false,0,0,"kn; kt; international knots","UCUM","Vel","Nonclinical","defined as equal to one nautical mile (1.852 km) per hour","[nmi_i]/h","[NMI_I]/H","1",1,false],[false,"square inch","[sin_i]","[SIN_I]","area",0.0006451600000000001,[2,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"in2; in^2; inches squared; sq inch; inches squared; international","UCUM","Area","Clinical","standard unit used in the US and internationally","[in_i]2","[IN_I]2","1",1,false],[false,"square foot","[sft_i]","[SFT_I]","area",0.09290304,[2,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"ft2; ft^2; ft squared; sq ft; feet; international","UCUM","Area","Clinical","standard unit used in the US and internationally","[ft_i]2","[FT_I]2","1",1,false],[false,"square yard","[syd_i]","[SYD_I]","area",0.8361273600000002,[2,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"yd2; yd^2; sq. yds; yards squared; international","UCUM","Area","Clinical","standard unit used in the US and internationally","[yd_i]2","[YD_I]2","1",1,false],[false,"cubic inch","[cin_i]","[CIN_I]","volume",0.000016387064000000006,[3,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"in3; in^3; in*3; inches^3; inches*3; cu. in; cu in; cubic inches; inches cubed; cin","UCUM","Vol","Clinical","standard unit used in the US and internationally","[in_i]3","[IN_I]3","1",1,false],[false,"cubic foot","[cft_i]","[CFT_I]","volume",0.028316846592000004,[3,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"ft3; ft^3; ft*3; cu. ft; cubic feet; cubed; [ft_i]3; international","UCUM","Vol","Clinical","","[ft_i]3","[FT_I]3","1",1,false],[false,"cubic yard","[cyd_i]","[CYD_I]","volume",0.7645548579840002,[3,0,0,0,0,0,0],"cu.yd","intcust",false,null,null,1,false,false,0,0,"cubic yards; cubic yds; cu yards; CYs; yards^3; yd^3; yds^3; yd3; yds3","UCUM","Vol","Nonclinical","standard unit used in the US and internationally","[yd_i]3","[YD_I]3","1",1,false],[false,"board foot","[bf_i]","[BF_I]","volume",0.0023597372160000006,[3,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"BDFT; FBM; BF; board feet; international","UCUM","Vol","Nonclinical","unit of volume used to measure lumber","[in_i]3","[IN_I]3","144",144,false],[false,"cord","[cr_i]","[CR_I]","volume",3.6245563637760005,[3,0,0,0,0,0,0],null,"intcust",false,null,null,1,false,false,0,0,"crd I; international cords","UCUM","Vol","Nonclinical","unit of measure of dry volume used to measure firewood equal 128 ft3","[ft_i]3","[FT_I]3","128",128,false],[false,"mil","[mil_i]","[MIL_I]","length",0.000025400000000000004,[1,0,0,0,0,0,0],"mil","intcust",false,null,null,1,false,false,0,0,"thou, thousandth; mils; international","UCUM","Len","Clinical","equal to 0.001 international inch","[in_i]","[IN_I]","1e-3",0.001,false],[false,"circular mil","[cml_i]","[CML_I]","area",5.067074790974979e-10,[2,0,0,0,0,0,0],"circ.mil","intcust",false,null,null,1,false,false,0,0,"circular mils; cml I; international","UCUM","Area","Clinical","","[pi]/4.[mil_i]2","[PI]/4.[MIL_I]2","1",1,false],[false,"hand","[hd_i]","[HD_I]","height of horses",0.10160000000000001,[1,0,0,0,0,0,0],"hd","intcust",false,null,null,1,false,false,0,0,"hands; international","UCUM","Len","Nonclinical","used to measure horse height","[in_i]","[IN_I]","4",4,false],[false,"foot - US","[ft_us]","[FT_US]","length",0.3048006096012192,[1,0,0,0,0,0,0],"ftus","us-lengths",false,null,null,1,false,false,0,0,"US foot; foot US; us ft; ft us; height; visual distance; feet","UCUM","Len","Obsolete","Better to use [ft_i] which refers to the length used worldwide, including in the US; [ft_us] may be confused with land survey units. ","m/3937","M/3937","1200",1200,false],[false,"yard - US","[yd_us]","[YD_US]","length",0.9144018288036575,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"US yards; us yds; distance","UCUM","Len; Nrat","Obsolete","Better to use [yd_i] which refers to the length used worldwide, including in the US; [yd_us] refers to unit used in land surveys in the US","[ft_us]","[FT_US]","3",3,false],[false,"inch - US","[in_us]","[IN_US]","length",0.0254000508001016,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"US inches; in us; us in; inch US","UCUM","Len","Obsolete","Better to use [in_i] which refers to the length used worldwide, including in the US","[ft_us]/12","[FT_US]/12","1",1,false],[false,"rod - US","[rd_us]","[RD_US]","length",5.029210058420117,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"US rod; US rods; rd US; US rd","UCUM","Len","Obsolete","","[ft_us]","[FT_US]","16.5",16.5,false],[false,"Gunter's chain - US","[ch_us]","[CH_US]","length",20.116840233680467,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"surveyor's chain; Surveyor's chain USA; Gunter’s measurement; surveyor’s measurement; Gunter's Chain USA","UCUM","Len","Obsolete","historical unit used for land survey used only in the US","[rd_us]","[RD_US]","4",4,false],[false,"link for Gunter's chain - US","[lk_us]","[LK_US]","length",0.20116840233680466,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"Links for Gunter's Chain USA","UCUM","Len","Obsolete","","[ch_us]/100","[CH_US]/100","1",1,false],[false,"Ramden's chain - US","[rch_us]","[RCH_US]","length",30.480060960121918,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"Ramsden's chain; engineer's chains","UCUM","Len","Obsolete","distance measuring device used for land survey","[ft_us]","[FT_US]","100",100,false],[false,"link for Ramden's chain - US","[rlk_us]","[RLK_US]","length",0.3048006096012192,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"links for Ramsden's chain","UCUM","Len","Obsolete","","[rch_us]/100","[RCH_US]/100","1",1,false],[false,"fathom - US","[fth_us]","[FTH_US]","length",1.828803657607315,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"US fathoms; fathom USA; fth us","UCUM","Len","Obsolete","same length as the international fathom - better to use international fathom ([fth_i])","[ft_us]","[FT_US]","6",6,false],[false,"furlong - US","[fur_us]","[FUR_US]","length",201.16840233680466,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"US furlongs; fur us","UCUM","Len","Nonclinical","distance unit in horse racing","[rd_us]","[RD_US]","40",40,false],[false,"mile - US","[mi_us]","[MI_US]","length",1609.3472186944373,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"U.S. Survey Miles; US statute miles; survey mi; US mi; distance","UCUM","Len","Nonclinical","Better to use [mi_i] which refers to the length used worldwide, including in the US","[fur_us]","[FUR_US]","8",8,false],[false,"acre - US","[acr_us]","[ACR_US]","area",4046.872609874252,[2,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"Acre USA Survey; Acre USA; survey acres","UCUM","Area","Nonclinical","an older unit based on pre 1959 US statute lengths that is still sometimes used in the US only for land survey purposes. ","[rd_us]2","[RD_US]2","160",160,false],[false,"square rod - US","[srd_us]","[SRD_US]","area",25.292953811714074,[2,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"rod2; rod^2; sq. rod; rods squared","UCUM","Area","Nonclinical","Used only in the US to measure land area, based on US statute land survey length units","[rd_us]2","[RD_US]2","1",1,false],[false,"square mile - US","[smi_us]","[SMI_US]","area",2589998.470319521,[2,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"mi2; mi^2; sq mi; miles squared","UCUM","Area","Nonclinical","historical unit used only in the US for land survey purposes (based on the US survey mile), not the internationally recognized [mi_i]","[mi_us]2","[MI_US]2","1",1,false],[false,"section","[sct]","[SCT]","area",2589998.470319521,[2,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"sct; sections","UCUM","Area","Nonclinical","tract of land approximately equal to 1 mile square containing 640 acres","[mi_us]2","[MI_US]2","1",1,false],[false,"township","[twp]","[TWP]","area",93239944.93150276,[2,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"twp; townships","UCUM","Area","Nonclinical","land measurement equal to 6 mile square","[sct]","[SCT]","36",36,false],[false,"mil - US","[mil_us]","[MIL_US]","length",0.0000254000508001016,[1,0,0,0,0,0,0],null,"us-lengths",false,null,null,1,false,false,0,0,"thou, thousandth; mils","UCUM","Len","Obsolete","better to use [mil_i] which is based on the internationally recognized inch","[in_us]","[IN_US]","1e-3",0.001,false],[false,"inch - British","[in_br]","[IN_BR]","length",0.025399980000000003,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"imperial inches; imp in; br in; british inches","UCUM","Len","Obsolete","","cm","CM","2.539998",2.539998,false],[false,"foot - British","[ft_br]","[FT_BR]","length",0.30479976000000003,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British Foot; Imperial Foot; feet; imp fts; br fts","UCUM","Len","Obsolete","","[in_br]","[IN_BR]","12",12,false],[false,"rod - British","[rd_br]","[RD_BR]","length",5.02919604,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British rods; br rd","UCUM","Len","Obsolete","","[ft_br]","[FT_BR]","16.5",16.5,false],[false,"Gunter's chain - British","[ch_br]","[CH_BR]","length",20.11678416,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"Gunter's Chain British; Gunters Chain British; Surveyor's Chain British","UCUM","Len","Obsolete","historical unit used for land survey used only in Great Britain","[rd_br]","[RD_BR]","4",4,false],[false,"link for Gunter's chain - British","[lk_br]","[LK_BR]","length",0.2011678416,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"Links for Gunter's Chain British","UCUM","Len","Obsolete","","[ch_br]/100","[CH_BR]/100","1",1,false],[false,"fathom - British","[fth_br]","[FTH_BR]","length",1.82879856,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British fathoms; imperial fathoms; br fth; imp fth","UCUM","Len","Obsolete","","[ft_br]","[FT_BR]","6",6,false],[false,"pace - British","[pc_br]","[PC_BR]","length",0.7619994000000001,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British paces; br pc","UCUM","Len","Nonclinical","traditional unit of length equal to 152.4 centimeters, or 1.52 meter. ","[ft_br]","[FT_BR]","2.5",2.5,false],[false,"yard - British","[yd_br]","[YD_BR]","length",0.91439928,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British yards; Br yds; distance","UCUM","Len","Obsolete","","[ft_br]","[FT_BR]","3",3,false],[false,"mile - British","[mi_br]","[MI_BR]","length",1609.3427328000002,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"imperial miles; British miles; English statute miles; imp mi, br mi","UCUM","Len","Obsolete","","[ft_br]","[FT_BR]","5280",5280,false],[false,"nautical mile - British","[nmi_br]","[NMI_BR]","length",1853.1825408000002,[1,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British nautical miles; Imperial nautical miles; Admiralty miles; n.m. br; imp nm","UCUM","Len","Obsolete","","[ft_br]","[FT_BR]","6080",6080,false],[false,"knot - British","[kn_br]","[KN_BR]","velocity",0.5147729280000001,[1,-1,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"British knots; kn br; kt","UCUM","Vel","Obsolete","based on obsolete British nautical mile ","[nmi_br]/h","[NMI_BR]/H","1",1,false],[false,"acre","[acr_br]","[ACR_BR]","area",4046.850049400269,[2,0,0,0,0,0,0],null,"brit-length",false,null,null,1,false,false,0,0,"Imperial acres; British; a; ac; ar; acr","UCUM","Area","Nonclinical","the standard unit for acre used in the US and internationally","[yd_br]2","[YD_BR]2","4840",4840,false],[false,"gallon - US","[gal_us]","[GAL_US]","fluid volume",0.0037854117840000014,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US gallons; US liquid gallon; gal us; Queen Anne's wine gallon","UCUM","Vol","Nonclinical","only gallon unit used in the US; [gal_us] is only used in some other countries in South American and Africa to measure gasoline volume","[in_i]3","[IN_I]3","231",231,false],[false,"barrel - US","[bbl_us]","[BBL_US]","fluid volume",0.15898729492800007,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"bbl","UCUM","Vol","Nonclinical","[bbl_us] is the standard unit for oil barrel, which is a unit only used in the US to measure the volume oil. ","[gal_us]","[GAL_US]","42",42,false],[false,"quart - US","[qt_us]","[QT_US]","fluid volume",0.0009463529460000004,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US quarts; us qts","UCUM","Vol","Clinical","Used only in the US","[gal_us]/4","[GAL_US]/4","1",1,false],[false,"pint - US","[pt_us]","[PT_US]","fluid volume",0.0004731764730000002,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US pints; pint US; liquid pint; pt us; us pt","UCUM","Vol","Clinical","Used only in the US","[qt_us]/2","[QT_US]/2","1",1,false],[false,"gill - US","[gil_us]","[GIL_US]","fluid volume",0.00011829411825000005,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US gills; gil us","UCUM","Vol","Nonclinical","only used in the context of alcohol volume in the US","[pt_us]/4","[PT_US]/4","1",1,false],[false,"fluid ounce - US","[foz_us]","[FOZ_US]","fluid volume",0.00002957352956250001,[3,0,0,0,0,0,0],"oz fl","us-volumes",false,null,null,1,false,false,0,0,"US fluid ounces; fl ozs; FO; fl. oz.; foz us","UCUM","Vol","Clinical","unit used only in the US","[gil_us]/4","[GIL_US]/4","1",1,false],[false,"fluid dram - US","[fdr_us]","[FDR_US]","fluid volume",0.0000036966911953125014,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US fluid drams; fdr us","UCUM","Vol","Nonclinical","equal to 1/8 US fluid ounce = 3.69 mL; used informally to mean small amount of liquor, especially Scotch whiskey","[foz_us]/8","[FOZ_US]/8","1",1,false],[false,"minim - US","[min_us]","[MIN_US]","fluid volume",6.161151992187503e-8,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"min US; US min; ♏ US","UCUM","Vol","Obsolete","","[fdr_us]/60","[FDR_US]/60","1",1,false],[false,"cord - US","[crd_us]","[CRD_US]","fluid volume",3.6245563637760005,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US cord; US cords; crd us; us crd","UCUM","Vol","Nonclinical","unit of measure of dry volume used to measure firewood equal 128 ft3 (the same as international cord [cr_i])","[ft_i]3","[FT_I]3","128",128,false],[false,"bushel - US","[bu_us]","[BU_US]","dry volume",0.035239070166880014,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US bushels; US bsh; US bu","UCUM","Vol","Obsolete","Historical unit of dry volume that is rarely used today","[in_i]3","[IN_I]3","2150.42",2150.42,false],[false,"gallon - historical","[gal_wi]","[GAL_WI]","dry volume",0.004404883770860002,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"Corn Gallon British; Dry Gallon US; Gallons Historical; Grain Gallon British; Winchester Corn Gallon; historical winchester gallons; wi gal","UCUM","Vol","Obsolete","historical unit of dry volume no longer used","[bu_us]/8","[BU_US]/8","1",1,false],[false,"peck - US","[pk_us]","[PK_US]","dry volume",0.008809767541720004,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"US pecks; US pk","UCUM","Vol","Nonclinical","unit of dry volume rarely used today (can be used to measure volume of apples)","[bu_us]/4","[BU_US]/4","1",1,false],[false,"dry quart - US","[dqt_us]","[DQT_US]","dry volume",0.0011012209427150004,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"dry quarts; dry quart US; US dry quart; dry qt; us dry qt; dqt; dqt us","UCUM","Vol","Nonclinical","historical unit of dry volume only in the US, but is rarely used today","[pk_us]/8","[PK_US]/8","1",1,false],[false,"dry pint - US","[dpt_us]","[DPT_US]","dry volume",0.0005506104713575002,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"dry pints; dry pint US; US dry pint; dry pt; dpt; dpt us","UCUM","Vol","Nonclinical","historical unit of dry volume only in the US, but is rarely used today","[dqt_us]/2","[DQT_US]/2","1",1,false],[false,"tablespoon - US","[tbs_us]","[TBS_US]","volume",0.000014786764781250006,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"Tbs; tbsp; tbs us; US tablespoons","UCUM","Vol","Clinical","unit defined as 0.5 US fluid ounces or 3 teaspoons - used only in the US. See [tbs_m] for the unit used internationally and in the US for nutrional labelling. ","[foz_us]/2","[FOZ_US]/2","1",1,false],[false,"teaspoon - US","[tsp_us]","[TSP_US]","volume",0.000004928921593750002,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"tsp; t; US teaspoons","UCUM","Vol","Nonclinical","unit defined as 1/6 US fluid ounces - used only in the US. See [tsp_m] for the unit used internationally and in the US for nutrional labelling. ","[tbs_us]/3","[TBS_US]/3","1",1,false],[false,"cup - US customary","[cup_us]","[CUP_US]","volume",0.0002365882365000001,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"cup us; us cups","UCUM","Vol","Nonclinical","Unit defined as 1/2 US pint or 16 US tablespoons ≈ 236.59 mL, which is not the standard unit defined by the FDA of 240 mL - see [cup_m] (metric cup)","[tbs_us]","[TBS_US]","16",16,false],[false,"fluid ounce - metric","[foz_m]","[FOZ_M]","fluid volume",0.000029999999999999997,[3,0,0,0,0,0,0],"oz fl","us-volumes",false,null,null,1,false,false,0,0,"metric fluid ounces; fozs m; fl ozs m","UCUM","Vol","Clinical","unit used only in the US for nutritional labelling, as set by the FDA","mL","ML","30",30,false],[false,"cup - US legal","[cup_m]","[CUP_M]","volume",0.00023999999999999998,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"cup m; metric cups","UCUM","Vol","Clinical","standard unit equal to 240 mL used in the US for nutritional labelling, as defined by the FDA. Note that this is different from the US customary cup (236.59 mL) and the metric cup used in Commonwealth nations (250 mL).","mL","ML","240",240,false],[false,"teaspoon - metric","[tsp_m]","[TSP_M]","volume",0.0000049999999999999996,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"tsp; t; metric teaspoons","UCUM","Vol","Clinical","standard unit used in the US and internationally","mL","mL","5",5,false],[false,"tablespoon - metric","[tbs_m]","[TBS_M]","volume",0.000014999999999999999,[3,0,0,0,0,0,0],null,"us-volumes",false,null,null,1,false,false,0,0,"metric tablespoons; Tbs; tbsp; T; tbs m","UCUM","Vol","Clinical","standard unit used in the US and internationally","mL","mL","15",15,false],[false,"gallon- British","[gal_br]","[GAL_BR]","volume",0.004546090000000001,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"imperial gallons, UK gallons; British gallons; br gal; imp gal","UCUM","Vol","Nonclinical","Used only in Great Britain and other Commonwealth countries","l","L","4.54609",4.54609,false],[false,"peck - British","[pk_br]","[PK_BR]","volume",0.009092180000000002,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"imperial pecks; British pecks; br pk; imp pk","UCUM","Vol","Nonclinical","unit of dry volume rarely used today (can be used to measure volume of apples)","[gal_br]","[GAL_BR]","2",2,false],[false,"bushel - British","[bu_br]","[BU_BR]","volume",0.03636872000000001,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"British bushels; imperial; br bsh; br bu; imp","UCUM","Vol","Obsolete","Historical unit of dry volume that is rarely used today","[pk_br]","[PK_BR]","4",4,false],[false,"quart - British","[qt_br]","[QT_BR]","volume",0.0011365225000000002,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"British quarts; imperial quarts; br qts","UCUM","Vol","Clinical","Used only in Great Britain and other Commonwealth countries","[gal_br]/4","[GAL_BR]/4","1",1,false],[false,"pint - British","[pt_br]","[PT_BR]","volume",0.0005682612500000001,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"British pints; imperial pints; pt br; br pt; imp pt; pt imp","UCUM","Vol","Clinical","Used only in Great Britain and other Commonwealth countries","[qt_br]/2","[QT_BR]/2","1",1,false],[false,"gill - British","[gil_br]","[GIL_BR]","volume",0.00014206531250000003,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"imperial gills; British gills; imp gill, br gill","UCUM","Vol","Nonclinical","only used in the context of alcohol volume in Great Britain","[pt_br]/4","[PT_BR]/4","1",1,false],[false,"fluid ounce - British","[foz_br]","[FOZ_BR]","volume",0.000028413062500000005,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"British fluid ounces; Imperial fluid ounces; br fozs; imp fozs; br fl ozs","UCUM","Vol","Clinical","Used only in Great Britain and other Commonwealth countries","[gil_br]/5","[GIL_BR]/5","1",1,false],[false,"fluid dram - British","[fdr_br]","[FDR_BR]","volume",0.0000035516328125000006,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"British fluid drams; fdr br","UCUM","Vol","Nonclinical","equal to 1/8 Imperial fluid ounce = 3.55 mL; used informally to mean small amount of liquor, especially Scotch whiskey","[foz_br]/8","[FOZ_BR]/8","1",1,false],[false,"minim - British","[min_br]","[MIN_BR]","volume",5.919388020833334e-8,[3,0,0,0,0,0,0],null,"brit-volumes",false,null,null,1,false,false,0,0,"min br; br min; ♏ br","UCUM","Vol","Obsolete","","[fdr_br]/60","[FDR_BR]/60","1",1,false],[false,"grain","[gr]","[GR]","mass",0.06479891,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"gr; grains","UCUM","Mass","Nonclinical","an apothecary measure of mass rarely used today","mg","MG","64.79891",64.79891,false],[false,"pound","[lb_av]","[LB_AV]","mass",453.59237,[0,0,1,0,0,0,0],"lb","avoirdupois",false,null,null,1,false,false,0,0,"avoirdupois pounds, international pounds; av lbs; pounds","UCUM","Mass","Clinical","standard unit used in the US and internationally","[gr]","[GR]","7000",7000,false],[false,"pound force - US","[lbf_av]","[LBF_AV]","force",4448.2216152605,[1,-2,1,0,0,0,0],"lbf","const",false,null,null,1,false,false,0,0,"lbfs; US lbf; US pound forces","UCUM","Force","Clinical","only rarely needed in health care - see [lb_av] which is the more common unit to express weight","[lb_av].[g]","[LB_AV].[G]","1",1,false],[false,"ounce","[oz_av]","[OZ_AV]","mass",28.349523125,[0,0,1,0,0,0,0],"oz","avoirdupois",false,null,null,1,false,false,0,0,"ounces; international ounces; avoirdupois ounces; av ozs","UCUM","Mass","Clinical","standard unit used in the US and internationally","[lb_av]/16","[LB_AV]/16","1",1,false],[false,"Dram mass unit","[dr_av]","[DR_AV]","mass",1.7718451953125,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"Dram; drams avoirdupois; avoidupois dram; international dram","UCUM","Mass","Clinical","unit from the avoirdupois system, which is used in the US and internationally","[oz_av]/16","[OZ_AV]/16","1",1,false],[false,"short hundredweight","[scwt_av]","[SCWT_AV]","mass",45359.237,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"hundredweights; s cwt; scwt; avoirdupois","UCUM","Mass","Nonclinical","Used only in the US to equal 100 pounds","[lb_av]","[LB_AV]","100",100,false],[false,"long hundredweight","[lcwt_av]","[LCWT_AV]","mass",50802.345440000005,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"imperial hundredweights; imp cwt; lcwt; avoirdupois","UCUM","Mass","Obsolete","","[lb_av]","[LB_AV]","112",112,false],[false,"short ton - US","[ston_av]","[STON_AV]","mass",907184.74,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"ton; US tons; avoirdupois tons","UCUM","Mass","Clinical","Used only in the US","[scwt_av]","[SCWT_AV]","20",20,false],[false,"long ton - British","[lton_av]","[LTON_AV]","mass",1016046.9088000001,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"imperial tons; weight tons; British long tons; long ton avoirdupois","UCUM","Mass","Nonclinical","Used only in Great Britain and other Commonwealth countries","[lcwt_av]","[LCWT_AV]","20",20,false],[false,"stone - British","[stone_av]","[STONE_AV]","mass",6350.293180000001,[0,0,1,0,0,0,0],null,"avoirdupois",false,null,null,1,false,false,0,0,"British stones; avoirdupois","UCUM","Mass","Nonclinical","Used primarily in the UK and Ireland to measure body weight","[lb_av]","[LB_AV]","14",14,false],[false,"pennyweight - troy","[pwt_tr]","[PWT_TR]","mass",1.5551738400000001,[0,0,1,0,0,0,0],null,"troy",false,null,null,1,false,false,0,0,"dwt; denarius weights","UCUM","Mass","Obsolete","historical unit used to measure mass and cost of precious metals","[gr]","[GR]","24",24,false],[false,"ounce - troy","[oz_tr]","[OZ_TR]","mass",31.103476800000003,[0,0,1,0,0,0,0],null,"troy",false,null,null,1,false,false,0,0,"troy ounces; tr ozs","UCUM","Mass","Nonclinical","unit of mass for precious metals and gemstones only","[pwt_tr]","[PWT_TR]","20",20,false],[false,"pound - troy","[lb_tr]","[LB_TR]","mass",373.2417216,[0,0,1,0,0,0,0],null,"troy",false,null,null,1,false,false,0,0,"troy pounds; tr lbs","UCUM","Mass","Nonclinical","only used for weighing precious metals","[oz_tr]","[OZ_TR]","12",12,false],[false,"scruple","[sc_ap]","[SC_AP]","mass",1.2959782,[0,0,1,0,0,0,0],null,"apoth",false,null,null,1,false,false,0,0,"scruples; sc ap","UCUM","Mass","Obsolete","","[gr]","[GR]","20",20,false],[false,"dram - apothecary","[dr_ap]","[DR_AP]","mass",3.8879346,[0,0,1,0,0,0,0],null,"apoth",false,null,null,1,false,false,0,0,"ʒ; drachm; apothecaries drams; dr ap; dram ap","UCUM","Mass","Nonclinical","unit still used in the US occasionally to measure amount of drugs in pharmacies","[sc_ap]","[SC_AP]","3",3,false],[false,"ounce - apothecary","[oz_ap]","[OZ_AP]","mass",31.1034768,[0,0,1,0,0,0,0],null,"apoth",false,null,null,1,false,false,0,0,"apothecary ounces; oz ap; ap ozs; ozs ap","UCUM","Mass","Obsolete","","[dr_ap]","[DR_AP]","8",8,false],[false,"pound - apothecary","[lb_ap]","[LB_AP]","mass",373.2417216,[0,0,1,0,0,0,0],null,"apoth",false,null,null,1,false,false,0,0,"apothecary pounds; apothecaries pounds; ap lb; lb ap; ap lbs; lbs ap","UCUM","Mass","Obsolete","","[oz_ap]","[OZ_AP]","12",12,false],[false,"ounce - metric","[oz_m]","[OZ_M]","mass",28,[0,0,1,0,0,0,0],null,"apoth",false,null,null,1,false,false,0,0,"metric ounces; m ozs","UCUM","Mass","Clinical","see [oz_av] (the avoirdupois ounce) for the standard ounce used internationally; [oz_m] is equal to 28 grams and is based on the apothecaries' system of mass units which is used in some US pharmacies. ","g","g","28",28,false],[false,"line","[lne]","[LNE]","length",0.002116666666666667,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"British lines; br L; L; l","UCUM","Len","Obsolete","","[in_i]/12","[IN_I]/12","1",1,false],[false,"point (typography)","[pnt]","[PNT]","length",0.0003527777777777778,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"DTP points; desktop publishing point; pt; pnt","UCUM","Len","Nonclinical","typography unit for typesetter's length","[lne]/6","[LNE]/6","1",1,false],[false,"pica (typography)","[pca]","[PCA]","length",0.004233333333333334,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"picas","UCUM","Len","Nonclinical","typography unit for typesetter's length","[pnt]","[PNT]","12",12,false],[false,"Printer's point (typography)","[pnt_pr]","[PNT_PR]","length",0.00035145980000000004,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"pnt pr","UCUM","Len","Nonclinical","typography unit for typesetter's length","[in_i]","[IN_I]","0.013837",0.013837,false],[false,"Printer's pica (typography)","[pca_pr]","[PCA_PR]","length",0.004217517600000001,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"pca pr; Printer's picas","UCUM","Len","Nonclinical","typography unit for typesetter's length","[pnt_pr]","[PNT_PR]","12",12,false],[false,"pied","[pied]","[PIED]","length",0.3248,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"pieds du roi; Paris foot; royal; French; feet","UCUM","Len","Obsolete","","cm","CM","32.48",32.48,false],[false,"pouce","[pouce]","[POUCE]","length",0.027066666666666666,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"historical French inches; French royal inches","UCUM","Len","Obsolete","","[pied]/12","[PIED]/12","1",1,false],[false,"ligne","[ligne]","[LIGNE]","length",0.0022555555555555554,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"Paris lines; lignes","UCUM","Len","Obsolete","","[pouce]/12","[POUCE]/12","1",1,false],[false,"didot","[didot]","[DIDOT]","length",0.0003759259259259259,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"Didot point; dd; Didots Point; didots; points","UCUM","Len","Obsolete","typography unit for typesetter's length","[ligne]/6","[LIGNE]/6","1",1,false],[false,"cicero","[cicero]","[CICERO]","length",0.004511111111111111,[1,0,0,0,0,0,0],null,"typeset",false,null,null,1,false,false,0,0,"Didot's pica; ciceros; picas","UCUM","Len","Obsolete","typography unit for typesetter's length","[didot]","[DIDOT]","12",12,false],[false,"degrees Fahrenheit","[degF]","[DEGF]","temperature",0.5555555555555556,[0,0,0,0,1,0,0],"°F","heat",false,null,"degF",1,true,false,0,0,"°F; deg F","UCUM","Temp","Clinical","","K",null,null,0.5555555555555556,false],[false,"degrees Rankine","[degR]","[degR]","temperature",0.5555555555555556,[0,0,0,0,1,0,0],"°R","heat",false,null,null,1,false,false,0,0,"°R; °Ra; Rankine","UCUM","Temp","Obsolete","Replaced by Kelvin","K/9","K/9","5",5,false],[false,"degrees Réaumur","[degRe]","[degRe]","temperature",1.25,[0,0,0,0,1,0,0],"°Ré","heat",false,null,"degRe",1,true,false,0,0,"°Ré, °Re, °r; Réaumur; degree Reaumur; Reaumur","UCUM","Temp","Obsolete","replaced by Celsius","K",null,null,1.25,false],[false,"calorie at 15°C","cal_[15]","CAL_[15]","energy",4185.8,[2,-2,1,0,0,0,0],"cal15°C","heat",true,null,null,1,false,false,0,0,"calorie 15 C; cals 15 C; calories at 15 C","UCUM","Enrg","Nonclinical","equal to 4.1855 joules; calorie most often used in engineering","J","J","4.18580",4.1858,false],[false,"calorie at 20°C","cal_[20]","CAL_[20]","energy",4181.9,[2,-2,1,0,0,0,0],"cal20°C","heat",true,null,null,1,false,false,0,0,"calorie 20 C; cal 20 C; calories at 20 C","UCUM","Enrg","Clinical","equal to 4.18190 joules. ","J","J","4.18190",4.1819,false],[false,"mean calorie","cal_m","CAL_M","energy",4190.0199999999995,[2,-2,1,0,0,0,0],"calm","heat",true,null,null,1,false,false,0,0,"mean cals; mean calories","UCUM","Enrg","Clinical","equal to 4.19002 joules. ","J","J","4.19002",4.19002,false],[false,"international table calorie","cal_IT","CAL_IT","energy",4186.8,[2,-2,1,0,0,0,0],"calIT","heat",true,null,null,1,false,false,0,0,"calories IT; IT cals; international steam table calories","UCUM","Enrg","Nonclinical","used in engineering steam tables and defined as 1/860 international watt-hour; equal to 4.1868 joules","J","J","4.1868",4.1868,false],[false,"thermochemical calorie","cal_th","CAL_TH","energy",4184,[2,-2,1,0,0,0,0],"calth","heat",true,null,null,1,false,false,0,0,"thermochemical calories; th cals","UCUM","Enrg","Clinical","equal to 4.184 joules; used as the unit in medicine and biochemistry (equal to cal)","J","J","4.184",4.184,false],[false,"calorie","cal","CAL","energy",4184,[2,-2,1,0,0,0,0],"cal","heat",true,null,null,1,false,false,0,0,"gram calories; small calories","UCUM","Enrg","Clinical","equal to 4.184 joules (the same value as the thermochemical calorie, which is the most common calorie used in medicine and biochemistry)","cal_th","CAL_TH","1",1,false],[false,"nutrition label Calories","[Cal]","[CAL]","energy",4184000,[2,-2,1,0,0,0,0],"Cal","heat",false,null,null,1,false,false,0,0,"food calories; Cal; kcal","UCUM","Eng","Clinical","","kcal_th","KCAL_TH","1",1,false],[false,"British thermal unit at 39°F","[Btu_39]","[BTU_39]","energy",1059670,[2,-2,1,0,0,0,0],"Btu39°F","heat",false,null,null,1,false,false,0,0,"BTU 39F; BTU 39 F; B.T.U. 39 F; B.Th.U. 39 F; BThU 39 F; British thermal units","UCUM","Eng","Nonclinical","equal to 1.05967 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","kJ","kJ","1.05967",1.05967,false],[false,"British thermal unit at 59°F","[Btu_59]","[BTU_59]","energy",1054800,[2,-2,1,0,0,0,0],"Btu59°F","heat",false,null,null,1,false,false,0,0,"BTU 59 F; BTU 59F; B.T.U. 59 F; B.Th.U. 59 F; BThU 59F; British thermal units","UCUM","Eng","Nonclinical","equal to 1.05480 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","kJ","kJ","1.05480",1.0548,false],[false,"British thermal unit at 60°F","[Btu_60]","[BTU_60]","energy",1054680,[2,-2,1,0,0,0,0],"Btu60°F","heat",false,null,null,1,false,false,0,0,"BTU 60 F; BTU 60F; B.T.U. 60 F; B.Th.U. 60 F; BThU 60 F; British thermal units 60 F","UCUM","Eng","Nonclinical","equal to 1.05468 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","kJ","kJ","1.05468",1.05468,false],[false,"mean British thermal unit","[Btu_m]","[BTU_M]","energy",1055870,[2,-2,1,0,0,0,0],"Btum","heat",false,null,null,1,false,false,0,0,"BTU mean; B.T.U. mean; B.Th.U. mean; BThU mean; British thermal units mean; ","UCUM","Eng","Nonclinical","equal to 1.05587 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","kJ","kJ","1.05587",1.05587,false],[false,"international table British thermal unit","[Btu_IT]","[BTU_IT]","energy",1055055.85262,[2,-2,1,0,0,0,0],"BtuIT","heat",false,null,null,1,false,false,0,0,"BTU IT; B.T.U. IT; B.Th.U. IT; BThU IT; British thermal units IT","UCUM","Eng","Nonclinical","equal to 1.055 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","kJ","kJ","1.05505585262",1.05505585262,false],[false,"thermochemical British thermal unit","[Btu_th]","[BTU_TH]","energy",1054350,[2,-2,1,0,0,0,0],"Btuth","heat",false,null,null,1,false,false,0,0,"BTU Th; B.T.U. Th; B.Th.U. Th; BThU Th; thermochemical British thermal units","UCUM","Eng","Nonclinical","equal to 1.054350 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","kJ","kJ","1.054350",1.05435,false],[false,"British thermal unit","[Btu]","[BTU]","energy",1054350,[2,-2,1,0,0,0,0],"btu","heat",false,null,null,1,false,false,0,0,"BTU; B.T.U. ; B.Th.U.; BThU; British thermal units","UCUM","Eng","Nonclinical","equal to the thermochemical British thermal unit equal to 1.054350 kJ; used as a measure of power in the electric power, steam generation, heating, and air conditioning industries","[Btu_th]","[BTU_TH]","1",1,false],[false,"horsepower - mechanical","[HP]","[HP]","power",745699.8715822703,[2,-3,1,0,0,0,0],null,"heat",false,null,null,1,false,false,0,0,"imperial horsepowers","UCUM","EngRat","Nonclinical","refers to mechanical horsepower, which is unit used to measure engine power primarily in the US. ","[ft_i].[lbf_av]/s","[FT_I].[LBF_AV]/S","550",550,false],[false,"tex","tex","TEX","linear mass density (of textile thread)",0.001,[-1,0,1,0,0,0,0],"tex","heat",true,null,null,1,false,false,0,0,"linear mass density; texes","UCUM","","Clinical","unit of linear mass density for fibers equal to gram per 1000 meters","g/km","G/KM","1",1,false],[false,"Denier (linear mass density)","[den]","[DEN]","linear mass density (of textile thread)",0.0001111111111111111,[-1,0,1,0,0,0,0],"den","heat",false,null,null,1,false,false,0,0,"den; deniers","UCUM","","Nonclinical","equal to the mass in grams per 9000 meters of the fiber (1 denier = 1 strand of silk)","g/9/km","G/9/KM","1",1,false],[false,"meter of water column","m[H2O]","M[H2O]","pressure",9806650,[-1,-2,1,0,0,0,0],"m HO2","clinical",true,null,null,1,false,false,0,0,"mH2O; m H2O; meters of water column; metres; pressure","UCUM","Pres","Clinical","","kPa","KPAL","980665e-5",9.80665,false],[false,"meter of mercury column","m[Hg]","M[HG]","pressure",133322000,[-1,-2,1,0,0,0,0],"m Hg","clinical",true,null,null,1,false,false,0,0,"mHg; m Hg; meters of mercury column; metres; pressure","UCUM","Pres","Clinical","","kPa","KPAL","133.3220",133.322,false],[false,"inch of water column","[in_i'H2O]","[IN_I'H2O]","pressure",249088.91000000003,[-1,-2,1,0,0,0,0],"in HO2","clinical",false,null,null,1,false,false,0,0,"inches WC; inAq; in H2O; inch of water gauge; iwg; pressure","UCUM","Pres","Clinical","unit of pressure, especially in respiratory and ventilation care","m[H2O].[in_i]/m","M[H2O].[IN_I]/M","1",1,false],[false,"inch of mercury column","[in_i'Hg]","[IN_I'HG]","pressure",3386378.8000000003,[-1,-2,1,0,0,0,0],"in Hg","clinical",false,null,null,1,false,false,0,0,"inHg; in Hg; pressure; inches","UCUM","Pres","Clinical","unit of pressure used in US to measure barometric pressure and occasionally blood pressure (see mm[Hg] for unit used internationally)","m[Hg].[in_i]/m","M[HG].[IN_I]/M","1",1,false],[false,"peripheral vascular resistance unit","[PRU]","[PRU]","fluid resistance",133322000000,[-4,-1,1,0,0,0,0],"P.R.U.","clinical",false,null,null,1,false,false,0,0,"peripheral vascular resistance units; peripheral resistance unit; peripheral resistance units; PRU","UCUM","FldResist","Clinical","used to assess blood flow in the capillaries; equal to 1 mmH.min/mL = 133.3 Pa·min/mL","mm[Hg].s/ml","MM[HG].S/ML","1",1,false],[false,"Wood unit","[wood'U]","[WOOD'U]","fluid resistance",7999320000,[-4,-1,1,0,0,0,0],"Wood U.","clinical",false,null,null,1,false,false,0,0,"hybrid reference units; HRU; mmHg.min/L; vascular resistance","UCUM","Pres","Clinical","simplified unit of measurement for for measuring pulmonary vascular resistance that uses pressure; equal to mmHg.min/L","mm[Hg].min/L","MM[HG].MIN/L","1",1,false],[false,"diopter (lens)","[diop]","[DIOP]","refraction of a lens",1,[1,0,0,0,0,0,0],"dpt","clinical",false,null,"inv",1,false,false,0,0,"diopters; diop; dioptre; dpt; refractive power","UCUM","InvLen","Clinical","unit of optical power of lens represented by inverse meters (m^-1)","m","/M","1",1,false],[false,"prism diopter (magnifying power)","[p'diop]","[P'DIOP]","refraction of a prism",1,[0,0,0,1,0,0,0],"PD","clinical",false,null,"tanTimes100",1,true,false,0,0,"diopters; dioptres; p diops; pdiop; dpt; pdptr; Δ; cm/m; centimeter per meter; centimetre; metre","UCUM","Angle","Clinical","unit for prism correction in eyeglass prescriptions","rad",null,null,1,false],[false,"percent of slope","%[slope]","%[SLOPE]","slope",0.017453292519943295,[0,0,0,1,0,0,0],"%","clinical",false,null,"100tan",1,true,false,0,0,"% slope; %slope; percents slopes","UCUM","VelFr; ElpotRatFr; VelRtoFr; AccelFr","Clinical","","deg",null,null,1,false],[false,"mesh","[mesh_i]","[MESH_I]","lineic number",0.025400000000000002,[1,0,0,0,0,0,0],null,"clinical",false,null,"inv",1,false,false,0,0,"meshes","UCUM","NLen (lineic number)","Clinical","traditional unit of length defined as the number of strands or particles per inch","[in_i]","/[IN_I]","1",1,false],[false,"French (catheter gauge) ","[Ch]","[CH]","gauge of catheters",0.0003333333333333333,[1,0,0,0,0,0,0],"Ch","clinical",false,null,null,1,false,false,0,0,"Charrières, French scales; French gauges; Fr, Fg, Ga, FR, Ch","UCUM","Len; Circ; Diam","Clinical","","mm/3","MM/3","1",1,false],[false,"drop - metric (1/20 mL)","[drp]","[DRP]","volume",5e-8,[3,0,0,0,0,0,0],"drp","clinical",false,null,null,1,false,false,0,0,"drop dosing units; metric drops; gtt","UCUM","Vol","Clinical","standard unit used in the US and internationally for clinical medicine but note that although [drp] is defined as 1/20 milliliter, in practice, drop sizes will vary due to external factors","ml/20","ML/20","1",1,false],[false,"Hounsfield unit","[hnsf'U]","[HNSF'U]","x-ray attenuation",1,[0,0,0,0,0,0,0],"HF","clinical",false,null,null,1,false,false,0,0,"HU; units","UCUM","","Clinical","used to measure X-ray attenuation, especially in CT scans.","1","1","1",1,false],[false,"Metabolic Equivalent of Task ","[MET]","[MET]","metabolic cost of physical activity",5.833333333333334e-11,[3,-1,-1,0,0,0,0],"MET","clinical",false,null,null,1,false,false,0,0,"metabolic equivalents","UCUM","RelEngRat","Clinical","unit used to measure rate of energy expenditure per power in treadmill and other functional tests","mL/min/kg","ML/MIN/KG","3.5",3.5,false],[false,"homeopathic potency of decimal series (retired)","[hp'_X]","[HP'_X]","homeopathic potency (retired)",1,[0,0,0,0,0,0,0],"X","clinical",false,null,"hpX",1,true,false,0,0,null,"UCUM",null,null,null,"1",null,null,1,false],[false,"homeopathic potency of centesimal series (retired)","[hp'_C]","[HP'_C]","homeopathic potency (retired)",1,[0,0,0,0,0,0,0],"C","clinical",false,null,"hpC",1,true,false,0,0,null,"UCUM",null,null,null,"1",null,null,1,false],[false,"homeopathic potency of millesimal series (retired)","[hp'_M]","[HP'_M]","homeopathic potency (retired)",1,[0,0,0,0,0,0,0],"M","clinical",false,null,"hpM",1,true,false,0,0,null,"UCUM",null,null,null,"1",null,null,1,false],[false,"homeopathic potency of quintamillesimal series (retired)","[hp'_Q]","[HP'_Q]","homeopathic potency (retired)",1,[0,0,0,0,0,0,0],"Q","clinical",false,null,"hpQ",1,true,false,0,0,null,"UCUM",null,null,null,"1",null,null,1,false],[false,"homeopathic potency of decimal hahnemannian series","[hp_X]","[HP_X]","homeopathic potency (Hahnemann)",1,[0,0,0,0,0,0,0],"X","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of centesimal hahnemannian series","[hp_C]","[HP_C]","homeopathic potency (Hahnemann)",1,[0,0,0,0,0,0,0],"C","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of millesimal hahnemannian series","[hp_M]","[HP_M]","homeopathic potency (Hahnemann)",1,[0,0,0,0,0,0,0],"M","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of quintamillesimal hahnemannian series","[hp_Q]","[HP_Q]","homeopathic potency (Hahnemann)",1,[0,0,0,0,0,0,0],"Q","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of decimal korsakovian series","[kp_X]","[KP_X]","homeopathic potency (Korsakov)",1,[0,0,0,0,0,0,0],"X","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of centesimal korsakovian series","[kp_C]","[KP_C]","homeopathic potency (Korsakov)",1,[0,0,0,0,0,0,0],"C","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of millesimal korsakovian series","[kp_M]","[KP_M]","homeopathic potency (Korsakov)",1,[0,0,0,0,0,0,0],"M","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"homeopathic potency of quintamillesimal korsakovian series","[kp_Q]","[KP_Q]","homeopathic potency (Korsakov)",1,[0,0,0,0,0,0,0],"Q","clinical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"equivalent","eq","EQ","amount of substance",6.0221367e+23,[0,0,0,0,0,0,0],"eq","chemical",true,null,null,1,false,false,0,1,"equivalents","UCUM","Sub","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"osmole","osm","OSM","amount of substance (dissolved particles)",6.0221367e+23,[0,0,0,0,0,0,0],"osm","chemical",true,null,null,1,false,false,1,0,"osmoles; osmols","UCUM","Osmol","Clinical","the number of moles of solute that contribute to the osmotic pressure of a solution","mol","MOL","1",1,false],[false,"pH","[pH]","[PH]","acidity",6.0221366999999994e+26,[-3,0,0,0,0,0,0],"pH","chemical",false,null,"pH",1,true,false,0,0,"pH scale","UCUM","LogCnc","Clinical","Log concentration of H+","mol/l",null,null,1,false],[false,"gram percent","g%","G%","mass concentration",10000,[-3,0,1,0,0,0,0],"g%","chemical",true,null,null,1,false,false,0,0,"gram %; gram%; grams per deciliter; g/dL; gm per dL; gram percents","UCUM","MCnc","Clinical","equivalent to unit gram per deciliter (g/dL), a unit often used in medical tests to represent solution concentrations","g/dl","G/DL","1",1,false],[false,"Svedberg unit","[S]","[S]","sedimentation coefficient",1e-13,[0,1,0,0,0,0,0],"S","chemical",false,null,null,1,false,false,0,0,"Sv; 10^-13 seconds; 100 fs; 100 femtoseconds","UCUM","Time","Clinical","unit of time used in measuring particle's sedimentation rate, usually after centrifugation. ","s","10*-13.S","1",1e-13,false],[false,"high power field (microscope)","[HPF]","[HPF]","view area in microscope",1,[0,0,0,0,0,0,0],"HPF","chemical",false,null,null,1,false,false,0,0,"HPF","UCUM","Area","Clinical","area visible under the maximum magnification power of the objective in microscopy (usually 400x)\n","1","1","1",1,false],[false,"low power field (microscope)","[LPF]","[LPF]","view area in microscope",1,[0,0,0,0,0,0,0],"LPF","chemical",false,null,null,1,false,false,0,0,"LPF; fields","UCUM","Area","Clinical","area visible under the low magnification of the objective in microscopy (usually 100 x)\n","1","1","100",100,false],[false,"katal","kat","KAT","catalytic activity",6.0221367e+23,[0,-1,0,0,0,0,0],"kat","chemical",true,null,null,1,false,false,1,0,"mol/secs; moles per second; mol*sec-1; mol*s-1; mol.s-1; katals; catalytic activity; enzymatic; enzyme units; activities","UCUM","CAct","Clinical","kat is a unit of catalytic activity with base units = mol/s. Rarely used because its units are too large to practically express catalytic activity. See enzyme unit [U] which is the standard unit for catalytic activity.","mol/s","MOL/S","1",1,false],[false,"enzyme unit","U","U","catalytic activity",10036894500000000,[0,-1,0,0,0,0,0],"U","chemical",true,null,null,1,false,false,1,0,"micromoles per minute; umol/min; umol per minute; umol min-1; enzymatic activity; enzyme activity","UCUM","CAct","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"international unit - arbitrary","[iU]","[IU]","arbitrary",1,[0,0,0,0,0,0,0],"IU","chemical",true,null,null,1,false,true,0,0,"international units; IE; F2","UCUM","Arb","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","1","1","1",1,false],[false,"international unit - arbitrary","[IU]","[IU]","arbitrary",1,[0,0,0,0,0,0,0],"i.U.","chemical",true,null,null,1,false,true,0,0,"international units; IE; F2","UCUM","Arb","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"arbitary unit","[arb'U]","[ARB'U]","arbitrary",1,[0,0,0,0,0,0,0],"arb. U","chemical",false,null,null,1,false,true,0,0,"arbitary units; arb units; arbU","UCUM","Arb","Clinical","relative unit of measurement to show the ratio of test measurement to reference measurement","1","1","1",1,false],[false,"United States Pharmacopeia unit","[USP'U]","[USP'U]","arbitrary",1,[0,0,0,0,0,0,0],"U.S.P.","chemical",false,null,null,1,false,true,0,0,"USP U; USP'U","UCUM","Arb","Clinical","a dose unit to express potency of drugs and vitamins defined by the United States Pharmacopoeia; usually 1 USP = 1 IU","1","1","1",1,false],[false,"GPL unit","[GPL'U]","[GPL'U]","biologic activity of anticardiolipin IgG",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"GPL Units; GPL U; IgG anticardiolipin units; IgG Phospholipid","UCUM","ACnc; AMass","Clinical","Units for an antiphospholipid test","1","1","1",1,false],[false,"MPL unit","[MPL'U]","[MPL'U]","biologic activity of anticardiolipin IgM",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"MPL units; MPL U; MPL'U; IgM anticardiolipin units; IgM Phospholipid Units ","UCUM","ACnc","Clinical","units for antiphospholipid test","1","1","1",1,false],[false,"APL unit","[APL'U]","[APL'U]","biologic activity of anticardiolipin IgA",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"APL units; APL U; IgA anticardiolipin; IgA Phospholipid; biologic activity of","UCUM","AMass; ACnc","Clinical","Units for an anti phospholipid syndrome test","1","1","1",1,false],[false,"Bethesda unit","[beth'U]","[BETH'U]","biologic activity of factor VIII inhibitor",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"BU","UCUM","ACnc","Clinical","measures of blood coagulation inhibitior for many blood factors","1","1","1",1,false],[false,"anti factor Xa unit","[anti'Xa'U]","[ANTI'XA'U]","biologic activity of factor Xa inhibitor (heparin)",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"units","UCUM","ACnc","Clinical","[anti'Xa'U] unit is equivalent to and can be converted to IU/mL. ","1","1","1",1,false],[false,"Todd unit","[todd'U]","[TODD'U]","biologic activity antistreptolysin O",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"units","UCUM","InvThres; RtoThres","Clinical","the unit for the results of the testing for antistreptolysin O (ASO)","1","1","1",1,false],[false,"Dye unit","[dye'U]","[DYE'U]","biologic activity of amylase",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"units","UCUM","CCnc","Obsolete","equivalent to the Somogyi unit, which is an enzyme unit for amylase but better to use U, the standard enzyme unit for measuring catalytic activity","1","1","1",1,false],[false,"Somogyi unit","[smgy'U]","[SMGY'U]","biologic activity of amylase",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"Somogyi units; smgy U","UCUM","CAct","Clinical","measures the enzymatic activity of amylase in blood serum - better to use base units mg/mL ","1","1","1",1,false],[false,"Bodansky unit","[bdsk'U]","[BDSK'U]","biologic activity of phosphatase",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"","UCUM","ACnc","Obsolete","Enzyme unit specific to alkaline phosphatase - better to use standard enzyme unit of U","1","1","1",1,false],[false,"King-Armstrong unit","[ka'U]","[KA'U]","biologic activity of phosphatase",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"King-Armstrong Units; King units","UCUM","AMass","Obsolete","enzyme units for acid phosphatase - better to use enzyme unit [U]","1","1","1",1,false],[false,"Kunkel unit","[knk'U]","[KNK'U]","arbitrary biologic activity",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,null,"UCUM",null,null,null,"1","1","1",1,false],[false,"Mac Lagan unit","[mclg'U]","[MCLG'U]","arbitrary biologic activity",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"galactose index; galactose tolerance test; thymol turbidity test unit; mclg U; units; indexes","UCUM","ACnc","Obsolete","unit for liver tests - previously used in thymol turbidity tests for liver disease diagnoses, and now is sometimes referred to in the oral galactose tolerance test","1","1","1",1,false],[false,"tuberculin unit","[tb'U]","[TB'U]","biologic activity of tuberculin",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"TU; units","UCUM","Arb","Clinical","amount of tuberculin antigen -usually in reference to a TB skin test ","1","1","1",1,false],[false,"50% cell culture infectious dose","[CCID_50]","[CCID_50]","biologic activity (infectivity) of an infectious agent preparation",1,[0,0,0,0,0,0,0],"CCID50","chemical",false,null,null,1,false,true,0,0,"CCID50; 50% cell culture infective doses","UCUM","NumThres","Clinical","","1","1","1",1,false],[false,"50% tissue culture infectious dose","[TCID_50]","[TCID_50]","biologic activity (infectivity) of an infectious agent preparation",1,[0,0,0,0,0,0,0],"TCID50","chemical",false,null,null,1,false,true,0,0,"TCID50; 50% tissue culture infective dose","UCUM","NumThres","Clinical","","1","1","1",1,false],[false,"50% embryo infectious dose","[EID_50]","[EID_50]","biologic activity (infectivity) of an infectious agent preparation",1,[0,0,0,0,0,0,0],"EID50","chemical",false,null,null,1,false,true,0,0,"EID50; 50% embryo infective doses; EID50 Egg Infective Dosage","UCUM","thresNum","Clinical","","1","1","1",1,false],[false,"plaque forming units","[PFU]","[PFU]","amount of an infectious agent",1,[0,0,0,0,0,0,0],"PFU","chemical",false,null,null,1,false,true,0,0,"PFU","UCUM","ACnc","Clinical","tests usually report unit as number of PFU per unit volume","1","1","1",1,false],[false,"focus forming units (cells)","[FFU]","[FFU]","amount of an infectious agent",1,[0,0,0,0,0,0,0],"FFU","chemical",false,null,null,1,false,true,0,0,"FFU","UCUM","EntNum","Clinical","","1","1","1",1,false],[false,"colony forming units","[CFU]","[CFU]","amount of a proliferating organism",1,[0,0,0,0,0,0,0],"CFU","chemical",false,null,null,1,false,true,0,0,"CFU","UCUM","Num","Clinical","","1","1","1",1,false],[false,"index of reactivity (allergen)","[IR]","[IR]","amount of an allergen callibrated through in-vivo testing using the Stallergenes® method.",1,[0,0,0,0,0,0,0],"IR","chemical",false,null,null,1,false,true,0,0,"IR; indexes","UCUM","Acnc","Clinical","amount of an allergen callibrated through in-vivo testing using the Stallergenes method. Usually reported in tests as IR/mL","1","1","1",1,false],[false,"bioequivalent allergen unit","[BAU]","[BAU]","amount of an allergen callibrated through in-vivo testing based on the ID50EAL method of (intradermal dilution for 50mm sum of erythema diameters",1,[0,0,0,0,0,0,0],"BAU","chemical",false,null,null,1,false,true,0,0,"BAU; Bioequivalent Allergy Units; bioequivalent allergen units","UCUM","Arb","Clinical","","1","1","1",1,false],[false,"allergy unit","[AU]","[AU]","procedure defined amount of an allergen using some reference standard",1,[0,0,0,0,0,0,0],"AU","chemical",false,null,null,1,false,true,0,0,"allergy units; allergen units; AU","UCUM","Arb","Clinical","Most standard test allergy units are reported as [IU] or as %. ","1","1","1",1,false],[false,"allergen unit for Ambrosia artemisiifolia","[Amb'a'1'U]","[AMB'A'1'U]","procedure defined amount of the major allergen of ragweed.",1,[0,0,0,0,0,0,0],"Amb a 1 U","chemical",false,null,null,1,false,true,0,0,"Amb a 1 unit; Antigen E; AgE U; allergen units","UCUM","Arb","Clinical","Amb a 1 is the major allergen in short ragweed, and can be converted Bioequivalent allergen units (BAU) where 350 Amb a 1 U/mL = 100,000 BAU/mL","1","1","1",1,false],[false,"protein nitrogen unit (allergen testing)","[PNU]","[PNU]","procedure defined amount of a protein substance",1,[0,0,0,0,0,0,0],"PNU","chemical",false,null,null,1,false,true,0,0,"protein nitrogen units; PNU","UCUM","Mass","Clinical","defined as 0.01 ug of phosphotungstic acid-precipitable protein nitrogen. Being replaced by bioequivalent allergy units (BAU).","1","1","1",1,false],[false,"Limit of flocculation","[Lf]","[LF]","procedure defined amount of an antigen substance",1,[0,0,0,0,0,0,0],"Lf","chemical",false,null,null,1,false,true,0,0,"Lf doses","UCUM","Arb","Clinical","the antigen content forming 1:1 ratio against 1 unit of antitoxin","1","1","1",1,false],[false,"D-antigen unit (polio)","[D'ag'U]","[D'AG'U]","procedure defined amount of a poliomyelitis d-antigen substance",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"DAgU; units","UCUM","Acnc","Clinical","unit of potency of poliovirus vaccine used for poliomyelitis prevention reported as D antigen units/mL. The unit is poliovirus type-specific.","1","1","1",1,false],[false,"fibrinogen equivalent units","[FEU]","[FEU]","amount of fibrinogen broken down into the measured d-dimers",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"FEU","UCUM","MCnc","Clinical","Note both the FEU and DDU units are used to report D-dimer measurements. 1 DDU = 1/2 FFU","1","1","1",1,false],[false,"ELISA unit","[ELU]","[ELU]","arbitrary ELISA unit",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"Enzyme-Linked Immunosorbent Assay Units; ELU; EL. U","UCUM","ACnc","Clinical","","1","1","1",1,false],[false,"Ehrlich units (urobilinogen)","[EU]","[EU]","Ehrlich unit",1,[0,0,0,0,0,0,0],null,"chemical",false,null,null,1,false,true,0,0,"EU/dL; mg{urobilinogen}/dL","UCUM","ACnc","Clinical","","1","1","1",1,false],[false,"neper","Np","NEP","level",1,[0,0,0,0,0,0,0],"Np","levels",true,null,"ln",1,true,false,0,0,"nepers","UCUM","LogRto","Clinical","logarithmic unit for ratios of measurements of physical field and power quantities, such as gain and loss of electronic signals","1",null,null,1,false],[false,"bel","B","B","level",1,[0,0,0,0,0,0,0],"B","levels",true,null,"lg",1,true,false,0,0,"bels","UCUM","LogRto","Clinical","Logarithm of the ratio of power- or field-type quantities; usually expressed in decibels ","1",null,null,1,false],[false,"bel sound pressure","B[SPL]","B[SPL]","pressure level",0.019999999999999997,[-1,-2,1,0,0,0,0],"B(SPL)","levels",true,null,"lgTimes2",1,true,false,0,0,"bel SPL; B SPL; sound pressure bels","UCUM","LogRto","Clinical","used to measure sound level in acoustics","Pa",null,null,0.000019999999999999998,false],[false,"bel volt","B[V]","B[V]","electric potential level",1000,[2,-2,1,0,0,-1,0],"B(V)","levels",true,null,"lgTimes2",1,true,false,0,0,"bel V; B V; volts bels","UCUM","LogRtoElp","Clinical","used to express power gain in electrical circuits","V",null,null,1,false],[false,"bel millivolt","B[mV]","B[MV]","electric potential level",1,[2,-2,1,0,0,-1,0],"B(mV)","levels",true,null,"lgTimes2",1,true,false,0,0,"bel mV; B mV; millivolt bels; 10^-3V bels; 10*-3V ","UCUM","LogRtoElp","Clinical","used to express power gain in electrical circuits","mV",null,null,1,false],[false,"bel microvolt","B[uV]","B[UV]","electric potential level",0.001,[2,-2,1,0,0,-1,0],"B(μV)","levels",true,null,"lgTimes2",1,true,false,0,0,"bel uV; B uV; microvolts bels; 10^-6V bel; 10*-6V bel","UCUM","LogRto","Clinical","used to express power gain in electrical circuits","uV",null,null,1,false],[false,"bel 10 nanovolt","B[10.nV]","B[10.NV]","electric potential level",0.000010000000000000003,[2,-2,1,0,0,-1,0],"B(10 nV)","levels",true,null,"lgTimes2",1,true,false,0,0,"bel 10 nV; B 10 nV; 10 nanovolts bels","UCUM","LogRtoElp","Clinical","used to express power gain in electrical circuits","nV",null,null,10,false],[false,"bel watt","B[W]","B[W]","power level",1000,[2,-3,1,0,0,0,0],"B(W)","levels",true,null,"lg",1,true,false,0,0,"bel W; b W; b Watt; Watts bels","UCUM","LogRto","Clinical","used to express power","W",null,null,1,false],[false,"bel kilowatt","B[kW]","B[KW]","power level",1000000,[2,-3,1,0,0,0,0],"B(kW)","levels",true,null,"lg",1,true,false,0,0,"bel kW; B kW; kilowatt bel; kW bel; kW B","UCUM","LogRto","Clinical","used to express power","kW",null,null,1,false],[false,"stere","st","STR","volume",1,[3,0,0,0,0,0,0],"st","misc",true,null,null,1,false,false,0,0,"stère; m3; cubic meter; m^3; meters cubed; metre","UCUM","Vol","Nonclinical","equal to one cubic meter, usually used for measuring firewood","m3","M3","1",1,false],[false,"Ångström","Ao","AO","length",1.0000000000000002e-10,[1,0,0,0,0,0,0],"Å","misc",false,null,null,1,false,false,0,0,"Å; Angstroms; Ao; Ångströms","UCUM","Len","Clinical","equal to 10^-10 meters; used to express wave lengths and atom scaled differences ","nm","NM","0.1",0.1,false],[false,"barn","b","BRN","action area",1.0000000000000001e-28,[2,0,0,0,0,0,0],"b","misc",false,null,null,1,false,false,0,0,"barns","UCUM","Area","Clinical","used in high-energy physics to express cross-sectional areas","fm2","FM2","100",100,false],[false,"technical atmosphere","att","ATT","pressure",98066500,[-1,-2,1,0,0,0,0],"at","misc",false,null,null,1,false,false,0,0,"at; tech atm; tech atmosphere; kgf/cm2; atms; atmospheres","UCUM","Pres","Obsolete","non-SI unit of pressure equal to one kilogram-force per square centimeter","kgf/cm2","KGF/CM2","1",1,false],[false,"mho","mho","MHO","electric conductance",0.001,[-2,1,-1,0,0,2,0],"mho","misc",true,null,null,1,false,false,0,0,"siemens; ohm reciprocals; Ω^−1; Ω-1 ","UCUM","","Obsolete","unit of electric conductance (the inverse of electrical resistance) equal to ohm^-1","S","S","1",1,false],[false,"pound per square inch","[psi]","[PSI]","pressure",6894757.293168359,[-1,-2,1,0,0,0,0],"psi","misc",false,null,null,1,false,false,0,0,"psi; lb/in2; lb per in2","UCUM","Pres","Clinical","","[lbf_av]/[in_i]2","[LBF_AV]/[IN_I]2","1",1,false],[false,"circle - plane angle","circ","CIRC","plane angle",6.283185307179586,[0,0,0,1,0,0,0],"circ","misc",false,null,null,1,false,false,0,0,"angles; circles","UCUM","Angle","Clinical","","[pi].rad","[PI].RAD","2",2,false],[false,"spere - solid angle","sph","SPH","solid angle",12.566370614359172,[0,0,0,2,0,0,0],"sph","misc",false,null,null,1,false,false,0,0,"speres","UCUM","Angle","Clinical","equal to the solid angle of an entire sphere = 4πsr (sr = steradian) ","[pi].sr","[PI].SR","4",4,false],[false,"metric carat","[car_m]","[CAR_M]","mass",0.2,[0,0,1,0,0,0,0],"ctm","misc",false,null,null,1,false,false,0,0,"carats; ct; car m","UCUM","Mass","Nonclinical","unit of mass for gemstones","g","G","2e-1",0.2,false],[false,"carat of gold alloys","[car_Au]","[CAR_AU]","mass fraction",0.041666666666666664,[0,0,0,0,0,0,0],"ctAu","misc",false,null,null,1,false,false,0,0,"karats; k; kt; car au; carats","UCUM","MFr","Nonclinical","unit of purity for gold alloys","/24","/24","1",1,false],[false,"Smoot","[smoot]","[SMOOT]","length",1.7018000000000002,[1,0,0,0,0,0,0],null,"misc",false,null,null,1,false,false,0,0,"","UCUM","Len","Nonclinical","prank unit of length from MIT","[in_i]","[IN_I]","67",67,false],[false,"meter per square seconds per square root of hertz","[m/s2/Hz^(1/2)]","[M/S2/HZ^(1/2)]","amplitude spectral density",1,[2,-3,0,0,0,0,0],null,"misc",false,null,"sqrt",1,true,false,0,0,"m/s2/(Hz^.5); m/s2/(Hz^(1/2)); m per s2 per Hz^1/2","UCUM","","Constant","measures amplitude spectral density, and is equal to the square root of power spectral density\n ","m2/s4/Hz",null,null,1,false],[false,"bit - logarithmic","bit_s","BIT_S","amount of information",1,[0,0,0,0,0,0,0],"bits","infotech",false,null,"ld",1,true,false,0,0,"bit-s; bit s; bit logarithmic","UCUM","LogA","Nonclinical","defined as the log base 2 of the number of distinct signals; cannot practically be used to express more than 1000 bits\n\nIn information theory, the definition of the amount of self-information and information entropy is often expressed with the binary logarithm (log base 2)","1",null,null,1,false],[false,"bit","bit","BIT","amount of information",1,[0,0,0,0,0,0,0],"bit","infotech",true,null,null,1,false,false,0,0,"bits","UCUM","","Nonclinical","dimensionless information unit of 1 used in computing and digital communications","1","1","1",1,false],[false,"byte","By","BY","amount of information",8,[0,0,0,0,0,0,0],"B","infotech",true,null,null,1,false,false,0,0,"bytes","UCUM","","Nonclinical","equal to 8 bits","bit","bit","8",8,false],[false,"baud","Bd","BD","signal transmission rate",1,[0,1,0,0,0,0,0],"Bd","infotech",true,null,"inv",1,false,false,0,0,"Bd; bauds","UCUM","Freq","Nonclinical","unit to express rate in symbols per second or pulses per second. ","s","/s","1",1,false],[false,"per twelve hour","/(12.h)","1/(12.HR)","",0.000023148148148148147,[0,-1,0,0,0,0,0],"/h",null,false,null,null,1,false,false,0,0,"per 12 hours; 12hrs; 12 hrs; /12hrs","LOINC","Rat","Clinical","",null,null,null,null,false],[false,"per arbitrary unit","/[arb'U]","1/[ARB'U]","",1,[0,0,0,0,0,0,0],"/arb/ U",null,false,null,null,1,false,true,0,0,"/arbU","LOINC","InvA ","Clinical","",null,null,null,null,false],[false,"per high power field","/[HPF]","1/[HPF]","",1,[0,0,0,0,0,0,0],"/HPF",null,false,null,null,1,false,false,0,0,"/HPF; per HPF","LOINC","Naric","Clinical","",null,null,null,null,false],[false,"per international unit","/[IU]","1/[IU]","",1,[0,0,0,0,0,0,0],"/i/U.",null,false,null,null,1,false,true,0,0,"international units; /IU; per IU","LOINC","InvA","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)",null,null,null,null,false],[false,"per low power field","/[LPF]","1/[LPF]","",1,[0,0,0,0,0,0,0],"/LPF",null,false,null,null,1,false,false,0,0,"/LPF; per LPF","LOINC","Naric","Clinical","",null,null,null,null,false],[false,"per 10 billion ","/10*10","1/(10*10)","",1e-10,[0,0,0,0,0,0,0],"/1010",null,false,null,null,1,false,false,0,0,"/10^10; per 10*10","LOINC","NFr","Clinical","used for counting entities, e.g. blood cells; usually these kinds of terms have numerators such as moles or milligrams, and counting that amount per the number in the denominator",null,null,null,null,false],[false,"per trillion ","/10*12","1/(10*12)","",1e-12,[0,0,0,0,0,0,0],"/1012",null,false,null,null,1,false,false,0,0,"/10^12; per 10*12","LOINC","NFr","Clinical","used for counting entities, e.g. blood cells; usually these kinds of terms have numerators such as moles or milligrams, and counting that amount per the number in the denominator",null,null,null,null,false],[false,"per thousand","/10*3","1/(10*3)","",0.001,[0,0,0,0,0,0,0],"/103",null,false,null,null,1,false,false,0,0,"/10^3; per 10*3","LOINC","NFr","Clinical","used for counting entities, e.g. blood cells; usually these kinds of terms have numerators such as moles or milligrams, and counting that amount per the number in the denominator",null,null,null,null,false],[false,"per million","/10*6","1/(10*6)","",0.000001,[0,0,0,0,0,0,0],"/106",null,false,null,null,1,false,false,0,0,"/10^6; per 10*6;","LOINC","NFr","Clinical","used for counting entities, e.g. blood cells; usually these kinds of terms have numerators such as moles or milligrams, and counting that amount per the number in the denominator",null,null,null,null,false],[false,"per billion","/10*9","1/(10*9)","",1e-9,[0,0,0,0,0,0,0],"/109",null,false,null,null,1,false,false,0,0,"/10^9; per 10*9","LOINC","NFr","Clinical","used for counting entities, e.g. blood cells; usually these kinds of terms have numerators such as moles or milligrams, and counting that amount per the number in the denominator",null,null,null,null,false],[false,"per 100","/100","1/100","",0.01,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"per hundred; 10^2; 10*2","LOINC","NFr","Clinical","used for counting entities, e.g. blood cells; usually these kinds of terms have numerators such as moles or milligrams, and counting that amount per the number in the denominator",null,null,null,null,false],[false,"per 100 cells","/100{cells}","/100{CELLS}","",0.01,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"/100 cells; /100cells; per hundred","LOINC","EntMass; EntNum; NFr","Clinical","",null,null,null,null,false],[false,"per 100 neutrophils","/100{neutrophils}","/100{NEUTROPHILS}","",0.01,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"/100 neutrophils; /100neutrophils; per hundred","LOINC","EntMass; EntNum; NFr","Clinical","",null,null,null,null,false],[false,"per 100 spermatozoa","/100{spermatozoa}","/100{SPERMATOZOA}","",0.01,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"/100 spermatozoa; /100spermatozoa; per hundred","LOINC","NFr","Clinical","",null,null,null,null,false],[false,"per 100 white blood cells","/100{WBCs}","/100{WBCS}","",0.01,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"/100 WBCs; /100WBCs; per hundred","LOINC","Ratio; NFr","Clinical","",null,null,null,null,false],[false,"per year","/a","1/ANN","",3.168808781402895e-8,[0,-1,0,0,0,0,0],"/a",null,false,null,null,1,false,false,0,0,"/Years; /yrs; yearly","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"per centimeter of water","/cm[H2O]","1/CM[H2O]","",0.000010197162129779282,[1,2,-1,0,0,0,0],"/cm HO2",null,false,null,null,1,false,false,0,0,"/cmH2O; /cm H2O; centimeters; centimetres","LOINC","InvPress","Clinical","",null,null,null,null,false],[false,"per day","/d","1/D","",0.000011574074074074073,[0,-1,0,0,0,0,0],"/d",null,false,null,null,1,false,false,0,0,"/dy; per day","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"per deciliter","/dL","1/DL","",10000,[-3,0,0,0,0,0,0],"/dL",null,false,null,null,1,false,false,0,0,"per dL; /deciliter; decilitre","LOINC","NCnc","Clinical","",null,null,null,null,false],[false,"per gram","/g","1/G","",1,[0,0,-1,0,0,0,0],"/g",null,false,null,null,1,false,false,0,0,"/gm; /gram; per g","LOINC","NCnt","Clinical","",null,null,null,null,false],[false,"per hour","/h","1/HR","",0.0002777777777777778,[0,-1,0,0,0,0,0],"/h",null,false,null,null,1,false,false,0,0,"/hr; /hour; per hr","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"per kilogram","/kg","1/KG","",0.001,[0,0,-1,0,0,0,0],"/kg",null,false,null,null,1,false,false,0,0,"per kg; per kilogram","LOINC","NCnt","Clinical","",null,null,null,null,false],[false,"per liter","/L","1/L","",1000,[-3,0,0,0,0,0,0],"/L",null,false,null,null,1,false,false,0,0,"/liter; litre","LOINC","NCnc","Clinical","",null,null,null,null,false],[false,"per square meter","/m2","1/M2","",1,[-2,0,0,0,0,0,0],"/m2",null,false,null,null,1,false,false,0,0,"/m^2; /m*2; /sq. m; per square meter; meter squared; metre","LOINC","Naric","Clinical","",null,null,null,null,false],[false,"per cubic meter","/m3","1/M3","",1,[-3,0,0,0,0,0,0],"/m3",null,false,null,null,1,false,false,0,0,"/m^3; /m*3; /cu. m; per cubic meter; meter cubed; per m3; metre","LOINC","NCncn","Clinical","",null,null,null,null,false],[false,"per milligram","/mg","1/MG","",1000,[0,0,-1,0,0,0,0],"/mg",null,false,null,null,1,false,false,0,0,"/milligram; per mg","LOINC","NCnt","Clinical","",null,null,null,null,false],[false,"per minute","/min","1/MIN","",0.016666666666666666,[0,-1,0,0,0,0,0],"/min",null,false,null,null,1,false,false,0,0,"/minute; per mins; breaths beats per minute","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"per milliliter","/mL","1/ML","",1000000,[-3,0,0,0,0,0,0],"/mL",null,false,null,null,1,false,false,0,0,"/milliliter; per mL; millilitre","LOINC","NCncn","Clinical","",null,null,null,null,false],[false,"per millimeter","/mm","1/MM","",1000,[-1,0,0,0,0,0,0],"/mm",null,false,null,null,1,false,false,0,0,"/millimeter; per mm; millimetre","LOINC","InvLen","Clinical","",null,null,null,null,false],[false,"per month","/mo","1/MO","",3.802570537683474e-7,[0,-1,0,0,0,0,0],"/mo",null,false,null,null,1,false,false,0,0,"/month; per mo; monthly; month","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"per second","/s","1/S","",1,[0,-1,0,0,0,0,0],"/s",null,false,null,null,1,false,false,0,0,"/second; /sec; per sec; frequency; Hertz; Herz; Hz; becquerels; Bq; s-1; s^-1","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"per enzyme unit","/U","1/U","",9.963241120049633e-17,[0,1,0,0,0,0,0],"/U",null,false,null,null,1,false,false,-1,0,"/enzyme units; per U","LOINC","InvC; NCat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)",null,null,null,null,false],[false,"per microliter","/uL","1/UL","",999999999.9999999,[-3,0,0,0,0,0,0],"/μL",null,false,null,null,1,false,false,0,0,"/microliter; microlitre; /mcl; per uL","LOINC","ACnc","Clinical","",null,null,null,null,false],[false,"per week","/wk","1/WK","",0.0000016534391534391535,[0,-1,0,0,0,0,0],"/wk",null,false,null,null,1,false,false,0,0,"/week; per wk; weekly, weeks","LOINC","NRat","Clinical","",null,null,null,null,false],[false,"APL unit per milliliter","[APL'U]/mL","[APL'U]/ML","biologic activity of anticardiolipin IgA",1000000,[-3,0,0,0,0,0,0],"/mL","chemical",false,null,null,1,false,true,0,0,"APL/mL; APL'U/mL; APL U/mL; APL/milliliter; IgA anticardiolipin units per milliliter; IgA Phospholipid Units; millilitre; biologic activity of","LOINC","ACnc","Clinical","Units for an anti phospholipid syndrome test","1","1","1",1,false],[false,"arbitrary unit per milliliter","[arb'U]/mL","[ARB'U]/ML","arbitrary",1000000,[-3,0,0,0,0,0,0],"(arb. U)/mL","chemical",false,null,null,1,false,true,0,0,"arb'U/mL; arbU/mL; arb U/mL; arbitrary units per milliliter; millilitre","LOINC","ACnc","Clinical","relative unit of measurement to show the ratio of test measurement to reference measurement","1","1","1",1,false],[false,"colony forming units per liter","[CFU]/L","[CFU]/L","amount of a proliferating organism",1000,[-3,0,0,0,0,0,0],"CFU/L","chemical",false,null,null,1,false,true,0,0,"CFU per Liter; CFU/L","LOINC","NCnc","Clinical","","1","1","1",1,false],[false,"colony forming units per milliliter","[CFU]/mL","[CFU]/ML","amount of a proliferating organism",1000000,[-3,0,0,0,0,0,0],"CFU/mL","chemical",false,null,null,1,false,true,0,0,"CFU per mL; CFU/mL","LOINC","NCnc","Clinical","","1","1","1",1,false],[false,"foot per foot - US","[ft_us]/[ft_us]","[FT_US]/[FT_US]","length",1,[0,0,0,0,0,0,0],"(ftus)/(ftus)","us-lengths",false,null,null,1,false,false,0,0,"ft/ft; ft per ft; feet per feet; visual acuity","","LenRto","Clinical","distance ratio to measure 20:20 vision","m/3937","M/3937","1200",1200,false],[false,"GPL unit per milliliter","[GPL'U]/mL","[GPL'U]/ML","biologic activity of anticardiolipin IgG",1000000,[-3,0,0,0,0,0,0],"/mL","chemical",false,null,null,1,false,true,0,0,"GPL U/mL; GPL'U/mL; GPL/mL; GPL U per mL; IgG Phospholipid Units per milliliters; IgG anticardiolipin units; millilitres ","LOINC","ACnc; AMass","Clinical","Units for an antiphospholipid test","1","1","1",1,false],[false,"international unit per 2 hour","[IU]/(2.h)","[IU]/(2.HR)","arbitrary",0.0001388888888888889,[0,-1,0,0,0,0,0],"(i.U.)/h","chemical",true,null,null,1,false,true,0,0,"IU/2hrs; IU/2 hours; IU per 2 hrs; international units per 2 hours","LOINC","ARat","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per 24 hour","[IU]/(24.h)","[IU]/(24.HR)","arbitrary",0.000011574074074074073,[0,-1,0,0,0,0,0],"(i.U.)/h","chemical",true,null,null,1,false,true,0,0,"IU/24hr; IU/24 hours; IU per 24 hrs; international units per 24 hours","LOINC","ARat","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per day","[IU]/d","[IU]/D","arbitrary",0.000011574074074074073,[0,-1,0,0,0,0,0],"(i.U.)/d","chemical",true,null,null,1,false,true,0,0,"IU/dy; IU/days; IU per dys; international units per day","LOINC","ARat","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per deciliter","[IU]/dL","[IU]/DL","arbitrary",10000,[-3,0,0,0,0,0,0],"(i.U.)/dL","chemical",true,null,null,1,false,true,0,0,"IU/dL; IU per dL; international units per deciliters; decilitres","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per gram","[IU]/g","[IU]/G","arbitrary",1,[0,0,-1,0,0,0,0],"(i.U.)/g","chemical",true,null,null,1,false,true,0,0,"IU/gm; IU/gram; IU per gm; IU per g; international units per gram","LOINC","ACnt","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per hour","[IU]/h","[IU]/HR","arbitrary",0.0002777777777777778,[0,-1,0,0,0,0,0],"(i.U.)/h","chemical",true,null,null,1,false,true,0,0,"IU/hrs; IU per hours; international units per hour","LOINC","ARat","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per kilogram","[IU]/kg","[IU]/KG","arbitrary",0.001,[0,0,-1,0,0,0,0],"(i.U.)/kg","chemical",true,null,null,1,false,true,0,0,"IU/kg; IU/kilogram; IU per kg; units","LOINC","ACnt","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per kilogram per day","[IU]/kg/d","([IU]/KG)/D","arbitrary",1.1574074074074074e-8,[0,-1,-1,0,0,0,0],"((i.U.)/kg)/d","chemical",true,null,null,1,false,true,0,0,"IU/kg/dy; IU/kg/day; IU/kilogram/day; IU per kg per day; units","LOINC","ACntRat","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per liter","[IU]/L","[IU]/L","arbitrary",1000,[-3,0,0,0,0,0,0],"(i.U.)/L","chemical",true,null,null,1,false,true,0,0,"IU/L; IU/liter; IU per liter; units; litre","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per minute","[IU]/min","[IU]/MIN","arbitrary",0.016666666666666666,[0,-1,0,0,0,0,0],"(i.U.)/min","chemical",true,null,null,1,false,true,0,0,"IU/min; IU/minute; IU per minute; international units","LOINC","ARat","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"international unit per milliliter","[IU]/mL","[IU]/ML","arbitrary",1000000,[-3,0,0,0,0,0,0],"(i.U.)/mL","chemical",true,null,null,1,false,true,0,0,"IU/mL; IU per mL; international units per milliliter; millilitre","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"MPL unit per milliliter","[MPL'U]/mL","[MPL'U]/ML","biologic activity of anticardiolipin IgM",1000000,[-3,0,0,0,0,0,0],"/mL","chemical",false,null,null,1,false,true,0,0,"MPL/mL; MPL U/mL; MPL'U/mL; IgM anticardiolipin units; IgM Phospholipid Units; millilitre ","LOINC","ACnc","Clinical","units for antiphospholipid test\n","1","1","1",1,false],[false,"number per high power field","{#}/[HPF]","{#}/[HPF]","",1,[0,0,0,0,0,0,0],"/HPF",null,false,null,null,1,false,false,0,0,"#/HPF; # per HPF; number/HPF; numbers per high power field","LOINC","Naric","Clinical","",null,null,null,null,false],[false,"number per low power field","{#}/[LPF]","{#}/[LPF]","",1,[0,0,0,0,0,0,0],"/LPF",null,false,null,null,1,false,false,0,0,"#/LPF; # per LPF; number/LPF; numbers per low power field","LOINC","Naric","Clinical","",null,null,null,null,false],[false,"IgA antiphosphatidylserine unit ","{APS'U}","{APS'U}","",1,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"APS Unit; Phosphatidylserine Antibody IgA Units","LOINC","ACnc","Clinical","unit for antiphospholipid test",null,null,null,null,false],[false,"EIA index","{EIA_index}","{EIA_index}","",1,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"enzyme immunoassay index","LOINC","ACnc","Clinical","",null,null,null,null,false],[false,"kaolin clotting time","{KCT'U}","{KCT'U}","",1,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"KCT","LOINC","Time","Clinical","sensitive test to detect lupus anticoagulants; measured in seconds",null,null,null,null,false],[false,"IgM antiphosphatidylserine unit","{MPS'U}","{MPS'U}","",1,[0,0,0,0,0,0,0],null,null,false,null,null,1,false,false,0,0,"Phosphatidylserine Antibody IgM Measurement ","LOINC","ACnc","Clinical","",null,null,null,null,false],[false,"trillion per liter","10*12/L","(10*12)/L","number",1000000000000000,[-3,0,0,0,0,0,0],"(1012)/L","dimless",false,null,null,1,false,false,0,0,"10^12/L; 10*12 per Liter; trillion per liter; litre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"10^3 (used for cell count)","10*3","10*3","number",1000,[0,0,0,0,0,0,0],"103","dimless",false,null,null,1,false,false,0,0,"10^3; thousand","LOINC","Num","Clinical","usually used for counting entities (e.g. blood cells) per volume","1","1","10",10,false],[false,"thousand per liter","10*3/L","(10*3)/L","number",1000000,[-3,0,0,0,0,0,0],"(103)/L","dimless",false,null,null,1,false,false,0,0,"10^3/L; 10*3 per liter; litre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"thousand per milliliter","10*3/mL","(10*3)/ML","number",1000000000,[-3,0,0,0,0,0,0],"(103)/mL","dimless",false,null,null,1,false,false,0,0,"10^3/mL; 10*3 per mL; thousand per milliliter; millilitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"thousand per microliter","10*3/uL","(10*3)/UL","number",999999999999.9999,[-3,0,0,0,0,0,0],"(103)/μL","dimless",false,null,null,1,false,false,0,0,"10^3/uL; 10*3 per uL; thousand per microliter; microlitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"10 thousand per microliter","10*4/uL","(10*4)/UL","number",10000000000000,[-3,0,0,0,0,0,0],"(104)/μL","dimless",false,null,null,1,false,false,0,0,"10^4/uL; 10*4 per uL; microlitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"10^5 ","10*5","10*5","number",100000,[0,0,0,0,0,0,0],"105","dimless",false,null,null,1,false,false,0,0,"one hundred thousand","LOINC","Num","Clinical","","1","1","10",10,false],[false,"10^6","10*6","10*6","number",1000000,[0,0,0,0,0,0,0],"106","dimless",false,null,null,1,false,false,0,0,"","LOINC","Num","Clinical","","1","1","10",10,false],[false,"million colony forming unit per liter","10*6.[CFU]/L","((10*6).[CFU])/L","number",1000000000,[-3,0,0,0,0,0,0],"((106).CFU)/L","dimless",false,null,null,1,false,true,0,0,"10*6 CFU/L; 10^6 CFU/L; 10^6CFU; 10^6 CFU per liter; million colony forming units; litre","LOINC","ACnc","Clinical","","1","1","10",10,false],[false,"million international unit","10*6.[IU]","(10*6).[IU]","number",1000000,[0,0,0,0,0,0,0],"(106).(i.U.)","dimless",false,null,null,1,false,true,0,0,"10*6 IU; 10^6 IU; international units","LOINC","arb","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","1","1","10",10,false],[false,"million per 24 hour","10*6/(24.h)","(10*6)/(24.HR)","number",11.574074074074074,[0,-1,0,0,0,0,0],"(106)/h","dimless",false,null,null,1,false,false,0,0,"10*6/24hrs; 10^6/24 hrs; 10*6 per 24 hrs; 10^6 per 24 hours","LOINC","NRat","Clinical","","1","1","10",10,false],[false,"million per kilogram","10*6/kg","(10*6)/KG","number",1000,[0,0,-1,0,0,0,0],"(106)/kg","dimless",false,null,null,1,false,false,0,0,"10^6/kg; 10*6 per kg; 10*6 per kilogram; millions","LOINC","NCnt","Clinical","","1","1","10",10,false],[false,"million per liter","10*6/L","(10*6)/L","number",1000000000,[-3,0,0,0,0,0,0],"(106)/L","dimless",false,null,null,1,false,false,0,0,"10^6/L; 10*6 per Liter; 10^6 per Liter; litre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"million per milliliter","10*6/mL","(10*6)/ML","number",1000000000000,[-3,0,0,0,0,0,0],"(106)/mL","dimless",false,null,null,1,false,false,0,0,"10^6/mL; 10*6 per mL; 10*6 per milliliter; millilitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"million per microliter","10*6/uL","(10*6)/UL","number",1000000000000000,[-3,0,0,0,0,0,0],"(106)/μL","dimless",false,null,null,1,false,false,0,0,"10^6/uL; 10^6 per uL; 10^6/mcl; 10^6 per mcl; 10^6 per microliter; microlitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"10^8","10*8","10*8","number",100000000,[0,0,0,0,0,0,0],"108","dimless",false,null,null,1,false,false,0,0,"100 million; one hundred million; 10^8","LOINC","Num","Clinical","","1","1","10",10,false],[false,"billion per liter","10*9/L","(10*9)/L","number",1000000000000,[-3,0,0,0,0,0,0],"(109)/L","dimless",false,null,null,1,false,false,0,0,"10^9/L; 10*9 per Liter; litre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"billion per milliliter","10*9/mL","(10*9)/ML","number",1000000000000000,[-3,0,0,0,0,0,0],"(109)/mL","dimless",false,null,null,1,false,false,0,0,"10^9/mL; 10*9 per mL; 10^9 per mL; 10*9 per milliliter; millilitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"billion per microliter","10*9/uL","(10*9)/UL","number",1000000000000000000,[-3,0,0,0,0,0,0],"(109)/μL","dimless",false,null,null,1,false,false,0,0,"10^9/uL; 10^9 per uL; 10^9/mcl; 10^9 per mcl; 10*9 per uL; 10*9 per mcl; 10*9/mcl; 10^9 per microliter; microlitre","LOINC","NCncn","Clinical","","1","1","10",10,false],[false,"10 liter per minute per square meter","10.L/(min.m2)","(10.L)/(MIN.M2)","",0.00016666666666666666,[1,-1,0,0,0,0,0],"L/(min.(m2))",null,false,null,null,1,false,false,0,0,"10 liters per minutes per square meter; 10 L per min per m2; m^2; 10 L/(min*m2); 10L/(min*m^2); litres; sq. meter; metre; meters squared","LOINC","ArVRat","Clinical","",null,null,null,null,false],[false,"10 liter per minute","10.L/min","(10.L)/MIN","",0.00016666666666666666,[3,-1,0,0,0,0,0],"L/min",null,false,null,null,1,false,false,0,0,"10 liters per minute; 10 L per min; 10L; 10 L/min; litre","LOINC","VRat","Clinical","",null,null,null,null,false],[false,"10 micronewton second per centimeter to the fifth power per square meter","10.uN.s/(cm5.m2)","((10.UN).S)/(CM5.M2)","",100000000,[-6,-1,1,0,0,0,0],"(μN.s)/(cm5).(m2)",null,false,null,null,1,false,false,0,0,"dyne seconds per centimeter5 and square meter; dyn.s/(cm5.m2); dyn.s/cm5/m2; cm^5; m^2","LOINC","","Clinical","unit to measure systemic vascular resistance per body surface area",null,null,null,null,false],[false,"24 hour","24.h","24.HR","",86400,[0,1,0,0,0,0,0],"h",null,false,null,null,1,false,false,0,0,"24hrs; 24 hrs; 24 hours; days; dy","LOINC","Time","Clinical","",null,null,null,null,false],[false,"ampere per meter","A/m","A/M","electric current",1,[-1,-1,0,0,0,1,0],"A/m","si",true,null,null,1,false,false,0,0,"A/m; amp/meter; magnetic field strength; H; B; amperes per meter; metre","LOINC","","Clinical","unit of magnetic field strength","C/s","C/S","1",1,false],[false,"centigram","cg","CG","mass",0.01,[0,0,1,0,0,0,0],"cg",null,false,"M",null,1,false,false,0,0,"centigrams; cg; cgm","LOINC","Mass","Clinical","",null,null,null,null,false],[false,"centiliter","cL","CL","volume",0.00001,[3,0,0,0,0,0,0],"cL","iso1000",true,null,null,1,false,false,0,0,"centiliters; centilitres","LOINC","Vol","Clinical","","l",null,"1",1,false],[false,"centimeter","cm","CM","length",0.01,[1,0,0,0,0,0,0],"cm",null,false,"L",null,1,false,false,0,0,"centimeters; centimetres","LOINC","Len","Clinical","",null,null,null,null,false],[false,"centimeter of water","cm[H2O]","CM[H2O]","pressure",98066.5,[-1,-2,1,0,0,0,0],"cm HO2","clinical",true,null,null,1,false,false,0,0,"cm H2O; cmH2O; centimetres; pressure","LOINC","Pres","Clinical","unit of pressure mostly applies to blood pressure","kPa","KPAL","980665e-5",9.80665,false],[false,"centimeter of water per liter per second","cm[H2O]/L/s","(CM[H2O]/L)/S","pressure",98066500,[-4,-3,1,0,0,0,0],"((cm HO2)/L)/s","clinical",true,null,null,1,false,false,0,0,"cm[H2O]/(L/s); cm[H2O].s/L; cm H2O/L/sec; cmH2O/L/sec; cmH2O/Liter; cmH2O per L per secs; centimeters of water per liters per second; centimetres; litres; cm[H2O]/(L/s)","LOINC","PresRat","Clinical","unit used to measure mean pulmonary resistance","kPa","KPAL","980665e-5",9.80665,false],[false,"centimeter of water per second per meter","cm[H2O]/s/m","(CM[H2O]/S)/M","pressure",98066.5,[-2,-3,1,0,0,0,0],"((cm HO2)/s)/m","clinical",true,null,null,1,false,false,0,0,"cm[H2O]/(s.m); cm H2O/s/m; cmH2O; cmH2O/sec/m; cmH2O per secs per meters; centimeters of water per seconds per meter; centimetres; metre","LOINC","PresRat","Clinical","unit used to measure pulmonary pressure time product","kPa","KPAL","980665e-5",9.80665,false],[false,"centimeter of mercury","cm[Hg]","CM[HG]","pressure",1333220,[-1,-2,1,0,0,0,0],"cm Hg","clinical",true,null,null,1,false,false,0,0,"centimeters of mercury; centimetres; cmHg; cm Hg","LOINC","Pres","Clinical","unit of pressure where 1 cmHg = 10 torr","kPa","KPAL","133.3220",133.322,false],[false,"square centimeter","cm2","CM2","length",0.0001,[2,0,0,0,0,0,0],"cm2",null,false,"L",null,1,false,false,0,0,"cm^2; sq cm; centimeters squared; square centimeters; centimetre; area","LOINC","Area","Clinical","",null,null,null,null,false],[false,"square centimeter per second","cm2/s","CM2/S","length",0.0001,[2,-1,0,0,0,0,0],"(cm2)/s",null,false,"L",null,1,false,false,0,0,"cm^2/sec; square centimeters per second; sq cm per sec; cm2; centimeters squared; centimetres","LOINC","AreaRat","Clinical","",null,null,null,null,false],[false,"centipoise","cP","CP","dynamic viscosity",1.0000000000000002,[-1,-1,1,0,0,0,0],"cP","cgs",true,null,null,1,false,false,0,0,"cps; centiposes","LOINC","Visc","Clinical","unit of dynamic viscosity in the CGS system with base units: 10^−3 Pa.s = 1 mPa·.s (1 millipascal second)","dyn.s/cm2","DYN.S/CM2","1",1,false],[false,"centistoke","cSt","CST","kinematic viscosity",0.000001,[2,-1,0,0,0,0,0],"cSt","cgs",true,null,null,1,false,false,0,0,"centistokes","LOINC","Visc","Clinical","unit for kinematic viscosity with base units of mm^2/s (square millimeter per second)","cm2/s","CM2/S","1",1,false],[false,"dekaliter per minute","daL/min","DAL/MIN","volume",0.00016666666666666666,[3,-1,0,0,0,0,0],"daL/min","iso1000",true,null,null,1,false,false,0,0,"dekalitres; dekaliters per minute; per min","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"dekaliter per minute per square meter","daL/min/m2","(DAL/MIN)/M2","volume",0.00016666666666666666,[1,-1,0,0,0,0,0],"(daL/min)/(m2)","iso1000",true,null,null,1,false,false,0,0,"daL/min/m^2; daL/minute/m2; sq. meter; dekaliters per minutes per square meter; meter squared; dekalitres; metre","LOINC","ArVRat","Clinical","The area usually is the body surface area used to normalize cardiovascular measures for patient's size","l",null,"1",1,false],[false,"decibel","dB","DB","level",1,[0,0,0,0,0,0,0],"dB","levels",true,null,"lg",0.1,true,false,0,0,"decibels","LOINC","LogRto","Clinical","unit most commonly used in acoustics as unit of sound pressure level. (also see B[SPL] or bel sound pressure level). ","1",null,null,1,false],[false,"degree per second","deg/s","DEG/S","plane angle",0.017453292519943295,[0,-1,0,1,0,0,0],"°/s","iso1000",false,null,null,1,false,false,0,0,"deg/sec; deg per sec; °/sec; twist rate; angular speed; rotational speed","LOINC","ARat","Clinical","unit of angular (rotational) speed used to express turning rate","[pi].rad/360","[PI].RAD/360","2",2,false],[false,"decigram","dg","DG","mass",0.1,[0,0,1,0,0,0,0],"dg",null,false,"M",null,1,false,false,0,0,"decigrams; dgm; 0.1 grams; 1/10 gm","LOINC","Mass","Clinical","equal to 1/10 gram",null,null,null,null,false],[false,"deciliter","dL","DL","volume",0.0001,[3,0,0,0,0,0,0],"dL","iso1000",true,null,null,1,false,false,0,0,"deciliters; decilitres; 0.1 liters; 1/10 L","LOINC","Vol","Clinical","equal to 1/10 liter","l",null,"1",1,false],[false,"decimeter","dm","DM","length",0.1,[1,0,0,0,0,0,0],"dm",null,false,"L",null,1,false,false,0,0,"decimeters; decimetres; 0.1 meters; 1/10 m; 10 cm; centimeters","LOINC","Len","Clinical","equal to 1/10 meter or 10 centimeters",null,null,null,null,false],[false,"square decimeter per square second","dm2/s2","DM2/S2","length",0.010000000000000002,[2,-2,0,0,0,0,0],"(dm2)/(s2)",null,false,"L",null,1,false,false,0,0,"dm2 per s2; dm^2/s^2; decimeters squared per second squared; sq dm; sq sec","LOINC","EngMass (massic energy)","Clinical","units for energy per unit mass or Joules per kilogram (J/kg = kg.m2/s2/kg = m2/s2) ",null,null,null,null,false],[false,"dyne second per centimeter per square meter","dyn.s/(cm.m2)","(DYN.S)/(CM.M2)","force",1,[-2,-1,1,0,0,0,0],"(dyn.s)/(cm.(m2))","cgs",true,null,null,1,false,false,0,0,"(dyn*s)/(cm*m2); (dyn*s)/(cm*m^2); dyn s per cm per m2; m^2; dyne seconds per centimeters per square meter; centimetres; sq. meter; squared","LOINC","","Clinical","","g.cm/s2","G.CM/S2","1",1,false],[false,"dyne second per centimeter","dyn.s/cm","(DYN.S)/CM","force",1,[0,-1,1,0,0,0,0],"(dyn.s)/cm","cgs",true,null,null,1,false,false,0,0,"(dyn*s)/cm; dyn sec per cm; seconds; centimetre; dyne seconds","LOINC","","Clinical","","g.cm/s2","G.CM/S2","1",1,false],[false,"equivalent per liter","eq/L","EQ/L","amount of substance",6.0221366999999994e+26,[-3,0,0,0,0,0,0],"eq/L","chemical",true,null,null,1,false,false,0,1,"eq/liter; eq/litre; eqs; equivalents per liter; litre","LOINC","SCnc","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"equivalent per milliliter","eq/mL","EQ/ML","amount of substance",6.0221367e+29,[-3,0,0,0,0,0,0],"eq/mL","chemical",true,null,null,1,false,false,0,1,"equivalent/milliliter; equivalents per milliliter; eq per mL; millilitre","LOINC","SCnc","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"equivalent per millimole","eq/mmol","EQ/MMOL","amount of substance",1000,[0,0,0,0,0,0,0],"eq/mmol","chemical",true,null,null,1,false,false,-1,1,"equivalent/millimole; equivalents per millimole; eq per mmol","LOINC","SRto","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"equivalent per micromole","eq/umol","EQ/UMOL","amount of substance",1000000,[0,0,0,0,0,0,0],"eq/μmol","chemical",true,null,null,1,false,false,-1,1,"equivalent/micromole; equivalents per micromole; eq per umol","LOINC","SRto","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"femtogram","fg","FG","mass",1e-15,[0,0,1,0,0,0,0],"fg",null,false,"M",null,1,false,false,0,0,"fg; fgm; femtograms; weight","LOINC","Mass","Clinical","equal to 10^-15 grams",null,null,null,null,false],[false,"femtoliter","fL","FL","volume",1e-18,[3,0,0,0,0,0,0],"fL","iso1000",true,null,null,1,false,false,0,0,"femtolitres; femtoliters","LOINC","Vol; EntVol","Clinical","equal to 10^-15 liters","l",null,"1",1,false],[false,"femtometer","fm","FM","length",1e-15,[1,0,0,0,0,0,0],"fm",null,false,"L",null,1,false,false,0,0,"femtometres; femtometers","LOINC","Len","Clinical","equal to 10^-15 meters",null,null,null,null,false],[false,"femtomole","fmol","FMOL","amount of substance",602213670,[0,0,0,0,0,0,0],"fmol","si",true,null,null,1,false,false,1,0,"femtomoles","LOINC","EntSub","Clinical","equal to 10^-15 moles","10*23","10*23","6.0221367",6.0221367,false],[false,"femtomole per gram","fmol/g","FMOL/G","amount of substance",602213670,[0,0,-1,0,0,0,0],"fmol/g","si",true,null,null,1,false,false,1,0,"femtomoles; fmol/gm; fmol per gm","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"femtomole per liter","fmol/L","FMOL/L","amount of substance",602213670000,[-3,0,0,0,0,0,0],"fmol/L","si",true,null,null,1,false,false,1,0,"femtomoles; fmol per liter; litre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"femtomole per milligram","fmol/mg","FMOL/MG","amount of substance",602213670000,[0,0,-1,0,0,0,0],"fmol/mg","si",true,null,null,1,false,false,1,0,"fmol per mg; femtomoles","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"femtomole per milliliter","fmol/mL","FMOL/ML","amount of substance",602213670000000,[-3,0,0,0,0,0,0],"fmol/mL","si",true,null,null,1,false,false,1,0,"femtomoles; millilitre; fmol per mL; fmol per milliliter","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"gram meter","g.m","G.M","mass",1,[1,0,1,0,0,0,0],"g.m",null,false,"M",null,1,false,false,0,0,"g*m; gxm; meters; metres","LOINC","Enrg","Clinical","Unit for measuring stroke work (heart work)",null,null,null,null,false],[false,"gram per 100 gram","g/(100.g)","G/(100.G)","mass",0.01,[0,0,0,0,0,0,0],"g/g",null,false,"M",null,1,false,false,0,0,"g/100 gm; 100gm; grams per 100 grams; gm per 100 gm","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"gram per 12 hour","g/(12.h)","G/(12.HR)","mass",0.000023148148148148147,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/12hrs; 12 hrs; gm per 12 hrs; 12hrs; grams per 12 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 24 hour","g/(24.h)","G/(24.HR)","mass",0.000011574074074074073,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/24hrs; gm/24 hrs; gm per 24 hrs; 24hrs; grams per 24 hours; gm/dy; gm per dy; grams per day","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 3 days","g/(3.d)","G/(3.D)","mass",0.000003858024691358025,[0,-1,1,0,0,0,0],"g/d",null,false,"M",null,1,false,false,0,0,"gm/3dy; gm/3 dy; gm per 3 days; grams","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 4 hour","g/(4.h)","G/(4.HR)","mass",0.00006944444444444444,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/4hrs; gm/4 hrs; gm per 4 hrs; 4hrs; grams per 4 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 48 hour","g/(48.h)","G/(48.HR)","mass",0.000005787037037037037,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/48hrs; gm/48 hrs; gm per 48 hrs; 48hrs; grams per 48 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 5 hour","g/(5.h)","G/(5.HR)","mass",0.00005555555555555556,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/5hrs; gm/5 hrs; gm per 5 hrs; 5hrs; grams per 5 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 6 hour","g/(6.h)","G/(6.HR)","mass",0.000046296296296296294,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/6hrs; gm/6 hrs; gm per 6 hrs; 6hrs; grams per 6 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per 72 hour","g/(72.h)","G/(72.HR)","mass",0.000003858024691358025,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/72hrs; gm/72 hrs; gm per 72 hrs; 72hrs; grams per 72 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per cubic centimeter","g/cm3","G/CM3","mass",999999.9999999999,[-3,0,1,0,0,0,0],"g/(cm3)",null,false,"M",null,1,false,false,0,0,"g/cm^3; gm per cm3; g per cm^3; grams per centimeter cubed; cu. cm; centimetre; g/mL; gram per milliliter; millilitre","LOINC","MCnc","Clinical","g/cm3 = g/mL",null,null,null,null,false],[false,"gram per day","g/d","G/D","mass",0.000011574074074074073,[0,-1,1,0,0,0,0],"g/d",null,false,"M",null,1,false,false,0,0,"gm/dy; gm per dy; grams per day; gm/24hrs; gm/24 hrs; gm per 24 hrs; 24hrs; grams per 24 hours; serving","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per deciliter","g/dL","G/DL","mass",10000,[-3,0,1,0,0,0,0],"g/dL",null,false,"M",null,1,false,false,0,0,"gm/dL; gm per dL; grams per deciliter; decilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"gram per gram","g/g","G/G","mass",1,[0,0,0,0,0,0,0],"g/g",null,false,"M",null,1,false,false,0,0,"gm; grams","LOINC","MRto ","Clinical","",null,null,null,null,false],[false,"gram per hour","g/h","G/HR","mass",0.0002777777777777778,[0,-1,1,0,0,0,0],"g/h",null,false,"M",null,1,false,false,0,0,"gm/hr; gm per hr; grams; intake; output","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per hour per square meter","g/h/m2","(G/HR)/M2","mass",0.0002777777777777778,[-2,-1,1,0,0,0,0],"(g/h)/(m2)",null,false,"M",null,1,false,false,0,0,"gm/hr/m2; gm/h/m2; /m^2; sq. m; g per hr per m2; grams per hours per square meter; meter squared; metre","LOINC","ArMRat","Clinical","",null,null,null,null,false],[false,"gram per kilogram","g/kg ","G/KG","mass",0.001,[0,0,0,0,0,0,0],"g/kg",null,false,"M",null,1,false,false,0,0,"g per kg; gram per kilograms","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"gram per kilogram per 8 hour ","g/kg/(8.h)","(G/KG)/(8.HR)","mass",3.472222222222222e-8,[0,-1,0,0,0,0,0],"(g/kg)/h",null,false,"M",null,1,false,false,0,0,"g/(8.kg.h); gm/kg/8hrs; 8 hrs; g per kg per 8 hrs; 8hrs; grams per kilograms per 8 hours; shift","LOINC","MCntRat; RelMRat","Clinical","unit often used to describe mass in grams of protein consumed in a 8 hours, divided by the subject's body weight in kilograms. Also used to measure mass dose rate per body mass",null,null,null,null,false],[false,"gram per kilogram per day","g/kg/d","(G/KG)/D","mass",1.1574074074074074e-8,[0,-1,0,0,0,0,0],"(g/kg)/d",null,false,"M",null,1,false,false,0,0,"g/(kg.d); gm/kg/dy; gm per kg per dy; grams per kilograms per day","LOINC","RelMRat","Clinical","unit often used to describe mass in grams of protein consumed in a day, divided by the subject's body weight in kilograms. Also used to measure mass dose rate per body mass",null,null,null,null,false],[false,"gram per kilogram per hour","g/kg/h","(G/KG)/HR","mass",2.7777777777777776e-7,[0,-1,0,0,0,0,0],"(g/kg)/h",null,false,"M",null,1,false,false,0,0,"g/(kg.h); g/kg/hr; g per kg per hrs; grams per kilograms per hour","LOINC","MCntRat; RelMRat","Clinical","unit used to measure mass dose rate per body mass",null,null,null,null,false],[false,"gram per kilogram per minute","g/kg/min","(G/KG)/MIN","mass",0.000016666666666666667,[0,-1,0,0,0,0,0],"(g/kg)/min",null,false,"M",null,1,false,false,0,0,"g/(kg.min); g/kg/min; g per kg per min; grams per kilograms per minute","LOINC","MCntRat; RelMRat","Clinical","unit used to measure mass dose rate per body mass",null,null,null,null,false],[false,"gram per liter","g/L","G/L","mass",1000,[-3,0,1,0,0,0,0],"g/L",null,false,"M",null,1,false,false,0,0,"gm per liter; g/liter; grams per liter; litre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"gram per square meter","g/m2","G/M2","mass",1,[-2,0,1,0,0,0,0],"g/(m2)",null,false,"M",null,1,false,false,0,0,"g/m^2; gram/square meter; g/sq m; g per m2; g per m^2; grams per square meter; meters squared; metre","LOINC","ArMass","Clinical","Tests measure myocardial mass (heart ventricle system) per body surface area; unit used to measure mass dose per body surface area",null,null,null,null,false],[false,"gram per milligram","g/mg","G/MG","mass",1000,[0,0,0,0,0,0,0],"g/mg",null,false,"M",null,1,false,false,0,0,"g per mg; grams per milligram","LOINC","MCnt; MRto","Clinical","",null,null,null,null,false],[false,"gram per minute","g/min","G/MIN","mass",0.016666666666666666,[0,-1,1,0,0,0,0],"g/min",null,false,"M",null,1,false,false,0,0,"g per min; grams per minute; gram/minute","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"gram per milliliter","g/mL","G/ML","mass",1000000,[-3,0,1,0,0,0,0],"g/mL",null,false,"M",null,1,false,false,0,0,"g per mL; grams per milliliter; millilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"gram per millimole","g/mmol","G/MMOL","mass",1.6605401866749388e-21,[0,0,1,0,0,0,0],"g/mmol",null,false,"M",null,1,false,false,-1,0,"grams per millimole; g per mmol","LOINC","Ratio","Clinical","",null,null,null,null,false],[false,"joule per liter","J/L","J/L","energy",1000000,[-1,-2,1,0,0,0,0],"J/L","si",true,null,null,1,false,false,0,0,"joules per liter; litre; J per L","LOINC","EngCnc","Clinical","","N.m","N.M","1",1,false],[false,"degree Kelvin per Watt","K/W","K/W","temperature",0.001,[-2,3,-1,0,1,0,0],"K/W",null,false,"C",null,1,false,false,0,0,"degree Kelvin/Watt; K per W; thermal ohm; thermal resistance; degrees","LOINC","TempEngRat","Clinical","unit for absolute thermal resistance equal to the reciprocal of thermal conductance. Unit used for tests to measure work of breathing",null,null,null,null,false],[false,"kilo international unit per liter","k[IU]/L","K[IU]/L","arbitrary",1000000,[-3,0,0,0,0,0,0],"(ki.U.)/L","chemical",true,null,null,1,false,true,0,0,"kIU/L; kIU per L; kIU per liter; kilo international units; litre; allergens; allergy units","LOINC","ACnc","Clinical","IgE has an WHO reference standard so IgE allergen testing can be reported as k[IU]/L","[iU]","[IU]","1",1,false],[false,"kilo international unit per milliliter","k[IU]/mL","K[IU]/ML","arbitrary",1000000000,[-3,0,0,0,0,0,0],"(ki.U.)/mL","chemical",true,null,null,1,false,true,0,0,"kIU/mL; kIU per mL; kIU per milliliter; kilo international units; millilitre; allergens; allergy units","LOINC","ACnc","Clinical","IgE has an WHO reference standard so IgE allergen testing can be reported as k[IU]/mL","[iU]","[IU]","1",1,false],[false,"katal per kilogram","kat/kg","KAT/KG","catalytic activity",602213670000000000000,[0,-1,-1,0,0,0,0],"kat/kg","chemical",true,null,null,1,false,false,1,0,"kat per kg; katals per kilogram; mol/s/kg; moles per seconds per kilogram","LOINC","CCnt","Clinical","kat is a unit of catalytic activity with base units = mol/s. Rarely used because its units are too large to practically express catalytic activity. See enzyme unit [U] which is the standard unit for catalytic activity.","mol/s","MOL/S","1",1,false],[false,"katal per liter","kat/L","KAT/L","catalytic activity",6.0221366999999994e+26,[-3,-1,0,0,0,0,0],"kat/L","chemical",true,null,null,1,false,false,1,0,"kat per L; katals per liter; litre; mol/s/L; moles per seconds per liter","LOINC","CCnc","Clinical","kat is a unit of catalytic activity with base units = mol/s. Rarely used because its units are too large to practically express catalytic activity. See enzyme unit [U] which is the standard unit for catalytic activity.","mol/s","MOL/S","1",1,false],[false,"kilocalorie","kcal","KCAL","energy",4184000,[2,-2,1,0,0,0,0],"kcal","heat",true,null,null,1,false,false,0,0,"kilogram calories; large calories; food calories; kcals","LOINC","EngRat","Clinical","It is equal to 1000 calories (equal to 4.184 kJ). But in practical usage, kcal refers to food calories which excludes caloric content in fiber and other constitutes that is not digestible by humans. Also see nutrition label Calories ([Cal])","cal_th","CAL_TH","1",1,false],[false,"kilocalorie per 24 hour","kcal/(24.h)","KCAL/(24.HR)","energy",48.425925925925924,[2,-3,1,0,0,0,0],"kcal/h","heat",true,null,null,1,false,false,0,0,"kcal/24hrs; kcal/24 hrs; kcal per 24hrs; kilocalories per 24 hours; kilojoules; kJ/24hr; kJ/(24.h); kJ/dy; kilojoules per days; intake; calories burned; metabolic rate; food calories","","EngRat","Clinical","","cal_th","CAL_TH","1",1,false],[false,"kilocalorie per ounce","kcal/[oz_av]","KCAL/[OZ_AV]","energy",147586.25679704445,[2,-2,0,0,0,0,0],"kcal/oz","heat",true,null,null,1,false,false,0,0,"kcal/oz; kcal per ozs; large calories per ounces; food calories; servings; international","LOINC","EngCnt","Clinical","used in nutrition to represent calorie of food","cal_th","CAL_TH","1",1,false],[false,"kilocalorie per day","kcal/d","KCAL/D","energy",48.425925925925924,[2,-3,1,0,0,0,0],"kcal/d","heat",true,null,null,1,false,false,0,0,"kcal/dy; kcal per day; kilocalories per days; kilojoules; kJ/dy; kilojoules per days; intake; calories burned; metabolic rate; food calories","LOINC","EngRat","Clinical","unit in nutrition for food intake (measured in calories) in a day","cal_th","CAL_TH","1",1,false],[false,"kilocalorie per hour","kcal/h","KCAL/HR","energy",1162.2222222222222,[2,-3,1,0,0,0,0],"kcal/h","heat",true,null,null,1,false,false,0,0,"kcal/hrs; kcals per hr; intake; kilocalories per hours; kilojoules","LOINC","EngRat","Clinical","used in nutrition to represent caloric requirement or consumption","cal_th","CAL_TH","1",1,false],[false,"kilocalorie per kilogram per 24 hour","kcal/kg/(24.h)","(KCAL/KG)/(24.HR)","energy",0.04842592592592593,[2,-3,0,0,0,0,0],"(kcal/kg)/h","heat",true,null,null,1,false,false,0,0,"kcal/kg/24hrs; 24 hrs; kcal per kg per 24hrs; kilocalories per kilograms per 24 hours; kilojoules","LOINC","EngCntRat","Clinical","used in nutrition to represent caloric requirement per day based on subject's body weight in kilograms","cal_th","CAL_TH","1",1,false],[false,"kilogram","kg","KG","mass",1000,[0,0,1,0,0,0,0],"kg",null,false,"M",null,1,false,false,0,0,"kilograms; kgs","LOINC","Mass","Clinical","",null,null,null,null,false],[false,"kilogram meter per second","kg.m/s","(KG.M)/S","mass",1000,[1,-1,1,0,0,0,0],"(kg.m)/s",null,false,"M",null,1,false,false,0,0,"kg*m/s; kg.m per sec; kg*m per sec; p; momentum","LOINC","","Clinical","unit for momentum = mass times velocity",null,null,null,null,false],[false,"kilogram per second per square meter","kg/(s.m2)","KG/(S.M2)","mass",1000,[-2,-1,1,0,0,0,0],"kg/(s.(m2))",null,false,"M",null,1,false,false,0,0,"kg/(s*m2); kg/(s*m^2); kg per s per m2; per sec; per m^2; kilograms per seconds per square meter; meter squared; metre","LOINC","ArMRat","Clinical","",null,null,null,null,false],[false,"kilogram per hour","kg/h","KG/HR","mass",0.2777777777777778,[0,-1,1,0,0,0,0],"kg/h",null,false,"M",null,1,false,false,0,0,"kg/hr; kg per hr; kilograms per hour","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"kilogram per liter","kg/L","KG/L","mass",1000000,[-3,0,1,0,0,0,0],"kg/L",null,false,"M",null,1,false,false,0,0,"kg per liter; litre; kilograms","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"kilogram per square meter","kg/m2","KG/M2","mass",1000,[-2,0,1,0,0,0,0],"kg/(m2)",null,false,"M",null,1,false,false,0,0,"kg/m^2; kg/sq. m; kg per m2; per m^2; per sq. m; kilograms; meter squared; metre; BMI","LOINC","Ratio","Clinical","units for body mass index (BMI)",null,null,null,null,false],[false,"kilogram per cubic meter","kg/m3","KG/M3","mass",1000,[-3,0,1,0,0,0,0],"kg/(m3)",null,false,"M",null,1,false,false,0,0,"kg/m^3; kg/cu. m; kg per m3; per m^3; per cu. m; kilograms; meters cubed; metre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"kilogram per minute","kg/min","KG/MIN","mass",16.666666666666668,[0,-1,1,0,0,0,0],"kg/min",null,false,"M",null,1,false,false,0,0,"kilogram/minute; kg per min; kilograms per minute","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"kilogram per mole","kg/mol","KG/MOL","mass",1.6605401866749388e-21,[0,0,1,0,0,0,0],"kg/mol",null,false,"M",null,1,false,false,-1,0,"kilogram/mole; kg per mol; kilograms per mole","LOINC","SCnt","Clinical","",null,null,null,null,false],[false,"kilogram per second","kg/s","KG/S","mass",1000,[0,-1,1,0,0,0,0],"kg/s",null,false,"M",null,1,false,false,0,0,"kg/sec; kilogram/second; kg per sec; kilograms; second","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"kiloliter","kL","KL","volume",1,[3,0,0,0,0,0,0],"kL","iso1000",true,null,null,1,false,false,0,0,"kiloliters; kilolitres; m3; m^3; meters cubed; metre","LOINC","Vol","Clinical","","l",null,"1",1,false],[false,"kilometer","km","KM","length",1000,[1,0,0,0,0,0,0],"km",null,false,"L",null,1,false,false,0,0,"kilometers; kilometres; distance","LOINC","Len","Clinical","",null,null,null,null,false],[false,"kilopascal","kPa","KPAL","pressure",1000000,[-1,-2,1,0,0,0,0],"kPa","si",true,null,null,1,false,false,0,0,"kilopascals; pressure","LOINC","Pres; PPresDiff","Clinical","","N/m2","N/M2","1",1,false],[false,"kilosecond","ks","KS","time",1000,[0,1,0,0,0,0,0],"ks",null,false,"T",null,1,false,false,0,0,"kiloseconds; ksec","LOINC","Time","Clinical","",null,null,null,null,false],[false,"kilo enzyme unit","kU","KU","catalytic activity",10036894500000000000,[0,-1,0,0,0,0,0],"kU","chemical",true,null,null,1,false,false,1,0,"units; mmol/min; millimoles per minute","LOINC","CAct","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 kU = 1 mmol/min","umol/min","UMOL/MIN","1",1,false],[false,"kilo enzyme unit per gram","kU/g","KU/G","catalytic activity",10036894500000000000,[0,-1,-1,0,0,0,0],"kU/g","chemical",true,null,null,1,false,false,1,0,"units per grams; kU per gm","LOINC","CCnt","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 kU = 1 mmol/min","umol/min","UMOL/MIN","1",1,false],[false,"kilo enzyme unit per liter","kU/L","KU/L","catalytic activity",1.00368945e+22,[-3,-1,0,0,0,0,0],"kU/L","chemical",true,null,null,1,false,false,1,0,"units per liter; litre; enzymatic activity; enzyme activity per volume; activities","LOINC","ACnc; CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 kU = 1 mmol/min","umol/min","UMOL/MIN","1",1,false],[false,"kilo enzyme unit per milliliter","kU/mL","KU/ML","catalytic activity",1.00368945e+25,[-3,-1,0,0,0,0,0],"kU/mL","chemical",true,null,null,1,false,false,1,0,"kU per mL; units per milliliter; millilitre; enzymatic activity per volume; enzyme activities","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 kU = 1 mmol/min","umol/min","UMOL/MIN","1",1,false],[false,"Liters per 24 hour","L/(24.h)","L/(24.HR)","volume",1.1574074074074074e-8,[3,-1,0,0,0,0,0],"L/h","iso1000",true,null,null,1,false,false,0,0,"L/24hrs; L/24 hrs; L per 24hrs; liters per 24 hours; day; dy; litres; volume flow rate","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"Liters per 8 hour","L/(8.h)","L/(8.HR)","volume",3.472222222222222e-8,[3,-1,0,0,0,0,0],"L/h","iso1000",true,null,null,1,false,false,0,0,"L/8hrs; L/8 hrs; L per 8hrs; liters per 8 hours; litres; volume flow rate; shift","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"Liters per minute per square meter","L/(min.m2) ","L/(MIN.M2)","volume",0.000016666666666666667,[1,-1,0,0,0,0,0],"L/(min.(m2))","iso1000",true,null,null,1,false,false,0,0,"L/(min.m2); L/min/m^2; L/min/sq. meter; L per min per m2; m^2; liters per minutes per square meter; meter squared; litres; metre ","LOINC","ArVRat","Clinical","unit for tests that measure cardiac output per body surface area (cardiac index)","l",null,"1",1,false],[false,"Liters per day","L/d","L/D","volume",1.1574074074074074e-8,[3,-1,0,0,0,0,0],"L/d","iso1000",true,null,null,1,false,false,0,0,"L/dy; L per day; 24hrs; 24 hrs; 24 hours; liters; litres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"Liters per hour","L/h","L/HR","volume",2.7777777777777776e-7,[3,-1,0,0,0,0,0],"L/h","iso1000",true,null,null,1,false,false,0,0,"L/hr; L per hr; litres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"Liters per kilogram","L/kg","L/KG","volume",0.000001,[3,0,-1,0,0,0,0],"L/kg","iso1000",true,null,null,1,false,false,0,0,"L per kg; litre","LOINC","VCnt","Clinical","","l",null,"1",1,false],[false,"Liters per liter","L/L","L/L","volume",1,[0,0,0,0,0,0,0],"L/L","iso1000",true,null,null,1,false,false,0,0,"L per L; liter/liter; litre","LOINC","VFr","Clinical","","l",null,"1",1,false],[false,"Liters per minute","L/min","L/MIN","volume",0.000016666666666666667,[3,-1,0,0,0,0,0],"L/min","iso1000",true,null,null,1,false,false,0,0,"liters per minute; litre","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"Liters per minute per square meter","L/min/m2","(L/MIN)/M2","volume",0.000016666666666666667,[1,-1,0,0,0,0,0],"(L/min)/(m2)","iso1000",true,null,null,1,false,false,0,0,"L/(min.m2); L/min/m^2; L/min/sq. meter; L per min per m2; m^2; liters per minutes per square meter; meter squared; litres; metre ","","ArVRat","Clinical","unit for tests that measure cardiac output per body surface area (cardiac index)","l",null,"1",1,false],[false,"Liters per second","L/s","L/S","volume",0.001,[3,-1,0,0,0,0,0],"L/s","iso1000",true,null,null,1,false,false,0,0,"L per sec; litres","LOINC","VRat","Clinical","unit used often to measure gas flow and peak expiratory flow","l",null,"1",1,false],[false,"Liters per second per square second","L/s/s2","(L/S)/S2","volume",0.001,[3,-3,0,0,0,0,0],"(L/s)/(s2)","iso1000",true,null,null,1,false,false,0,0,"L/s/s^2; L/sec/sec2; L/sec/sec^2; L/sec/sq. sec; L per s per s2; L per sec per sec2; s^2; sec^2; liters per seconds per square second; second squared; litres ","LOINC","ArVRat","Clinical","unit for tests that measure cardiac output/body surface area","l",null,"1",1,false],[false,"lumen square meter","lm.m2","LM.M2","luminous flux",1,[2,0,0,2,0,0,1],"lm.(m2)","si",true,null,null,1,false,false,0,0,"lm*m2; lm*m^2; lumen meters squared; lumen sq. meters; metres","LOINC","","Clinical","","cd.sr","CD.SR","1",1,false],[false,"meter per second","m/s","M/S","length",1,[1,-1,0,0,0,0,0],"m/s",null,false,"L",null,1,false,false,0,0,"meter/second; m per sec; meters per second; metres; velocity; speed","LOINC","Vel","Clinical","unit of velocity",null,null,null,null,false],[false,"meter per square second","m/s2","M/S2","length",1,[1,-2,0,0,0,0,0],"m/(s2)",null,false,"L",null,1,false,false,0,0,"m/s^2; m/sq. sec; m per s2; per s^2; meters per square second; second squared; sq second; metres; acceleration","LOINC","Accel","Clinical","unit of acceleration",null,null,null,null,false],[false,"milli international unit per liter","m[IU]/L","M[IU]/L","arbitrary",1,[-3,0,0,0,0,0,0],"(mi.U.)/L","chemical",true,null,null,1,false,true,0,0,"mIU/L; m IU/L; mIU per liter; units; litre","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"milli international unit per milliliter","m[IU]/mL","M[IU]/ML","arbitrary",1000.0000000000001,[-3,0,0,0,0,0,0],"(mi.U.)/mL","chemical",true,null,null,1,false,true,0,0,"mIU/mL; m IU/mL; mIU per mL; milli international units per milliliter; millilitre","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"square meter","m2","M2","length",1,[2,0,0,0,0,0,0],"m2",null,false,"L",null,1,false,false,0,0,"m^2; sq m; square meters; meters squared; metres","LOINC","Area","Clinical","unit often used to represent body surface area",null,null,null,null,false],[false,"square meter per second","m2/s","M2/S","length",1,[2,-1,0,0,0,0,0],"(m2)/s",null,false,"L",null,1,false,false,0,0,"m^2/sec; m2 per sec; m^2 per sec; sq m/sec; meters squared/seconds; sq m per sec; meters squared; metres","LOINC","ArRat","Clinical","",null,null,null,null,false],[false,"cubic meter per second","m3/s","M3/S","length",1,[3,-1,0,0,0,0,0],"(m3)/s",null,false,"L",null,1,false,false,0,0,"m^3/sec; m3 per sec; m^3 per sec; cu m/sec; cubic meters per seconds; meters cubed; metres","LOINC","VRat","Clinical","",null,null,null,null,false],[false,"milliampere","mA","MA","electric current",0.001,[0,-1,0,0,0,1,0],"mA","si",true,null,null,1,false,false,0,0,"mamp; milliamperes","LOINC","ElpotRat","Clinical","unit of electric current","C/s","C/S","1",1,false],[false,"millibar","mbar","MBAR","pressure",100000,[-1,-2,1,0,0,0,0],"mbar","iso1000",true,null,null,1,false,false,0,0,"millibars","LOINC","Pres","Clinical","unit of pressure","Pa","PAL","1e5",100000,false],[false,"millibar second per liter","mbar.s/L","(MBAR.S)/L","pressure",100000000,[-4,-1,1,0,0,0,0],"(mbar.s)/L","iso1000",true,null,null,1,false,false,0,0,"mbar*s/L; mbar.s per L; mbar*s per L; millibar seconds per liter; millibar second per litre","LOINC","","Clinical","unit to measure expiratory resistance","Pa","PAL","1e5",100000,false],[false,"millibar per liter per second","mbar/L/s","(MBAR/L)/S","pressure",100000000,[-4,-3,1,0,0,0,0],"(mbar/L)/s","iso1000",true,null,null,1,false,false,0,0,"mbar/(L.s); mbar/L/sec; mbar/liter/second; mbar per L per sec; mbar per liter per second; millibars per liters per seconds; litres","LOINC","PresCncRat","Clinical","unit to measure expiratory resistance","Pa","PAL","1e5",100000,false],[false,"milliequivalent","meq","MEQ","amount of substance",602213670000000000000,[0,0,0,0,0,0,0],"meq","chemical",true,null,null,1,false,false,0,1,"milliequivalents; meqs","LOINC","Sub","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per 2 hour","meq/(2.h)","MEQ/(2.HR)","amount of substance",83640787500000000,[0,-1,0,0,0,0,0],"meq/h","chemical",true,null,null,1,false,false,0,1,"meq/2hrs; meq/2 hrs; meq per 2 hrs; milliequivalents per 2 hours","LOINC","SRat","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per 24 hour","meq/(24.h)","MEQ/(24.HR)","amount of substance",6970065625000000,[0,-1,0,0,0,0,0],"meq/h","chemical",true,null,null,1,false,false,0,1,"meq/24hrs; meq/24 hrs; meq per 24 hrs; milliequivalents per 24 hours","LOINC","SRat","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per 8 hour","meq/(8.h)","MEQ/(8.HR)","amount of substance",20910196875000000,[0,-1,0,0,0,0,0],"meq/h","chemical",true,null,null,1,false,false,0,1,"meq/8hrs; meq/8 hrs; meq per 8 hrs; milliequivalents per 8 hours; shift","LOINC","SRat","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per day","meq/d","MEQ/D","amount of substance",6970065625000000,[0,-1,0,0,0,0,0],"meq/d","chemical",true,null,null,1,false,false,0,1,"meq/dy; meq per day; milliquivalents per days; meq/24hrs; meq/24 hrs; meq per 24 hrs; milliequivalents per 24 hours","LOINC","SRat","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per deciliter","meq/dL","MEQ/DL","amount of substance",6.022136699999999e+24,[-3,0,0,0,0,0,0],"meq/dL","chemical",true,null,null,1,false,false,0,1,"meq per dL; milliequivalents per deciliter; decilitre","LOINC","SCnc","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per gram","meq/g","MEQ/G","amount of substance",602213670000000000000,[0,0,-1,0,0,0,0],"meq/g","chemical",true,null,null,1,false,false,0,1,"mgq/gm; meq per gm; milliequivalents per gram","LOINC","MCnt","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per hour","meq/h","MEQ/HR","amount of substance",167281575000000000,[0,-1,0,0,0,0,0],"meq/h","chemical",true,null,null,1,false,false,0,1,"meq/hrs; meq per hrs; milliequivalents per hour","LOINC","SRat","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per kilogram","meq/kg","MEQ/KG","amount of substance",602213670000000000,[0,0,-1,0,0,0,0],"meq/kg","chemical",true,null,null,1,false,false,0,1,"meq per kg; milliequivalents per kilogram","LOINC","SCnt","Clinical","equivalence equals moles per valence; used to measure dose per patient body mass","mol","MOL","1",1,false],[false,"milliequivalent per kilogram per hour","meq/kg/h","(MEQ/KG)/HR","amount of substance",167281575000000,[0,-1,-1,0,0,0,0],"(meq/kg)/h","chemical",true,null,null,1,false,false,0,1,"meq/(kg.h); meq/kg/hr; meq per kg per hr; milliequivalents per kilograms per hour","LOINC","SCntRat","Clinical","equivalence equals moles per valence; unit used to measure dose rate per patient body mass","mol","MOL","1",1,false],[false,"milliequivalent per liter","meq/L","MEQ/L","amount of substance",6.0221367e+23,[-3,0,0,0,0,0,0],"meq/L","chemical",true,null,null,1,false,false,0,1,"milliequivalents per liter; litre; meq per l; acidity","LOINC","SCnc","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per square meter","meq/m2","MEQ/M2","amount of substance",602213670000000000000,[-2,0,0,0,0,0,0],"meq/(m2)","chemical",true,null,null,1,false,false,0,1,"meq/m^2; meq/sq. m; milliequivalents per square meter; meter squared; metre","LOINC","ArSub","Clinical","equivalence equals moles per valence; note that the use of m2 in clinical units ofter refers to body surface area","mol","MOL","1",1,false],[false,"milliequivalent per minute","meq/min","MEQ/MIN","amount of substance",10036894500000000000,[0,-1,0,0,0,0,0],"meq/min","chemical",true,null,null,1,false,false,0,1,"meq per min; milliequivalents per minute","LOINC","SRat","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milliequivalent per milliliter","meq/mL","MEQ/ML","amount of substance",6.0221367e+26,[-3,0,0,0,0,0,0],"meq/mL","chemical",true,null,null,1,false,false,0,1,"meq per mL; milliequivalents per milliliter; millilitre","LOINC","SCnc","Clinical","equivalence equals moles per valence","mol","MOL","1",1,false],[false,"milligram","mg","MG","mass",0.001,[0,0,1,0,0,0,0],"mg",null,false,"M",null,1,false,false,0,0,"milligrams","LOINC","Mass","Clinical","",null,null,null,null,false],[false,"milligram per 10 hour","mg/(10.h)","MG/(10.HR)","mass",2.7777777777777777e-8,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/10hrs; mg/10 hrs; mg per 10 hrs; milligrams per 10 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per 12 hour","mg/(12.h)","MG/(12.HR)","mass",2.3148148148148148e-8,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/12hrs; mg/12 hrs; per 12 hrs; 12hrs; milligrams per 12 hours","LOINC","MRat","Clinical","units used for tests in urine",null,null,null,null,false],[false,"milligram per 2 hour","mg/(2.h)","MG/(2.HR)","mass",1.3888888888888888e-7,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/2hrs; mg/2 hrs; mg per 2 hrs; 2hrs; milligrams per 2 hours","LOINC","MRat","Clinical","units used for tests in urine",null,null,null,null,false],[false,"milligram per 24 hour","mg/(24.h)","MG/(24.HR)","mass",1.1574074074074074e-8,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/24hrs; mg/24 hrs; milligrams per 24 hours; mg/kg/dy; mg per kg per day; milligrams per kilograms per days","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per 6 hour","mg/(6.h)","MG/(6.HR)","mass",4.6296296296296295e-8,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/6hrs; mg/6 hrs; mg per 6 hrs; 6hrs; milligrams per 6 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per 72 hour","mg/(72.h)","MG/(72.HR)","mass",3.858024691358025e-9,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/72hrs; mg/72 hrs; 72 hrs; 72hrs; milligrams per 72 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per 8 hour","mg/(8.h)","MG/(8.HR)","mass",3.472222222222222e-8,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/8hrs; mg/8 hrs; milligrams per 8 hours; shift","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per day","mg/d","MG/D","mass",1.1574074074074074e-8,[0,-1,1,0,0,0,0],"mg/d",null,false,"M",null,1,false,false,0,0,"mg/24hrs; mg/24 hrs; milligrams per 24 hours; mg/dy; mg per day; milligrams","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per deciliter","mg/dL","MG/DL","mass",10,[-3,0,1,0,0,0,0],"mg/dL",null,false,"M",null,1,false,false,0,0,"mg per dL; milligrams per deciliter; decilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"milligram per gram","mg/g","MG/G","mass",0.001,[0,0,0,0,0,0,0],"mg/g",null,false,"M",null,1,false,false,0,0,"mg per gm; milligrams per gram","LOINC","MCnt; MRto","Clinical","",null,null,null,null,false],[false,"milligram per hour","mg/h","MG/HR","mass",2.7777777777777776e-7,[0,-1,1,0,0,0,0],"mg/h",null,false,"M",null,1,false,false,0,0,"mg/hr; mg per hr; milligrams","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per kilogram","mg/kg","MG/KG","mass",0.000001,[0,0,0,0,0,0,0],"mg/kg",null,false,"M",null,1,false,false,0,0,"mg per kg; milligrams per kilograms","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"milligram per kilogram per 8 hour","mg/kg/(8.h)","(MG/KG)/(8.HR)","mass",3.472222222222222e-11,[0,-1,0,0,0,0,0],"(mg/kg)/h",null,false,"M",null,1,false,false,0,0,"mg/(8.h.kg); mg/kg/8hrs; mg/kg/8 hrs; mg per kg per 8hrs; 8 hrs; milligrams per kilograms per 8 hours; shift","LOINC","RelMRat; MCntRat","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"milligram per kilogram per day","mg/kg/d","(MG/KG)/D","mass",1.1574074074074074e-11,[0,-1,0,0,0,0,0],"(mg/kg)/d",null,false,"M",null,1,false,false,0,0,"mg/(kg.d); mg/(kg.24.h)mg/kg/dy; mg per kg per day; milligrams per kilograms per days; mg/kg/(24.h); mg/kg/24hrs; 24 hrs; 24 hours","LOINC","RelMRat ","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"milligram per kilogram per hour","mg/kg/h","(MG/KG)/HR","mass",2.7777777777777777e-10,[0,-1,0,0,0,0,0],"(mg/kg)/h",null,false,"M",null,1,false,false,0,0,"mg/(kg.h); mg/kg/hr; mg per kg per hr; milligrams per kilograms per hour","LOINC","RelMRat; MCntRat","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"milligram per kilogram per minute","mg/kg/min","(MG/KG)/MIN","mass",1.6666666666666667e-8,[0,-1,0,0,0,0,0],"(mg/kg)/min",null,false,"M",null,1,false,false,0,0,"mg/(kg.min); mg per kg per min; milligrams per kilograms per minute","LOINC","RelMRat; MCntRat","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"milligram per liter","mg/L","MG/L","mass",1,[-3,0,1,0,0,0,0],"mg/L",null,false,"M",null,1,false,false,0,0,"mg per l; milligrams per liter; litre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"milligram per square meter","mg/m2","MG/M2","mass",0.001,[-2,0,1,0,0,0,0],"mg/(m2)",null,false,"M",null,1,false,false,0,0,"mg/m^2; mg/sq. m; mg per m2; mg per m^2; mg per sq. milligrams; meter squared; metre","LOINC","ArMass","Clinical","",null,null,null,null,false],[false,"milligram per cubic meter","mg/m3","MG/M3","mass",0.001,[-3,0,1,0,0,0,0],"mg/(m3)",null,false,"M",null,1,false,false,0,0,"mg/m^3; mg/cu. m; mg per m3; milligrams per cubic meter; meter cubed; metre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"milligram per milligram","mg/mg","MG/MG","mass",1,[0,0,0,0,0,0,0],"mg/mg",null,false,"M",null,1,false,false,0,0,"mg per mg; milligrams; milligram/milligram","LOINC","MRto","Clinical","",null,null,null,null,false],[false,"milligram per minute","mg/min","MG/MIN","mass",0.000016666666666666667,[0,-1,1,0,0,0,0],"mg/min",null,false,"M",null,1,false,false,0,0,"mg per min; milligrams per minutes; milligram/minute","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"milligram per milliliter","mg/mL","MG/ML","mass",1000.0000000000001,[-3,0,1,0,0,0,0],"mg/mL",null,false,"M",null,1,false,false,0,0,"mg per mL; milligrams per milliliters; millilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"milligram per millimole","mg/mmol","MG/MMOL","mass",1.660540186674939e-24,[0,0,1,0,0,0,0],"mg/mmol",null,false,"M",null,1,false,false,-1,0,"mg per mmol; milligrams per millimole; ","LOINC","Ratio","Clinical","",null,null,null,null,false],[false,"milligram per week","mg/wk","MG/WK","mass",1.6534391534391535e-9,[0,-1,1,0,0,0,0],"mg/wk",null,false,"M",null,1,false,false,0,0,"mg/week; mg per wk; milligrams per weeks; milligram/week","LOINC","Mrat","Clinical","",null,null,null,null,false],[false,"milliliter","mL","ML","volume",0.000001,[3,0,0,0,0,0,0],"mL","iso1000",true,null,null,1,false,false,0,0,"milliliters; millilitres","LOINC","Vol","Clinical","","l",null,"1",1,false],[false,"milliliter per 10 hour","mL/(10.h)","ML/(10.HR)","volume",2.7777777777777777e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/10hrs; ml/10 hrs; mL per 10hrs; 10 hrs; milliliters per 10 hours; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 12 hour","mL/(12.h)","ML/(12.HR)","volume",2.3148148148148147e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/12hrs; ml/12 hrs; mL per 12hrs; 12 hrs; milliliters per 12 hours; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 2 hour","mL/(2.h)","ML/(2.HR)","volume",1.3888888888888888e-10,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/2hrs; ml/2 hrs; mL per 2hrs; 2 hrs; milliliters per 2 hours; millilitres ","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 24 hour","mL/(24.h)","ML/(24.HR)","volume",1.1574074074074074e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/24hrs; ml/24 hrs; mL per 24hrs; 24 hrs; milliliters per 24 hours; millilitres; ml/dy; /day; ml per dy; days; fluid outputs; fluid inputs; flow rate","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 4 hour","mL/(4.h)","ML/(4.HR)","volume",6.944444444444444e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/4hrs; ml/4 hrs; mL per 4hrs; 4 hrs; milliliters per 4 hours; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 5 hour","mL/(5.h)","ML/(5.HR)","volume",5.5555555555555553e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/5hrs; ml/5 hrs; mL per 5hrs; 5 hrs; milliliters per 5 hours; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 6 hour","mL/(6.h)","ML/(6.HR)","volume",4.6296296296296294e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/6hrs; ml/6 hrs; mL per 6hrs; 6 hrs; milliliters per 6 hours; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 72 hour","mL/(72.h)","ML/(72.HR)","volume",3.8580246913580245e-12,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/72hrs; ml/72 hrs; mL per 72hrs; 72 hrs; milliliters per 72 hours; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 8 hour","mL/(8.h)","ML/(8.HR)","volume",3.472222222222222e-11,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"ml/8hrs; ml/8 hrs; mL per 8hrs; 8 hrs; milliliters per 8 hours; millilitres; shift","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per 8 hour per kilogram","mL/(8.h)/kg","(ML/(8.HR))/KG","volume",3.472222222222222e-14,[3,-1,-1,0,0,0,0],"(mL/h)/kg","iso1000",true,null,null,1,false,false,0,0,"mL/kg/(8.h); ml/8h/kg; ml/8 h/kg; ml/8hr/kg; ml/8 hr/kgr; mL per 8h per kg; 8 h; 8hr; 8 hr; milliliters per 8 hours per kilogram; millilitres; shift","LOINC","VRatCnt","Clinical","unit used to measure renal excretion volume rate per body mass","l",null,"1",1,false],[false,"milliliter per square inch (international)","mL/[sin_i]","ML/[SIN_I]","volume",0.0015500031000061998,[1,0,0,0,0,0,0],"mL","iso1000",true,null,null,1,false,false,0,0,"mL/sin; mL/in2; mL/in^2; mL per sin; in2; in^2; sq. in; milliliters per square inch; inch squared","LOINC","ArVol","Clinical","","l",null,"1",1,false],[false,"milliliter per centimeter of water","mL/cm[H2O]","ML/CM[H2O]","volume",1.0197162129779282e-11,[4,2,-1,0,0,0,0],"mL/(cm HO2)","iso1000",true,null,null,1,false,false,0,0,"milliliters per centimeter of water; millilitre per centimetre of water; millilitres per centimetre of water; mL/cmH2O; mL/cm H2O; mL per cmH2O; mL per cm H2O","LOINC","Compli","Clinical","unit used to measure dynamic lung compliance","l",null,"1",1,false],[false,"milliliter per day","mL/d","ML/D","volume",1.1574074074074074e-11,[3,-1,0,0,0,0,0],"mL/d","iso1000",true,null,null,1,false,false,0,0,"ml/day; ml per day; milliliters per day; 24 hours; 24hrs; millilitre;","LOINC","VRat","Clinical","usually used to measure fluid output or input; flow rate","l",null,"1",1,false],[false,"milliliter per deciliter","mL/dL","ML/DL","volume",0.009999999999999998,[0,0,0,0,0,0,0],"mL/dL","iso1000",true,null,null,1,false,false,0,0,"mL per dL; millilitres; decilitre; milliliters","LOINC","VFr; VFrDiff","Clinical","","l",null,"1",1,false],[false,"milliliter per hour","mL/h","ML/HR","volume",2.7777777777777777e-10,[3,-1,0,0,0,0,0],"mL/h","iso1000",true,null,null,1,false,false,0,0,"mL/hr; mL per hr; milliliters per hour; millilitres; fluid intake; fluid output","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per kilogram","mL/kg","ML/KG","volume",9.999999999999999e-10,[3,0,-1,0,0,0,0],"mL/kg","iso1000",true,null,null,1,false,false,0,0,"mL per kg; milliliters per kilogram; millilitres","LOINC","VCnt","Clinical","","l",null,"1",1,false],[false,"milliliter per kilogram per 8 hour","mL/kg/(8.h)","(ML/KG)/(8.HR)","volume",3.472222222222222e-14,[3,-1,-1,0,0,0,0],"(mL/kg)/h","iso1000",true,null,null,1,false,false,0,0,"mL/(8.h.kg); mL/kg/8hrs; mL/kg/8 hrs; mL per kg per 8hrs; 8 hrs; milliliters per kilograms per 8 hours; millilitres; shift","LOINC","VCntRat; RelEngRat","Clinical","unit used to measure renal excretion volume rate per body mass","l",null,"1",1,false],[false,"milliliter per kilogram per day","mL/kg/d","(ML/KG)/D","volume",1.1574074074074072e-14,[3,-1,-1,0,0,0,0],"(mL/kg)/d","iso1000",true,null,null,1,false,false,0,0,"mL/(kg.d); mL/kg/dy; mL per kg per day; milliliters per kilograms per day; mg/kg/24hrs; 24 hrs; per 24 hours millilitres","LOINC","VCntRat; RelEngRat","Clinical","unit used to measure renal excretion volume rate per body mass","l",null,"1",1,false],[false,"milliliter per kilogram per hour","mL/kg/h","(ML/KG)/HR","volume",2.7777777777777774e-13,[3,-1,-1,0,0,0,0],"(mL/kg)/h","iso1000",true,null,null,1,false,false,0,0,"mL/(kg.h); mL/kg/hr; mL per kg per hr; milliliters per kilograms per hour; millilitres","LOINC","VCntRat; RelEngRat","Clinical","unit used to measure renal excretion volume rate per body mass","l",null,"1",1,false],[false,"milliliter per kilogram per minute","mL/kg/min","(ML/KG)/MIN","volume",1.6666666666666664e-11,[3,-1,-1,0,0,0,0],"(mL/kg)/min","iso1000",true,null,null,1,false,false,0,0,"mL/(kg.min); mL/kg/dy; mL per kg per day; milliliters per kilograms per day; millilitres","LOINC","RelEngRat","Clinical","used for tests that measure activity metabolic rate compared to standard resting metabolic rate ","l",null,"1",1,false],[false,"milliliter per square meter","mL/m2","ML/M2","volume",0.000001,[1,0,0,0,0,0,0],"mL/(m2)","iso1000",true,null,null,1,false,false,0,0,"mL/m^2; mL/sq. meter; mL per m2; m^2; sq. meter; milliliters per square meter; millilitres; meter squared","LOINC","ArVol","Clinical","used for tests that relate to heart work - e.g. ventricular stroke volume; atrial volume per body surface area","l",null,"1",1,false],[false,"milliliter per millibar","mL/mbar","ML/MBAR","volume",1e-11,[4,2,-1,0,0,0,0],"mL/mbar","iso1000",true,null,null,1,false,false,0,0,"mL per mbar; milliliters per millibar; millilitres","LOINC","","Clinical","unit used to measure dynamic lung compliance","l",null,"1",1,false],[false,"milliliter per minute","mL/min","ML/MIN","volume",1.6666666666666667e-8,[3,-1,0,0,0,0,0],"mL/min","iso1000",true,null,null,1,false,false,0,0,"mL per min; milliliters; millilitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"milliliter per minute per square meter","mL/min/m2","(ML/MIN)/M2","volume",1.6666666666666667e-8,[1,-1,0,0,0,0,0],"(mL/min)/(m2)","iso1000",true,null,null,1,false,false,0,0,"ml/min/m^2; ml/min/sq. meter; mL per min per m2; m^2; sq. meter; milliliters per minutes per square meter; millilitres; metre; meter squared","LOINC","ArVRat","Clinical","unit used to measure volume per body surface area; oxygen consumption index","l",null,"1",1,false],[false,"milliliter per millimeter","mL/mm","ML/MM","volume",0.001,[2,0,0,0,0,0,0],"mL/mm","iso1000",true,null,null,1,false,false,0,0,"mL per mm; milliliters per millimeter; millilitres; millimetre","LOINC","Lineic Volume","Clinical","","l",null,"1",1,false],[false,"milliliter per second","mL/s","ML/S","volume",0.000001,[3,-1,0,0,0,0,0],"mL/s","iso1000",true,null,null,1,false,false,0,0,"ml/sec; mL per sec; milliliters per second; millilitres","LOINC","Vel; VelRat; VRat","Clinical","","l",null,"1",1,false],[false,"millimeter","mm","MM","length",0.001,[1,0,0,0,0,0,0],"mm",null,false,"L",null,1,false,false,0,0,"millimeters; millimetres; height; length; diameter; thickness; axis; curvature; size","LOINC","Len","Clinical","",null,null,null,null,false],[false,"millimeter per hour","mm/h","MM/HR","length",2.7777777777777776e-7,[1,-1,0,0,0,0,0],"mm/h",null,false,"L",null,1,false,false,0,0,"mm/hr; mm per hr; millimeters per hour; millimetres","LOINC","Vel","Clinical","unit to measure sedimentation rate",null,null,null,null,false],[false,"millimeter per minute","mm/min","MM/MIN","length",0.000016666666666666667,[1,-1,0,0,0,0,0],"mm/min",null,false,"L",null,1,false,false,0,0,"mm per min; millimeters per minute; millimetres","LOINC","Vel","Clinical","",null,null,null,null,false],[false,"millimeter of water","mm[H2O]","MM[H2O]","pressure",9806.65,[-1,-2,1,0,0,0,0],"mm HO2","clinical",true,null,null,1,false,false,0,0,"mmH2O; mm H2O; millimeters of water; millimetres","LOINC","Pres","Clinical","","kPa","KPAL","980665e-5",9.80665,false],[false,"millimeter of mercury","mm[Hg]","MM[HG]","pressure",133322,[-1,-2,1,0,0,0,0],"mm Hg","clinical",true,null,null,1,false,false,0,0,"mmHg; mm Hg; millimeters of mercury; millimetres","LOINC","Pres; PPres; Ratio","Clinical","1 mm[Hg] = 1 torr; unit to measure blood pressure","kPa","KPAL","133.3220",133.322,false],[false,"square millimeter","mm2","MM2","length",0.000001,[2,0,0,0,0,0,0],"mm2",null,false,"L",null,1,false,false,0,0,"mm^2; sq. mm.; sq. millimeters; millimeters squared; millimetres","LOINC","Area","Clinical","",null,null,null,null,false],[false,"millimole","mmol","MMOL","amount of substance",602213670000000000000,[0,0,0,0,0,0,0],"mmol","si",true,null,null,1,false,false,1,0,"millimoles","LOINC","Sub","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per 12 hour","mmol/(12.h)","MMOL/(12.HR)","amount of substance",13940131250000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/12hrs; mmol/12 hrs; mmol per 12 hrs; 12hrs; millimoles per 12 hours","LOINC","SRat","Clinical","unit for tests related to urine","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per 2 hour","mmol/(2.h)","MMOL/(2.HR)","amount of substance",83640787500000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/2hrs; mmol/2 hrs; mmol per 2 hrs; 2hrs; millimoles per 2 hours","LOINC","SRat","Clinical","unit for tests related to urine","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per 24 hour","mmol/(24.h)","MMOL/(24.HR)","amount of substance",6970065625000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/24hrs; mmol/24 hrs; mmol per 24 hrs; 24hrs; millimoles per 24 hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per 5 hour","mmol/(5.h)","MMOL/(5.HR)","amount of substance",33456315000000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/5hrs; mmol/5 hrs; mmol per 5 hrs; 5hrs; millimoles per 5 hours","LOINC","SRat","Clinical","unit for tests related to doses","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per 6 hour","mmol/(6.h)","MMOL/(6.HR)","amount of substance",27880262500000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/6hrs; mmol/6 hrs; mmol per 6 hrs; 6hrs; millimoles per 6 hours","LOINC","SRat","Clinical","unit for tests related to urine","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per 8 hour","mmol/(8.h)","MMOL/(8.HR)","amount of substance",20910196875000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/8hrs; mmol/8 hrs; mmol per 8 hrs; 8hrs; millimoles per 8 hours; shift","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per day","mmol/d","MMOL/D","amount of substance",6970065625000000,[0,-1,0,0,0,0,0],"mmol/d","si",true,null,null,1,false,false,1,0,"mmol/24hrs; mmol/24 hrs; mmol per 24 hrs; 24hrs; millimoles per 24 hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per deciliter","mmol/dL","MMOL/DL","amount of substance",6.022136699999999e+24,[-3,0,0,0,0,0,0],"mmol/dL","si",true,null,null,1,false,false,1,0,"mmol per dL; millimoles; decilitre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per gram","mmol/g","MMOL/G","amount of substance",602213670000000000000,[0,0,-1,0,0,0,0],"mmol/g","si",true,null,null,1,false,false,1,0,"mmol per gram; millimoles","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per hour","mmol/h","MMOL/HR","amount of substance",167281575000000000,[0,-1,0,0,0,0,0],"mmol/h","si",true,null,null,1,false,false,1,0,"mmol/hr; mmol per hr; millimoles per hour","LOINC","SRat","Clinical","unit for tests related to urine","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per kilogram","mmol/kg","MMOL/KG","amount of substance",602213670000000000,[0,0,-1,0,0,0,0],"mmol/kg","si",true,null,null,1,false,false,1,0,"mmol per kg; millimoles per kilogram","LOINC","SCnt","Clinical","unit for tests related to stool","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per kilogram per 8 hour","mmol/kg/(8.h)","(MMOL/KG)/(8.HR)","amount of substance",20910196875000,[0,-1,-1,0,0,0,0],"(mmol/kg)/h","si",true,null,null,1,false,false,1,0,"mmol/(8.h.kg); mmol/kg/8hrs; mmol/kg/8 hrs; mmol per kg per 8hrs; 8 hrs; millimoles per kilograms per 8 hours; shift","LOINC","CCnt","Clinical","unit used to measure molar dose rate per patient body mass","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per kilogram per day","mmol/kg/d","(MMOL/KG)/D","amount of substance",6970065625000,[0,-1,-1,0,0,0,0],"(mmol/kg)/d","si",true,null,null,1,false,false,1,0,"mmol/kg/dy; mmol/kg/day; mmol per kg per dy; millimoles per kilograms per day","LOINC","RelSRat","Clinical","unit used to measure molar dose rate per patient body mass","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per kilogram per hour","mmol/kg/h","(MMOL/KG)/HR","amount of substance",167281575000000,[0,-1,-1,0,0,0,0],"(mmol/kg)/h","si",true,null,null,1,false,false,1,0,"mmol/kg/hr; mmol per kg per hr; millimoles per kilograms per hour","LOINC","CCnt","Clinical","unit used to measure molar dose rate per patient body mass","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per kilogram per minute","mmol/kg/min","(MMOL/KG)/MIN","amount of substance",10036894500000000,[0,-1,-1,0,0,0,0],"(mmol/kg)/min","si",true,null,null,1,false,false,1,0,"mmol/(kg.min); mmol/kg/min; mmol per kg per min; millimoles per kilograms per minute","LOINC","CCnt","Clinical","unit used to measure molar dose rate per patient body mass; note that the unit for the enzyme unit U = umol/min. mmol/kg/min = kU/kg; ","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per liter","mmol/L","MMOL/L","amount of substance",6.0221367e+23,[-3,0,0,0,0,0,0],"mmol/L","si",true,null,null,1,false,false,1,0,"mmol per L; millimoles per liter; litre","LOINC","SCnc","Clinical","unit for tests related to doses","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per square meter","mmol/m2","MMOL/M2","amount of substance",602213670000000000000,[-2,0,0,0,0,0,0],"mmol/(m2)","si",true,null,null,1,false,false,1,0,"mmol/m^2; mmol/sq. meter; mmol per m2; m^2; sq. meter; millimoles; meter squared; metre","LOINC","ArSub","Clinical","unit used to measure molar dose per patient body surface area","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per minute","mmol/min","MMOL/MIN","amount of substance",10036894500000000000,[0,-1,0,0,0,0,0],"mmol/min","si",true,null,null,1,false,false,1,0,"mmol per min; millimoles per minute","LOINC","Srat; CAct","Clinical","unit for the enzyme unit U = umol/min. mmol/min = kU","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per millimole","mmol/mmol","MMOL/MMOL","amount of substance",1,[0,0,0,0,0,0,0],"mmol/mmol","si",true,null,null,1,false,false,0,0,"mmol per mmol; millimoles per millimole","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per mole","mmol/mol","MMOL/MOL","amount of substance",0.001,[0,0,0,0,0,0,0],"mmol/mol","si",true,null,null,1,false,false,0,0,"mmol per mol; millimoles per mole","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"millimole per second per liter","mmol/s/L","(MMOL/S)/L","amount of substance",6.0221367e+23,[-3,-1,0,0,0,0,0],"(mmol/s)/L","si",true,null,null,1,false,false,1,0,"mmol/sec/L; mmol per s per L; per sec; millimoles per seconds per liter; litre","LOINC","CCnc ","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per kilogram","mol/kg","MOL/KG","amount of substance",602213670000000000000,[0,0,-1,0,0,0,0],"mol/kg","si",true,null,null,1,false,false,1,0,"mol per kg; moles; mols","LOINC","SCnt","Clinical","unit for tests related to stool","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per kilogram per second","mol/kg/s","(MOL/KG)/S","amount of substance",602213670000000000000,[0,-1,-1,0,0,0,0],"(mol/kg)/s","si",true,null,null,1,false,false,1,0,"mol/kg/sec; mol per kg per sec; moles per kilograms per second; mols","LOINC","CCnt","Clinical","unit of catalytic activity (mol/s) per mass (kg)","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per liter","mol/L","MOL/L","amount of substance",6.0221366999999994e+26,[-3,0,0,0,0,0,0],"mol/L","si",true,null,null,1,false,false,1,0,"mol per L; moles per liter; litre; moles; mols","LOINC","SCnc","Clinical","unit often used in tests measuring oxygen content","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per cubic meter","mol/m3","MOL/M3","amount of substance",6.0221367e+23,[-3,0,0,0,0,0,0],"mol/(m3)","si",true,null,null,1,false,false,1,0,"mol/m^3; mol/cu. m; mol per m3; m^3; cu. meter; mols; moles; meters cubed; metre; mole per kiloliter; kilolitre; mol/kL","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per milliliter","mol/mL","MOL/ML","amount of substance",6.0221367e+29,[-3,0,0,0,0,0,0],"mol/mL","si",true,null,null,1,false,false,1,0,"mol per mL; moles; millilitre; mols","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per mole","mol/mol","MOL/MOL","amount of substance",1,[0,0,0,0,0,0,0],"mol/mol","si",true,null,null,1,false,false,0,0,"mol per mol; moles per mol; mols","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"mole per second","mol/s","MOL/S","amount of substance",6.0221367e+23,[0,-1,0,0,0,0,0],"mol/s","si",true,null,null,1,false,false,1,0,"mol per sec; moles per second; mols","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"milliosmole","mosm","MOSM","amount of substance (dissolved particles)",602213670000000000000,[0,0,0,0,0,0,0],"mosm","chemical",true,null,null,1,false,false,1,0,"milliosmoles","LOINC","Osmol","Clinical","equal to 1/1000 of an osmole","mol","MOL","1",1,false],[false,"milliosmole per kilogram","mosm/kg","MOSM/KG","amount of substance (dissolved particles)",602213670000000000,[0,0,-1,0,0,0,0],"mosm/kg","chemical",true,null,null,1,false,false,1,0,"mosm per kg; milliosmoles per kilogram","LOINC","Osmol","Clinical","","mol","MOL","1",1,false],[false,"milliosmole per liter","mosm/L","MOSM/L","amount of substance (dissolved particles)",6.0221367e+23,[-3,0,0,0,0,0,0],"mosm/L","chemical",true,null,null,1,false,false,1,0,"mosm per liter; litre; milliosmoles","LOINC","Osmol","Clinical","","mol","MOL","1",1,false],[false,"millipascal","mPa","MPAL","pressure",1,[-1,-2,1,0,0,0,0],"mPa","si",true,null,null,1,false,false,0,0,"millipascals","LOINC","Pres","Clinical","unit of pressure","N/m2","N/M2","1",1,false],[false,"millipascal second","mPa.s","MPAL.S","pressure",1,[-1,-1,1,0,0,0,0],"mPa.s","si",true,null,null,1,false,false,0,0,"mPa*s; millipoise; mP; dynamic viscosity","LOINC","Visc","Clinical","base units for millipoise, a measurement of dynamic viscosity","N/m2","N/M2","1",1,false],[false,"megasecond","Ms","MAS","time",1000000,[0,1,0,0,0,0,0],"Ms",null,false,"T",null,1,false,false,0,0,"megaseconds","LOINC","Time","Clinical","",null,null,null,null,false],[false,"millisecond","ms","MS","time",0.001,[0,1,0,0,0,0,0],"ms",null,false,"T",null,1,false,false,0,0,"milliseconds; duration","LOINC","Time","Clinical","",null,null,null,null,false],[false,"milli enzyme unit per gram","mU/g","MU/G","catalytic activity",10036894500000,[0,-1,-1,0,0,0,0],"mU/g","chemical",true,null,null,1,false,false,1,0,"mU per gm; milli enzyme units per gram; enzyme activity; enzymatic activity per mass","LOINC","CCnt","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 mU = 1 nmol/min","umol/min","UMOL/MIN","1",1,false],[false,"milli enzyme unit per liter","mU/L","MU/L","catalytic activity",10036894500000000,[-3,-1,0,0,0,0,0],"mU/L","chemical",true,null,null,1,false,false,1,0,"mU per liter; litre; milli enzyme units enzymatic activity per volume; enzyme activity","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 mU = 1 nmol/min","umol/min","UMOL/MIN","1",1,false],[false,"milli enzyme unit per milligram","mU/mg","MU/MG","catalytic activity",10036894500000000,[0,-1,-1,0,0,0,0],"mU/mg","chemical",true,null,null,1,false,false,1,0,"mU per mg; milli enzyme units per milligram","LOINC","CCnt","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 mU = 1 nmol/min","umol/min","UMOL/MIN","1",1,false],[false,"milli enzyme unit per milliliter","mU/mL","MU/ML","catalytic activity",10036894500000000000,[-3,-1,0,0,0,0,0],"mU/mL","chemical",true,null,null,1,false,false,1,0,"mU per mL; milli enzyme units per milliliter; millilitre; enzymatic activity per volume; enzyme activity","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 mU = 1 nmol/min","umol/min","UMOL/MIN","1",1,false],[false,"milli enzyme unit per milliliter per minute","mU/mL/min","(MU/ML)/MIN","catalytic activity",167281575000000000,[-3,-2,0,0,0,0,0],"(mU/mL)/min","chemical",true,null,null,1,false,false,1,0,"mU per mL per min; mU per milliliters per minute; millilitres; milli enzyme units; enzymatic activity; enzyme activity","LOINC","CCncRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 mU = 1 nmol/min","umol/min","UMOL/MIN","1",1,false],[false,"millivolt","mV","MV","electric potential",1,[2,-2,1,0,0,-1,0],"mV","si",true,null,null,1,false,false,0,0,"millivolts","LOINC","Elpot","Clinical","unit of electric potential (voltage)","J/C","J/C","1",1,false],[false,"Newton centimeter","N.cm","N.CM","force",10,[2,-2,1,0,0,0,0],"N.cm","si",true,null,null,1,false,false,0,0,"N*cm; Ncm; N cm; Newton*centimeters; Newton* centimetres; torque; work","LOINC","","Clinical","as a measurement of work, N.cm = 1/100 Joules;\nnote that N.m is the standard unit of measurement for torque (although dimensionally equivalent to Joule), and N.cm can also be thought of as a torqe unit","kg.m/s2","KG.M/S2","1",1,false],[false,"Newton second","N.s","N.S","force",1000,[1,-1,1,0,0,0,0],"N.s","si",true,null,null,1,false,false,0,0,"Newton*seconds; N*s; N s; Ns; impulse; imp","LOINC","","Clinical","standard unit of impulse","kg.m/s2","KG.M/S2","1",1,false],[false,"nanogram","ng","NG","mass",1e-9,[0,0,1,0,0,0,0],"ng",null,false,"M",null,1,false,false,0,0,"nanograms","LOINC","Mass","Clinical","",null,null,null,null,false],[false,"nanogram per 24 hour","ng/(24.h)","NG/(24.HR)","mass",1.1574074074074075e-14,[0,-1,1,0,0,0,0],"ng/h",null,false,"M",null,1,false,false,0,0,"ng/24hrs; ng/24 hrs; nanograms per 24 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"nanogram per 8 hour","ng/(8.h)","NG/(8.HR)","mass",3.4722222222222224e-14,[0,-1,1,0,0,0,0],"ng/h",null,false,"M",null,1,false,false,0,0,"ng/8hrs; ng/8 hrs; nanograms per 8 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"nanogram per million","ng/10*6","NG/(10*6)","mass",1e-15,[0,0,1,0,0,0,0],"ng/(106)",null,false,"M",null,1,false,false,0,0,"ng/10^6; ng per 10*6; 10^6; nanograms","LOINC","MNum","Clinical","",null,null,null,null,false],[false,"nanogram per day","ng/d","NG/D","mass",1.1574074074074075e-14,[0,-1,1,0,0,0,0],"ng/d",null,false,"M",null,1,false,false,0,0,"ng/dy; ng per day; nanograms ","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"nanogram per deciliter","ng/dL","NG/DL","mass",0.00001,[-3,0,1,0,0,0,0],"ng/dL",null,false,"M",null,1,false,false,0,0,"ng per dL; nanograms per deciliter; decilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"nanogram per gram","ng/g","NG/G","mass",1e-9,[0,0,0,0,0,0,0],"ng/g",null,false,"M",null,1,false,false,0,0,"ng/gm; ng per gm; nanograms per gram","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"nanogram per hour","ng/h","NG/HR","mass",2.777777777777778e-13,[0,-1,1,0,0,0,0],"ng/h",null,false,"M",null,1,false,false,0,0,"ng/hr; ng per hr; nanograms per hour","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"nanogram per kilogram","ng/kg","NG/KG","mass",1e-12,[0,0,0,0,0,0,0],"ng/kg",null,false,"M",null,1,false,false,0,0,"ng per kg; nanograms per kilogram","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"nanogram per kilogram per 8 hour","ng/kg/(8.h)","(NG/KG)/(8.HR)","mass",3.472222222222222e-17,[0,-1,0,0,0,0,0],"(ng/kg)/h",null,false,"M",null,1,false,false,0,0,"ng/(8.h.kg); ng/kg/8hrs; ng/kg/8 hrs; ng per kg per 8hrs; 8 hrs; nanograms per kilograms per 8 hours; shift","LOINC","MRtoRat ","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"nanogram per kilogram per hour","ng/kg/h","(NG/KG)/HR","mass",2.7777777777777775e-16,[0,-1,0,0,0,0,0],"(ng/kg)/h",null,false,"M",null,1,false,false,0,0,"ng/(kg.h); ng/kg/hr; ng per kg per hr; nanograms per kilograms per hour","LOINC","MRtoRat ","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"nanogram per kilogram per minute","ng/kg/min","(NG/KG)/MIN","mass",1.6666666666666667e-14,[0,-1,0,0,0,0,0],"(ng/kg)/min",null,false,"M",null,1,false,false,0,0,"ng/(kg.min); ng per kg per min; nanograms per kilograms per minute","LOINC","MRtoRat ","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"nanogram per liter","ng/L","NG/L","mass",0.000001,[-3,0,1,0,0,0,0],"ng/L",null,false,"M",null,1,false,false,0,0,"ng per L; nanograms per liter; litre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"nanogram per square meter","ng/m2","NG/M2","mass",1e-9,[-2,0,1,0,0,0,0],"ng/(m2)",null,false,"M",null,1,false,false,0,0,"ng/m^2; ng/sq. m; ng per m2; m^2; sq. meter; nanograms; meter squared; metre","LOINC","ArMass","Clinical","unit used to measure mass dose per patient body surface area",null,null,null,null,false],[false,"nanogram per milligram","ng/mg","NG/MG","mass",0.000001,[0,0,0,0,0,0,0],"ng/mg",null,false,"M",null,1,false,false,0,0,"ng per mg; nanograms","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"nanogram per milligram per hour","ng/mg/h","(NG/MG)/HR","mass",2.7777777777777777e-10,[0,-1,0,0,0,0,0],"(ng/mg)/h",null,false,"M",null,1,false,false,0,0,"ng/mg/hr; ng per mg per hr; nanograms per milligrams per hour","LOINC","MRtoRat ","Clinical","",null,null,null,null,false],[false,"nanogram per minute","ng/min","NG/MIN","mass",1.6666666666666667e-11,[0,-1,1,0,0,0,0],"ng/min",null,false,"M",null,1,false,false,0,0,"ng per min; nanograms","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"nanogram per millliiter","ng/mL","NG/ML","mass",0.001,[-3,0,1,0,0,0,0],"ng/mL",null,false,"M",null,1,false,false,0,0,"ng per mL; nanograms; millilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"nanogram per milliliter per hour","ng/mL/h","(NG/ML)/HR","mass",2.7777777777777776e-7,[-3,-1,1,0,0,0,0],"(ng/mL)/h",null,false,"M",null,1,false,false,0,0,"ng/mL/hr; ng per mL per mL; nanograms per milliliter per hour; nanogram per millilitre per hour; nanograms per millilitre per hour; enzymatic activity per volume; enzyme activity per milliliters","LOINC","CCnc","Clinical","tests that measure enzymatic activity",null,null,null,null,false],[false,"nanogram per second","ng/s","NG/S","mass",1e-9,[0,-1,1,0,0,0,0],"ng/s",null,false,"M",null,1,false,false,0,0,"ng/sec; ng per sec; nanograms per second","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"nanogram per enzyme unit","ng/U","NG/U","mass",9.963241120049634e-26,[0,1,1,0,0,0,0],"ng/U",null,false,"M",null,1,false,false,-1,0,"ng per U; nanograms per enzyme unit","LOINC","CMass","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)",null,null,null,null,false],[false,"nanokatal","nkat","NKAT","catalytic activity",602213670000000,[0,-1,0,0,0,0,0],"nkat","chemical",true,null,null,1,false,false,1,0,"nanokatals","LOINC","CAct","Clinical","kat is a unit of catalytic activity with base units = mol/s. Rarely used because its units are too large to practically express catalytic activity. See enzyme unit [U] which is the standard unit for catalytic activity.","mol/s","MOL/S","1",1,false],[false,"nanoliter","nL","NL","volume",1.0000000000000002e-12,[3,0,0,0,0,0,0],"nL","iso1000",true,null,null,1,false,false,0,0,"nanoliters; nanolitres","LOINC","Vol","Clinical","","l",null,"1",1,false],[false,"nanometer","nm","NM","length",1e-9,[1,0,0,0,0,0,0],"nm",null,false,"L",null,1,false,false,0,0,"nanometers; nanometres","LOINC","Len","Clinical","",null,null,null,null,false],[false,"nanometer per second per liter","nm/s/L","(NM/S)/L","length",0.000001,[-2,-1,0,0,0,0,0],"(nm/s)/L",null,false,"L",null,1,false,false,0,0,"nm/sec/liter; nm/sec/litre; nm per s per l; nm per sec per l; nanometers per second per liter; nanometre per second per litre; nanometres per second per litre","LOINC","VelCnc","Clinical","",null,null,null,null,false],[false,"nanomole","nmol","NMOL","amount of substance",602213670000000,[0,0,0,0,0,0,0],"nmol","si",true,null,null,1,false,false,1,0,"nanomoles","LOINC","Sub","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per 24 hour","nmol/(24.h)","NMOL/(24.HR)","amount of substance",6970065625,[0,-1,0,0,0,0,0],"nmol/h","si",true,null,null,1,false,false,1,0,"nmol/24hr; nmol/24 hr; nanomoles per 24 hours; nmol/day; nanomoles per day; nmol per day; nanomole/day; nanomol/day","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per day","nmol/d","NMOL/D","amount of substance",6970065625,[0,-1,0,0,0,0,0],"nmol/d","si",true,null,null,1,false,false,1,0,"nmol/day; nanomoles per day; nmol per day; nanomole/day; nanomol/day; nmol/24hr; nmol/24 hr; nanomoles per 24 hours; ","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per deciliter","nmol/dL","NMOL/DL","amount of substance",6022136700000000000,[-3,0,0,0,0,0,0],"nmol/dL","si",true,null,null,1,false,false,1,0,"nmol per dL; nanomoles per deciliter; nanomole per decilitre; nanomoles per decilitre; nanomole/deciliter; nanomole/decilitre; nanomol/deciliter; nanomol/decilitre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per gram","nmol/g","NMOL/G","amount of substance",602213670000000,[0,0,-1,0,0,0,0],"nmol/g","si",true,null,null,1,false,false,1,0,"nmol per gram; nanomoles per gram; nanomole/gram","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per hour per liter","nmol/h/L","(NMOL/HR)/L","amount of substance",167281575000000,[-3,-1,0,0,0,0,0],"(nmol/h)/L","si",true,null,null,1,false,false,1,0,"nmol/hrs/L; nmol per hrs per L; nanomoles per hours per liter; litre; enzymatic activity per volume; enzyme activities","LOINC","CCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per liter","nmol/L","NMOL/L","amount of substance",602213670000000000,[-3,0,0,0,0,0,0],"nmol/L","si",true,null,null,1,false,false,1,0,"nmol per L; nanomoles per liter; litre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per milligram","nmol/mg","NMOL/MG","amount of substance",602213670000000000,[0,0,-1,0,0,0,0],"nmol/mg","si",true,null,null,1,false,false,1,0,"nmol per mg; nanomoles per milligram","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per milligram per hour","nmol/mg/h","(NMOL/MG)/HR","amount of substance",167281575000000,[0,-1,-1,0,0,0,0],"(nmol/mg)/h","si",true,null,null,1,false,false,1,0,"nmol/mg/hr; nmol per mg per hr; nanomoles per milligrams per hour","LOINC","SCntRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per milligram of protein","nmol/mg{prot}","NMOL/MG","amount of substance",602213670000000000,[0,0,-1,0,0,0,0],"nmol/mg","si",true,null,null,1,false,false,1,0,"nanomoles; nmol/mg prot; nmol per mg prot","LOINC","Ratio; CCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per minute","nmol/min","NMOL/MIN","amount of substance",10036894500000,[0,-1,0,0,0,0,0],"nmol/min","si",true,null,null,1,false,false,1,0,"nmol per min; nanomoles per minute; milli enzyme units; enzyme activity per volume; enzymatic activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. nmol/min = mU (milli enzyme unit)","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per minute per milliliter","nmol/min/mL","(NMOL/MIN)/ML","amount of substance",10036894500000000000,[-3,-1,0,0,0,0,0],"(nmol/min)/mL","si",true,null,null,1,false,false,1,0,"nmol per min per mL; nanomoles per minutes per milliliter; millilitre; milli enzyme units per volume; enzyme activity; enzymatic activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. nmol/mL/min = mU/mL","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per milliliter","nmol/mL","NMOL/ML","amount of substance",602213670000000000000,[-3,0,0,0,0,0,0],"nmol/mL","si",true,null,null,1,false,false,1,0,"nmol per mL; nanomoles per milliliter; millilitre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per milliliter per hour","nmol/mL/h","(NMOL/ML)/HR","amount of substance",167281575000000000,[-3,-1,0,0,0,0,0],"(nmol/mL)/h","si",true,null,null,1,false,false,1,0,"nmol/mL/hr; nmol per mL per hr; nanomoles per milliliters per hour; millilitres; milli enzyme units per volume; enzyme activity; enzymatic activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min.","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per milliliter per minute","nmol/mL/min","(NMOL/ML)/MIN","amount of substance",10036894500000000000,[-3,-1,0,0,0,0,0],"(nmol/mL)/min","si",true,null,null,1,false,false,1,0,"nmol per mL per min; nanomoles per milliliters per min; millilitres; milli enzyme units per volume; enzyme activity; enzymatic activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. nmol/mL/min = mU/mL","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per millimole","nmol/mmol","NMOL/MMOL","amount of substance",0.000001,[0,0,0,0,0,0,0],"nmol/mmol","si",true,null,null,1,false,false,0,0,"nmol per mmol; nanomoles per millimole","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per millimole of creatinine","nmol/mmol{creat}","NMOL/MMOL","amount of substance",0.000001,[0,0,0,0,0,0,0],"nmol/mmol","si",true,null,null,1,false,false,0,0,"nanomoles","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per mole","nmol/mol","NMOL/MOL","amount of substance",1e-9,[0,0,0,0,0,0,0],"nmol/mol","si",true,null,null,1,false,false,0,0,"nmol per mole; nanomoles","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per nanomole","nmol/nmol","NMOL/NMOL","amount of substance",1,[0,0,0,0,0,0,0],"nmol/nmol","si",true,null,null,1,false,false,0,0,"nmol per nmol; nanomoles","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per second","nmol/s","NMOL/S","amount of substance",602213670000000,[0,-1,0,0,0,0,0],"nmol/s","si",true,null,null,1,false,false,1,0,"nmol/sec; nmol per sec; nanomoles per sercond; milli enzyme units; enzyme activity; enzymatic activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min.","10*23","10*23","6.0221367",6.0221367,false],[false,"nanomole per second per liter","nmol/s/L","(NMOL/S)/L","amount of substance",602213670000000000,[-3,-1,0,0,0,0,0],"(nmol/s)/L","si",true,null,null,1,false,false,1,0,"nmol/sec/L; nmol per s per L; nmol per sec per L; nanomoles per seconds per liter; litre; milli enzyme units per volume; enzyme activity; enzymatic activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min.","10*23","10*23","6.0221367",6.0221367,false],[false,"nanosecond","ns","NS","time",1e-9,[0,1,0,0,0,0,0],"ns",null,false,"T",null,1,false,false,0,0,"nanoseconds","LOINC","Time","Clinical","",null,null,null,null,false],[false,"nanoenzyme unit per milliliter","nU/mL","NU/ML","catalytic activity",10036894500000,[-3,-1,0,0,0,0,0],"nU/mL","chemical",true,null,null,1,false,false,1,0,"nU per mL; nanoenzyme units per milliliter; millilitre; enzymatic activity per volume; enzyme activity","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 fU = pmol/min","umol/min","UMOL/MIN","1",1,false],[false,"Ohm meter","Ohm.m","OHM.M","electric resistance",1000,[3,-1,1,0,0,-2,0],"Ω.m","si",true,null,null,1,false,false,0,0,"electric resistivity; meters; metres","LOINC","","Clinical","unit of electric resistivity","V/A","V/A","1",1,false],[false,"osmole per kilogram","osm/kg","OSM/KG","amount of substance (dissolved particles)",602213670000000000000,[0,0,-1,0,0,0,0],"osm/kg","chemical",true,null,null,1,false,false,1,0,"osm per kg; osmoles per kilogram; osmols","LOINC","Osmol","Clinical","","mol","MOL","1",1,false],[false,"osmole per liter","osm/L","OSM/L","amount of substance (dissolved particles)",6.0221366999999994e+26,[-3,0,0,0,0,0,0],"osm/L","chemical",true,null,null,1,false,false,1,0,"osm per L; osmoles per liter; litre; osmols","LOINC","Osmol","Clinical","","mol","MOL","1",1,false],[false,"picoampere","pA","PA","electric current",1e-12,[0,-1,0,0,0,1,0],"pA","si",true,null,null,1,false,false,0,0,"picoamperes","LOINC","","Clinical","equal to 10^-12 amperes","C/s","C/S","1",1,false],[false,"picogram","pg","PG","mass",1e-12,[0,0,1,0,0,0,0],"pg",null,false,"M",null,1,false,false,0,0,"picograms","LOINC","Mass; EntMass","Clinical","",null,null,null,null,false],[false,"picogram per deciliter","pg/dL","PG/DL","mass",9.999999999999999e-9,[-3,0,1,0,0,0,0],"pg/dL",null,false,"M",null,1,false,false,0,0,"pg per dL; picograms; decilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"picogram per liter","pg/L","PG/L","mass",1e-9,[-3,0,1,0,0,0,0],"pg/L",null,false,"M",null,1,false,false,0,0,"pg per L; picograms; litre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"picogram per milligram","pg/mg","PG/MG","mass",1e-9,[0,0,0,0,0,0,0],"pg/mg",null,false,"M",null,1,false,false,0,0,"pg per mg; picograms","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"picogram per milliliter","pg/mL","PG/ML","mass",0.000001,[-3,0,1,0,0,0,0],"pg/mL",null,false,"M",null,1,false,false,0,0,"pg per mL; picograms per milliliter; millilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"picogram per millimeter","pg/mm","PG/MM","mass",1e-9,[-1,0,1,0,0,0,0],"pg/mm",null,false,"M",null,1,false,false,0,0,"pg per mm; picogram/millimeter; picogram/millimetre; picograms per millimeter; millimetre","LOINC","Lineic Mass","Clinical","",null,null,null,null,false],[false,"picokatal","pkat","PKAT","catalytic activity",602213670000,[0,-1,0,0,0,0,0],"pkat","chemical",true,null,null,1,false,false,1,0,"pkats; picokatals","LOINC","CAct","Clinical","kat is a unit of catalytic activity with base units = mol/s. Rarely used because its units are too large to practically express catalytic activity. See enzyme unit [U] which is the standard unit for catalytic activity.","mol/s","MOL/S","1",1,false],[false,"picoliter","pL","PL","volume",1e-15,[3,0,0,0,0,0,0],"pL","iso1000",true,null,null,1,false,false,0,0,"picoliters; picolitres","LOINC","Vol","Clinical","","l",null,"1",1,false],[false,"picometer","pm","PM","length",1e-12,[1,0,0,0,0,0,0],"pm",null,false,"L",null,1,false,false,0,0,"picometers; picometres","LOINC","Len","Clinical","",null,null,null,null,false],[false,"picomole","pmol","PMOL","amount of substance",602213670000,[0,0,0,0,0,0,0],"pmol","si",true,null,null,1,false,false,1,0,"picomoles; pmols","LOINC","Sub","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per 24 hour","pmol/(24.h)","PMOL/(24.HR)","amount of substance",6970065.625,[0,-1,0,0,0,0,0],"pmol/h","si",true,null,null,1,false,false,1,0,"pmol/24hrs; pmol/24 hrs; pmol per 24 hrs; 24hrs; days; dy; picomoles per 24 hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per day","pmol/d","PMOL/D","amount of substance",6970065.625,[0,-1,0,0,0,0,0],"pmol/d","si",true,null,null,1,false,false,1,0,"pmol/dy; pmol per day; 24 hours; 24hrs; 24 hrs; picomoles","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per deciliter","pmol/dL","PMOL/DL","amount of substance",6022136700000000,[-3,0,0,0,0,0,0],"pmol/dL","si",true,null,null,1,false,false,1,0,"pmol per dL; picomoles per deciliter; decilitre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per gram","pmol/g","PMOL/G","amount of substance",602213670000,[0,0,-1,0,0,0,0],"pmol/g","si",true,null,null,1,false,false,1,0,"pmol per gm; picomoles per gram; picomole/gram","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per hour per milliliter ","pmol/h/mL","(PMOL/HR)/ML","amount of substance",167281575000000,[-3,-1,0,0,0,0,0],"(pmol/h)/mL","si",true,null,null,1,false,false,1,0,"pmol/hrs/mL; pmol per hrs per mL; picomoles per hour per milliliter; millilitre; micro enzyme units per volume; enzymatic activity; enzyme activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. ","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per liter","pmol/L","PMOL/L","amount of substance",602213670000000,[-3,0,0,0,0,0,0],"pmol/L","si",true,null,null,1,false,false,1,0,"picomole/liter; pmol per L; picomoles; litre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per minute","pmol/min","PMOL/MIN","amount of substance",10036894500,[0,-1,0,0,0,0,0],"pmol/min","si",true,null,null,1,false,false,1,0,"picomole/minute; pmol per min; picomoles per minute; micro enzyme units; enzymatic activity; enzyme activity","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. pmol/min = uU (micro enzyme unit)","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per milliliter","pmol/mL","PMOL/ML","amount of substance",602213670000000000,[-3,0,0,0,0,0,0],"pmol/mL","si",true,null,null,1,false,false,1,0,"picomole/milliliter; picomole/millilitre; pmol per mL; picomoles; millilitre; picomols; pmols","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picomole per micromole","pmol/umol","PMOL/UMOL","amount of substance",0.000001,[0,0,0,0,0,0,0],"pmol/μmol","si",true,null,null,1,false,false,0,0,"pmol/mcgmol; picomole/micromole; pmol per umol; pmol per mcgmol; picomoles ","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"picosecond","ps","PS","time",1e-12,[0,1,0,0,0,0,0],"ps",null,false,"T",null,1,false,false,0,0,"picoseconds; psec","LOINC","Time","Clinical","",null,null,null,null,false],[false,"picotesla","pT","PT","magnetic flux density",1e-9,[0,-1,1,0,0,-1,0],"pT","si",true,null,null,1,false,false,0,0,"picoteslas","LOINC","","Clinical","SI unit of magnetic field strength for magnetic field B","Wb/m2","WB/M2","1",1,false],[false,"enzyme unit per 12 hour","U/(12.h)","U/(12.HR)","catalytic activity",232335520833.33334,[0,-2,0,0,0,0,0],"U/h","chemical",true,null,null,1,false,false,1,0,"U/12hrs; U/ 12hrs; U per 12 hrs; 12hrs; enzyme units per 12 hours; enzyme activity; enzymatic activity per time; umol per min per 12 hours; micromoles per minute per 12 hours; umol/min/12hr","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per 2 hour","U/(2.h)","U/(2.HR)","catalytic activity",1394013125000,[0,-2,0,0,0,0,0],"U/h","chemical",true,null,null,1,false,false,1,0,"U/2hrs; U/ 2hrs; U per 2 hrs; 2hrs; enzyme units per 2 hours; enzyme activity; enzymatic activity per time; umol per minute per 2 hours; micromoles per minute; umol/min/2hr; umol per min per 2hr","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per 24 hour","U/(24.h)","U/(24.HR)","catalytic activity",116167760416.66667,[0,-2,0,0,0,0,0],"U/h","chemical",true,null,null,1,false,false,1,0,"U/24hrs; U/ 24hrs; U per 24 hrs; 24hrs; enzyme units per 24 hours; enzyme activity; enzymatic activity per time; micromoles per minute per 24 hours; umol/min/24hr; umol per min per 24hr","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per 10","U/10","U/10","catalytic activity",1003689450000000,[0,-1,0,0,0,0,0],"U","chemical",true,null,null,1,false,false,1,0,"enzyme unit/10; U per 10; enzyme units per 10; enzymatic activity; enzyme activity; micromoles per minute; umol/min/10","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per 10 billion","U/10*10","U/(10*10)","catalytic activity",1003689.45,[0,-1,0,0,0,0,0],"U/(1010)","chemical",true,null,null,1,false,false,1,0,"U per 10*10; enzyme units per 10*10; U per 10 billion; enzyme units; enzymatic activity; micromoles per minute per 10 billion; umol/min/10*10","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per trillion","U/10*12","U/(10*12)","catalytic activity",10036.8945,[0,-1,0,0,0,0,0],"U/(1012)","chemical",true,null,null,1,false,false,1,0,"enzyme unit/10*12; U per 10*12; enzyme units per 10*12; enzyme units per trillion; enzymatic activity; micromoles per minute per trillion; umol/min/10*12; umol per min per 10*12","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per million","U/10*6","U/(10*6)","catalytic activity",10036894500,[0,-1,0,0,0,0,0],"U/(106)","chemical",true,null,null,1,false,false,1,0,"enzyme unit/10*6; U per 10*6; enzyme units per 10*6; enzyme units; enzymatic activity per volume; micromoles per minute per million; umol/min/10*6; umol per min per 10*6","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per billion","U/10*9","U/(10*9)","catalytic activity",10036894.5,[0,-1,0,0,0,0,0],"U/(109)","chemical",true,null,null,1,false,false,1,0,"enzyme unit/10*9; U per 10*9; enzyme units per 10*9; enzymatic activity per volume; micromoles per minute per billion; umol/min/10*9; umol per min per 10*9","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per day","U/d","U/D","catalytic activity",116167760416.66667,[0,-2,0,0,0,0,0],"U/d","chemical",true,null,null,1,false,false,1,0,"U/dy; enzyme units per day; enzyme units; enzyme activity; enzymatic activity per time; micromoles per minute per day; umol/min/day; umol per min per day","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per deciliter","U/dL","U/DL","catalytic activity",100368945000000000000,[-3,-1,0,0,0,0,0],"U/dL","chemical",true,null,null,1,false,false,1,0,"U per dL; enzyme units per deciliter; decilitre; micromoles per minute per deciliter; umol/min/dL; umol per min per dL","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per gram","U/g","U/G","catalytic activity",10036894500000000,[0,-1,-1,0,0,0,0],"U/g","chemical",true,null,null,1,false,false,1,0,"U/gm; U per gm; enzyme units per gram; micromoles per minute per gram; umol/min/g; umol per min per g","LOINC","CCnt","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per hour","U/h","U/HR","catalytic activity",2788026250000,[0,-2,0,0,0,0,0],"U/h","chemical",true,null,null,1,false,false,1,0,"U/hr; U per hr; enzyme units per hour; micromoles per minute per hour; umol/min/hr; umol per min per hr","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per liter","U/L","U/L","catalytic activity",10036894500000000000,[-3,-1,0,0,0,0,0],"U/L","chemical",true,null,null,1,false,false,1,0,"enzyme unit/liter; enzyme unit/litre; U per L; enzyme units per liter; enzyme unit per litre; micromoles per minute per liter; umol/min/L; umol per min per L","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per minute","U/min","U/MIN","catalytic activity",167281575000000,[0,-2,0,0,0,0,0],"U/min","chemical",true,null,null,1,false,false,1,0,"enzyme unit/minute; U per min; enzyme units; umol/min/min; micromoles per minute per minute; micromoles per min per min; umol","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per milliliter","U/mL","U/ML","catalytic activity",1.00368945e+22,[-3,-1,0,0,0,0,0],"U/mL","chemical",true,null,null,1,false,false,1,0,"U per mL; enzyme units per milliliter; millilitre; micromoles per minute per milliliter; umol/min/mL; umol per min per mL","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"enzyme unit per second","U/s","U/S","catalytic activity",10036894500000000,[0,-2,0,0,0,0,0],"U/s","chemical",true,null,null,1,false,false,1,0,"U/sec; U per second; enzyme units per second; micromoles per minute per second; umol/min/sec; umol per min per sec","LOINC","CRat","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min)","umol/min","UMOL/MIN","1",1,false],[false,"micro international unit","u[IU]","U[IU]","arbitrary",0.000001,[0,0,0,0,0,0,0],"μi.U.","chemical",true,null,null,1,false,true,0,0,"uIU; u IU; microinternational units","LOINC","Arb","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"micro international unit per liter","u[IU]/L","U[IU]/L","arbitrary",0.001,[-3,0,0,0,0,0,0],"(μi.U.)/L","chemical",true,null,null,1,false,true,0,0,"uIU/L; u IU/L; uIU per L; microinternational units per liter; litre; ","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"micro international unit per milliliter","u[IU]/mL","U[IU]/ML","arbitrary",1,[-3,0,0,0,0,0,0],"(μi.U.)/mL","chemical",true,null,null,1,false,true,0,0,"uIU/mL; u IU/mL; uIU per mL; microinternational units per milliliter; millilitre","LOINC","ACnc","Clinical","International units (IU) are analyte and reference specimen specific arbitrary units (held at WHO)","[iU]","[IU]","1",1,false],[false,"microequivalent","ueq","UEQ","amount of substance",602213670000000000,[0,0,0,0,0,0,0],"μeq","chemical",true,null,null,1,false,false,0,1,"microequivalents; 10^-6 equivalents; 10-6 equivalents","LOINC","Sub","Clinical","","mol","MOL","1",1,false],[false,"microequivalent per liter","ueq/L","UEQ/L","amount of substance",602213670000000000000,[-3,0,0,0,0,0,0],"μeq/L","chemical",true,null,null,1,false,false,0,1,"ueq per liter; litre; microequivalents","LOINC","MCnc","Clinical","","mol","MOL","1",1,false],[false,"microequivalent per milliliter","ueq/mL","UEQ/ML","amount of substance",6.0221367000000003e+23,[-3,0,0,0,0,0,0],"μeq/mL","chemical",true,null,null,1,false,false,0,1,"ueq per milliliter; millilitre; microequivalents","LOINC","MCnc","Clinical","","mol","MOL","1",1,false],[false,"microgram","ug","UG","mass",0.000001,[0,0,1,0,0,0,0],"μg",null,false,"M",null,1,false,false,0,0,"mcg; micrograms; 10^-6 grams; 10-6 grams","LOINC","Mass","Clinical","",null,null,null,null,false],[false,"microgram per 100 gram","ug/(100.g)","UG/(100.G)","mass",1e-8,[0,0,0,0,0,0,0],"μg/g",null,false,"M",null,1,false,false,0,0,"ug/100gm; ug/100 gm; mcg; ug per 100g; 100 gm; mcg per 100g; micrograms per 100 grams","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"microgram per 24 hour","ug/(24.h)","UG/(24.HR)","mass",1.1574074074074074e-11,[0,-1,1,0,0,0,0],"μg/h",null,false,"M",null,1,false,false,0,0,"ug/24hrs; ug/24 hrs; mcg/24hrs; ug per 24hrs; mcg per 24hrs; 24 hrs; micrograms per 24 hours","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"microgram per 8 hour","ug/(8.h)","UG/(8.HR)","mass",3.472222222222222e-11,[0,-1,1,0,0,0,0],"μg/h",null,false,"M",null,1,false,false,0,0,"ug/8hrs; ug/8 hrs; mcg/8hrs; ug per 8hrs; mcg per 8hrs; 8 hrs; micrograms per 8 hours; shift","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"microgram per square foot (international)","ug/[sft_i]","UG/[SFT_I]","mass",0.000010763910416709721,[-2,0,1,0,0,0,0],"μg",null,false,"M",null,1,false,false,0,0,"ug/sft; ug/ft2; ug/ft^2; ug/sq. ft; micrograms; sq. foot; foot squared","LOINC","ArMass","Clinical","",null,null,null,null,false],[false,"microgram per day","ug/d","UG/D","mass",1.1574074074074074e-11,[0,-1,1,0,0,0,0],"μg/d",null,false,"M",null,1,false,false,0,0,"ug/dy; mcg/dy; ug per day; mcg; micrograms per day","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"microgram per deciliter","ug/dL","UG/DL","mass",0.009999999999999998,[-3,0,1,0,0,0,0],"μg/dL",null,false,"M",null,1,false,false,0,0,"ug per dL; mcg/dl; mcg per dl; micrograms per deciliter; decilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"microgram per gram","ug/g","UG/G","mass",0.000001,[0,0,0,0,0,0,0],"μg/g",null,false,"M",null,1,false,false,0,0,"ug per gm; mcg/gm; mcg per g; micrograms per gram","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"microgram per hour","ug/h","UG/HR","mass",2.7777777777777777e-10,[0,-1,1,0,0,0,0],"μg/h",null,false,"M",null,1,false,false,0,0,"ug/hr; mcg/hr; mcg per hr; ug per hr; ug per hour; micrograms","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"microgram per kilogram","ug/kg","UG/KG","mass",9.999999999999999e-10,[0,0,0,0,0,0,0],"μg/kg",null,false,"M",null,1,false,false,0,0,"ug per kg; mcg/kg; mcg per kg; micrograms per kilogram","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"microgram per kilogram per 8 hour","ug/kg/(8.h)","(UG/KG)/(8.HR)","mass",3.472222222222222e-14,[0,-1,0,0,0,0,0],"(μg/kg)/h",null,false,"M",null,1,false,false,0,0,"ug/kg/8hrs; mcg/kg/8hrs; ug/kg/8 hrs; mcg/kg/8 hrs; ug per kg per 8hrs; 8 hrs; mcg per kg per 8hrs; micrograms per kilograms per 8 hours; shift","LOINC","","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"microgram per kilogram per day","ug/kg/d","(UG/KG)/D","mass",1.1574074074074072e-14,[0,-1,0,0,0,0,0],"(μg/kg)/d",null,false,"M",null,1,false,false,0,0,"ug/(kg.d); ug/kg/dy; mcg/kg/day; ug per kg per dy; 24 hours; 24hrs; mcg; kilograms; microgram per kilogram and day","LOINC","","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"microgram per kilogram per hour","ug/kg/h","(UG/KG)/HR","mass",2.7777777777777774e-13,[0,-1,0,0,0,0,0],"(μg/kg)/h",null,false,"M",null,1,false,false,0,0,"ug/(kg.h); ug/kg/hr; mcg/kg/hr; ug per kg per hr; mcg per kg per hr; kilograms","LOINC","","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"microgram per kilogram per minute","ug/kg/min","(UG/KG)/MIN","mass",1.6666666666666664e-11,[0,-1,0,0,0,0,0],"(μg/kg)/min",null,false,"M",null,1,false,false,0,0,"ug/kg/min; ug/kg/min; mcg/kg/min; ug per kg per min; mcg; micrograms per kilograms per minute ","LOINC","","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"microgram per liter","ug/L","UG/L","mass",0.001,[-3,0,1,0,0,0,0],"μg/L",null,false,"M",null,1,false,false,0,0,"mcg/L; ug per L; mcg; micrograms per liter; litre ","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"microgram per liter per 24 hour","ug/L/(24.h)","(UG/L)/(24.HR)","mass",1.1574074074074074e-8,[-3,-1,1,0,0,0,0],"(μg/L)/h",null,false,"M",null,1,false,false,0,0,"ug/L/24hrs; ug/L/24 hrs; mcg/L/24hrs; ug per L per 24hrs; 24 hrs; day; dy mcg; micrograms per liters per 24 hours; litres","LOINC","","Clinical","unit used to measure mass dose rate per patient body mass",null,null,null,null,false],[false,"microgram per square meter","ug/m2","UG/M2","mass",0.000001,[-2,0,1,0,0,0,0],"μg/(m2)",null,false,"M",null,1,false,false,0,0,"ug/m^2; ug/sq. m; mcg/m2; mcg/m^2; mcg/sq. m; ug per m2; m^2; sq. meter; mcg; micrograms per square meter; meter squared; metre","LOINC","ArMass","Clinical","unit used to measure mass dose per patient body surface area",null,null,null,null,false],[false,"microgram per cubic meter","ug/m3","UG/M3","mass",0.000001,[-3,0,1,0,0,0,0],"μg/(m3)",null,false,"M",null,1,false,false,0,0,"ug/m^3; ug/cu. m; mcg/m3; mcg/m^3; mcg/cu. m; ug per m3; ug per m^3; ug per cu. m; mcg; micrograms per cubic meter; meter cubed; metre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"microgram per milligram","ug/mg","UG/MG","mass",0.001,[0,0,0,0,0,0,0],"μg/mg",null,false,"M",null,1,false,false,0,0,"ug per mg; mcg/mg; mcg per mg; micromilligrams per milligram","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"microgram per minute","ug/min","UG/MIN","mass",1.6666666666666667e-8,[0,-1,1,0,0,0,0],"μg/min",null,false,"M",null,1,false,false,0,0,"ug per min; mcg/min; mcg per min; microminutes per minute","LOINC","MRat","Clinical","",null,null,null,null,false],[false,"microgram per milliliter","ug/mL","UG/ML","mass",1,[-3,0,1,0,0,0,0],"μg/mL",null,false,"M",null,1,false,false,0,0,"ug per mL; mcg/mL; mcg per mL; micrograms per milliliter; millilitre","LOINC","MCnc","Clinical","",null,null,null,null,false],[false,"microgram per millimole","ug/mmol","UG/MMOL","mass",1.660540186674939e-27,[0,0,1,0,0,0,0],"μg/mmol",null,false,"M",null,1,false,false,-1,0,"ug per mmol; mcg/mmol; mcg per mmol; micrograms per millimole","LOINC","Ratio","Clinical","",null,null,null,null,false],[false,"microgram per nanogram","ug/ng","UG/NG","mass",999.9999999999999,[0,0,0,0,0,0,0],"μg/ng",null,false,"M",null,1,false,false,0,0,"ug per ng; mcg/ng; mcg per ng; micrograms per nanogram","LOINC","MCnt","Clinical","",null,null,null,null,false],[false,"microkatal","ukat","UKAT","catalytic activity",602213670000000000,[0,-1,0,0,0,0,0],"μkat","chemical",true,null,null,1,false,false,1,0,"microkatals; ukats","LOINC","CAct","Clinical","kat is a unit of catalytic activity with base units = mol/s. Rarely used because its units are too large to practically express catalytic activity. See enzyme unit [U] which is the standard unit for catalytic activity.","mol/s","MOL/S","1",1,false],[false,"microliter","uL","UL","volume",1e-9,[3,0,0,0,0,0,0],"μL","iso1000",true,null,null,1,false,false,0,0,"microliters; microlitres; mcl","LOINC","Vol","Clinical","","l",null,"1",1,false],[false,"microliter per 2 hour","uL/(2.h)","UL/(2.HR)","volume",1.388888888888889e-13,[3,-1,0,0,0,0,0],"μL/h","iso1000",true,null,null,1,false,false,0,0,"uL/2hrs; uL/2 hrs; mcg/2hr; mcg per 2hr; uL per 2hr; uL per 2 hrs; microliters per 2 hours; microlitres ","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"microliter per hour","uL/h","UL/HR","volume",2.777777777777778e-13,[3,-1,0,0,0,0,0],"μL/h","iso1000",true,null,null,1,false,false,0,0,"uL/hr; mcg/hr; mcg per hr; uL per hr; microliters per hour; microlitres","LOINC","VRat","Clinical","","l",null,"1",1,false],[false,"micrometer","um","UM","length",0.000001,[1,0,0,0,0,0,0],"μm",null,false,"L",null,1,false,false,0,0,"micrometers; micrometres; μm; microns","LOINC","Len","Clinical","Unit of length that is usually used in tests related to the eye",null,null,null,null,false],[false,"microns per second","um/s","UM/S","length",0.000001,[1,-1,0,0,0,0,0],"μm/s",null,false,"L",null,1,false,false,0,0,"um/sec; micron/second; microns/second; um per sec; micrometers per second; micrometres","LOINC","Vel","Clinical","",null,null,null,null,false],[false,"micromole","umol","UMOL","amount of substance",602213670000000000,[0,0,0,0,0,0,0],"μmol","si",true,null,null,1,false,false,1,0,"micromoles; umols","LOINC","Sub","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per 2 hour","umol/(2.h)","UMOL/(2.HR)","amount of substance",83640787500000,[0,-1,0,0,0,0,0],"μmol/h","si",true,null,null,1,false,false,1,0,"umol/2hrs; umol/2 hrs; umol per 2 hrs; 2hrs; micromoles per 2 hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per 24 hour","umol/(24.h)","UMOL/(24.HR)","amount of substance",6970065625000,[0,-1,0,0,0,0,0],"μmol/h","si",true,null,null,1,false,false,1,0,"umol/24hrs; umol/24 hrs; umol per 24 hrs; per 24hrs; micromoles per 24 hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per 8 hour","umol/(8.h)","UMOL/(8.HR)","amount of substance",20910196875000,[0,-1,0,0,0,0,0],"μmol/h","si",true,null,null,1,false,false,1,0,"umol/8hr; umol/8 hr; umol per 8 hr; umol per 8hr; umols per 8hr; umol per 8 hours; micromoles per 8 hours; shift","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per day","umol/d","UMOL/D","amount of substance",6970065625000,[0,-1,0,0,0,0,0],"μmol/d","si",true,null,null,1,false,false,1,0,"umol/day; umol per day; umols per day; umol per days; micromoles per days; umol/24hr; umol/24 hr; umol per 24 hr; umol per 24hr; umols per 24hr; umol per 24 hours; micromoles per 24 hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per deciliter","umol/dL","UMOL/DL","amount of substance",6.0221367e+21,[-3,0,0,0,0,0,0],"μmol/dL","si",true,null,null,1,false,false,1,0,"micromole/deciliter; micromole/decilitre; umol per dL; micromoles per deciliters; micromole per decilitres","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per gram","umol/g","UMOL/G","amount of substance",602213670000000000,[0,0,-1,0,0,0,0],"μmol/g","si",true,null,null,1,false,false,1,0,"micromole/gram; umol per g; micromoles per gram","LOINC","SCnt; Ratio","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per hour","umol/h","UMOL/HR","amount of substance",167281575000000,[0,-1,0,0,0,0,0],"μmol/h","si",true,null,null,1,false,false,1,0,"umol/hr; umol per hr; umol per hour; micromoles per hours","LOINC","SRat","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per kilogram","umol/kg","UMOL/KG","amount of substance",602213670000000,[0,0,-1,0,0,0,0],"μmol/kg","si",true,null,null,1,false,false,1,0,"umol per kg; micromoles per kilogram","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per liter","umol/L","UMOL/L","amount of substance",602213670000000000000,[-3,0,0,0,0,0,0],"μmol/L","si",true,null,null,1,false,false,1,0,"micromole/liter; micromole/litre; umol per liter; micromoles per liter; litre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per liter per hour","umol/L/h","(UMOL/L)/HR","amount of substance",167281575000000000,[-3,-1,0,0,0,0,0],"(μmol/L)/h","si",true,null,null,1,false,false,1,0,"umol/liter/hr; umol/litre/hr; umol per L per hr; umol per liter per hour; micromoles per liters per hour; litre","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min; umol/L/h is a derived unit of enzyme units","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per milligram","umol/mg","UMOL/MG","amount of substance",602213670000000000000,[0,0,-1,0,0,0,0],"μmol/mg","si",true,null,null,1,false,false,1,0,"micromole/milligram; umol per mg; micromoles per milligram","LOINC","SCnt","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per minute","umol/min","UMOL/MIN","amount of substance",10036894500000000,[0,-1,0,0,0,0,0],"μmol/min","si",true,null,null,1,false,false,1,0,"micromole/minute; umol per min; micromoles per minute; enzyme units","LOINC","CAct","Clinical","unit for the enzyme unit U = umol/min","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per minute per gram","umol/min/g","(UMOL/MIN)/G","amount of substance",10036894500000000,[0,-1,-1,0,0,0,0],"(μmol/min)/g","si",true,null,null,1,false,false,1,0,"umol/min/gm; umol per min per gm; micromoles per minutes per gram; U/g; enzyme units","LOINC","CCnt","Clinical","unit for the enzyme unit U = umol/min. umol/min/g = U/g","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per minute per liter","umol/min/L","(UMOL/MIN)/L","amount of substance",10036894500000000000,[-3,-1,0,0,0,0,0],"(μmol/min)/L","si",true,null,null,1,false,false,1,0,"umol/min/liter; umol/minute/liter; micromoles per minutes per liter; litre; enzyme units; U/L","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. umol/min/L = U/L","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per milliliter","umol/mL","UMOL/ML","amount of substance",6.0221367000000003e+23,[-3,0,0,0,0,0,0],"μmol/mL","si",true,null,null,1,false,false,1,0,"umol per mL; micromoles per milliliter; millilitre","LOINC","SCnc","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per milliliter per minute","umol/mL/min","(UMOL/ML)/MIN","amount of substance",1.00368945e+22,[-3,-1,0,0,0,0,0],"(μmol/mL)/min","si",true,null,null,1,false,false,1,0,"umol per mL per min; micromoles per milliliters per minute; millilitres","LOINC","CCnc","Clinical","unit for the enzyme unit U = umol/min. umol/mL/min = U/mL","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per millimole","umol/mmol","UMOL/MMOL","amount of substance",0.001,[0,0,0,0,0,0,0],"μmol/mmol","si",true,null,null,1,false,false,0,0,"umol per mmol; micromoles per millimole","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per mole","umol/mol","UMOL/MOL","amount of substance",0.000001,[0,0,0,0,0,0,0],"μmol/mol","si",true,null,null,1,false,false,0,0,"umol per mol; micromoles per mole","LOINC","SRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"micromole per micromole","umol/umol","UMOL/UMOL","amount of substance",1,[0,0,0,0,0,0,0],"μmol/μmol","si",true,null,null,1,false,false,0,0,"umol per umol; micromoles per micromole","LOINC","Srto; SFr; EntSRto","Clinical","","10*23","10*23","6.0221367",6.0221367,false],[false,"microOhm","uOhm","UOHM","electric resistance",0.001,[2,-1,1,0,0,-2,0],"μΩ","si",true,null,null,1,false,false,0,0,"microOhms; µΩ","LOINC","","Clinical","unit of electric resistance","V/A","V/A","1",1,false],[false,"microsecond","us","US","time",0.000001,[0,1,0,0,0,0,0],"μs",null,false,"T",null,1,false,false,0,0,"microseconds","LOINC","Time","Clinical","",null,null,null,null,false],[false,"micro enzyme unit per gram","uU/g","UU/G","catalytic activity",10036894500,[0,-1,-1,0,0,0,0],"μU/g","chemical",true,null,null,1,false,false,1,0,"uU per gm; micro enzyme units per gram; micro enzymatic activity per mass; enzyme activity","LOINC","CCnt","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 uU = 1pmol/min","umol/min","UMOL/MIN","1",1,false],[false,"micro enzyme unit per liter","uU/L","UU/L","catalytic activity",10036894500000,[-3,-1,0,0,0,0,0],"μU/L","chemical",true,null,null,1,false,false,1,0,"uU per L; micro enzyme units per liter; litre; enzymatic activity per volume; enzyme activity ","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 uU = 1pmol/min","umol/min","UMOL/MIN","1",1,false],[false,"micro enzyme unit per milliliter","uU/mL","UU/ML","catalytic activity",10036894500000000,[-3,-1,0,0,0,0,0],"μU/mL","chemical",true,null,null,1,false,false,1,0,"uU per mL; micro enzyme units per milliliter; millilitre; enzymatic activity per volume; enzyme activity","LOINC","CCnc","Clinical","1 U is the standard enzyme unit which equals 1 micromole substrate catalyzed per minute (1 umol/min); 1 uU = 1pmol/min","umol/min","UMOL/MIN","1",1,false],[false,"microvolt","uV","UV","electric potential",0.001,[2,-2,1,0,0,-1,0],"μV","si",true,null,null,1,false,false,0,0,"microvolts","LOINC","Elpot","Clinical","unit of electric potential (voltage)","J/C","J/C","1",1,false]]}} -},{}],59:[function(require,module,exports){ +},{}],60:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -10286,7 +10350,7 @@ var Ucum = { exports.Ucum = Ucum; -},{}],60:[function(require,module,exports){ +},{}],61:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -10599,7 +10663,7 @@ class Dimension { exports.Dimension = Dimension; -},{"./config.js":59,"is-integer":74}],61:[function(require,module,exports){ +},{"./config.js":60,"is-integer":75}],62:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -10721,7 +10785,7 @@ function unpackArray(obj) { } -},{}],62:[function(require,module,exports){ +},{}],63:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -10865,7 +10929,7 @@ class Prefix { exports.Prefix = Prefix; -},{"./config.js":59}],63:[function(require,module,exports){ +},{"./config.js":60}],64:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -10996,7 +11060,7 @@ const PrefixTables = { exports.PrefixTables = PrefixTables; -},{}],64:[function(require,module,exports){ +},{}],65:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -11232,7 +11296,7 @@ var _default = new UcumFunctions(); // one singleton instance exports.default = _default; -},{}],65:[function(require,module,exports){ +},{}],66:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -11331,7 +11395,7 @@ function getSynonyms(theSyn) { } // end getSynonyms -},{"./unitTables.js":71}],66:[function(require,module,exports){ +},{"./unitTables.js":72}],67:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -11386,7 +11450,7 @@ var ucumJsonDefs = new UcumJsonDefs(); exports.ucumJsonDefs = ucumJsonDefs; -},{"../data/ucumDefs.min.json":58,"./jsonArrayPack.js":61,"./prefix.js":62,"./prefixTables.js":63,"./unit.js":69,"./unitTables.js":71}],67:[function(require,module,exports){ +},{"../data/ucumDefs.min.json":59,"./jsonArrayPack.js":62,"./prefix.js":63,"./prefixTables.js":64,"./unit.js":70,"./unitTables.js":72}],68:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -12073,7 +12137,7 @@ UcumLhcUtils.getInstance = function () { }; -},{"./config.js":59,"./ucumInternalUtils.js":65,"./ucumJsonDefs.js":66,"./unitString.js":70,"./unitTables.js":71}],68:[function(require,module,exports){ +},{"./config.js":60,"./ucumInternalUtils.js":66,"./ucumJsonDefs.js":67,"./unitString.js":71,"./unitTables.js":72}],69:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -12095,7 +12159,7 @@ var UnitTables = require("./unitTables.js").UnitTables; exports.UnitTables = UnitTables; -},{"./config.js":59,"./ucumLhcUtils.js":67,"./unitTables.js":71}],69:[function(require,module,exports){ +},{"./config.js":60,"./ucumLhcUtils.js":68,"./unitTables.js":72}],70:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -13153,7 +13217,7 @@ class Unit { exports.Unit = Unit; -},{"./config.js":59,"./dimension.js":60,"./ucumFunctions.js":64,"./ucumInternalUtils.js":65,"./unitTables.js":71,"is-integer":74}],70:[function(require,module,exports){ +},{"./config.js":60,"./dimension.js":61,"./ucumFunctions.js":65,"./ucumInternalUtils.js":66,"./unitTables.js":72,"is-integer":75}],71:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -14604,7 +14668,7 @@ UnitString.getInstance(); */ -},{"./config.js":59,"./prefixTables.js":63,"./ucumInternalUtils.js":65,"./unit.js":69,"./unitTables.js":71}],71:[function(require,module,exports){ +},{"./config.js":60,"./prefixTables.js":64,"./ucumInternalUtils.js":66,"./unit.js":70,"./unitTables.js":72}],72:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { @@ -15226,7 +15290,7 @@ const UnitTables = { exports.UnitTables = UnitTables; -},{"./config.js":59}],72:[function(require,module,exports){ +},{"./config.js":60}],73:[function(require,module,exports){ /** * @license * MIT License @@ -21483,14 +21547,14 @@ exports.UnitTables = UnitTables; })); -},{}],73:[function(require,module,exports){ +},{}],74:[function(require,module,exports){ 'use strict'; module.exports = Number.isFinite || function (value) { return !(typeof value !== 'number' || value !== value || value === Infinity || value === -Infinity); }; -},{}],74:[function(require,module,exports){ +},{}],75:[function(require,module,exports){ // https://github.com/paulmillr/es6-shim // http://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.isinteger var isFinite = require("is-finite"); @@ -21500,7 +21564,7 @@ module.exports = Number.isInteger || function(val) { Math.floor(val) === val; }; -},{"is-finite":73}],75:[function(require,module,exports){ +},{"is-finite":74}],76:[function(require,module,exports){ 'use strict'; Object.defineProperty(exports, '__esModule', { value: true }); diff --git a/src/datatypes/bigint.ts b/src/datatypes/bigint.ts new file mode 100644 index 000000000..948dddb00 --- /dev/null +++ b/src/datatypes/bigint.ts @@ -0,0 +1,17 @@ +// By default, BigInt throws a TypeError if you attempt to JSON.stringify it. +// You can avoid the TypeError by defining a `toJSON()` function for BigInt. +// We will use the same serialization approach as FHIR uses for integer64: a string. +// See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt#use_within_json +// See: https://hl7.org/fhir/R5/json.html#primitive + +declare global { + interface BigInt { + toJSON?(): unknown; + } +} + +if (BigInt.prototype.toJSON === undefined) { + BigInt.prototype.toJSON = function () { + return this.toString(); + }; +} diff --git a/src/datatypes/datatypes.ts b/src/datatypes/datatypes.ts index aa00c71cd..ec689cc88 100644 --- a/src/datatypes/datatypes.ts +++ b/src/datatypes/datatypes.ts @@ -1,3 +1,4 @@ +export * from './bigint'; export * from './logic'; export * from './clinical'; export * from './uncertainty'; diff --git a/src/elm/arithmetic.ts b/src/elm/arithmetic.ts index 352d53787..9c3983e0f 100644 --- a/src/elm/arithmetic.ts +++ b/src/elm/arithmetic.ts @@ -182,8 +182,19 @@ export class TruncatedDivide extends Expression { return null; } - const quotient = args.reduce((x: number, y: number) => x / y); - const truncatedQuotient = quotient >= 0 ? Math.floor(quotient) : Math.ceil(quotient); + let truncatedQuotient: number | bigint; + if (typeof args[0] === 'bigint') { + // bigint division always truncates + try { + truncatedQuotient = args.reduce((x: bigint, y: bigint) => x / y); + } catch { + // bigint divide by 0 throws an error + return null; + } + } else { + const quotient = args.reduce((x: number, y: number) => x / y); + truncatedQuotient = quotient >= 0 ? Math.floor(quotient) : Math.ceil(quotient); + } if (MathUtil.overflowsOrUnderflows(truncatedQuotient)) { return null; @@ -205,7 +216,7 @@ export class Modulo extends Expression { const modulo = args.reduce((x: number, y: number) => x % y); - return MathUtil.decimalOrNull(modulo); + return MathUtil.decimalLongOrNull(modulo); } } @@ -264,6 +275,8 @@ export class Abs extends Expression { return null; } else if (arg.isQuantity) { return new Quantity(Math.abs(arg.value), arg.unit); + } else if (typeof arg === 'bigint') { + return arg < 0n ? -arg : arg; } else { return Math.abs(arg); } @@ -281,6 +294,8 @@ export class Negate extends Expression { return null; } else if (arg.isQuantity) { return new Quantity(arg.value * -1, arg.unit); + } else if (typeof arg === 'bigint') { + return arg * -1n; } else { return arg * -1; } @@ -371,7 +386,7 @@ export class Power extends Expression { return null; } - const power = args.reduce((x: number, y: number) => Math.pow(x, y)); + const power = args.reduce((x: any, y: any) => x ** y); if (MathUtil.overflowsOrUnderflows(power)) { return null; diff --git a/src/elm/literal.ts b/src/elm/literal.ts index badaf09dd..94c7a4e23 100644 --- a/src/elm/literal.ts +++ b/src/elm/literal.ts @@ -72,7 +72,7 @@ export class IntegerLiteral extends Literal { export class LongLiteral extends Literal { constructor(json: any) { super(json); - this.value = parseInt(this.value, 10); + this.value = BigInt(this.value); } // Define a simple getter to allow type-checking of this class without instanceof diff --git a/src/elm/type.ts b/src/elm/type.ts index 4ff5b78e5..5758f36ee 100644 --- a/src/elm/type.ts +++ b/src/elm/type.ts @@ -151,8 +151,8 @@ export class ToInteger extends Expression { if (isValidInteger(arg)) { return arg; } - } else if (typeof arg === 'string') { - const integer = parseInt(arg); + } else if (typeof arg === 'string' || typeof arg === 'bigint') { + const integer = Number(arg); if (isValidInteger(integer)) { return integer; } @@ -170,17 +170,21 @@ export class ToLong extends Expression { async exec(ctx: Context) { const arg = await this.execArgs(ctx); - if (typeof arg === 'number') { + if (typeof arg === 'bigint') { if (isValidLong(arg)) { return arg; } - } else if (typeof arg === 'string') { - const long = parseInt(arg); - if (isValidLong(long)) { - return long; + } else if (typeof arg === 'number' || typeof arg === 'string') { + try { + const long = BigInt(arg); + if (isValidLong(long)) { + return long; + } + } catch { + return null; } } else if (typeof arg === 'boolean') { - return arg ? 1 : 0; + return arg ? 1n : 0n; } return null; } diff --git a/src/runtime/context.ts b/src/runtime/context.ts index 96a39e1d6..02be4c70f 100644 --- a/src/runtime/context.ts +++ b/src/runtime/context.ts @@ -326,8 +326,9 @@ export class Context { case '{urn:hl7-org:elm-types:r1}Decimal': return typeof val === 'number'; case '{urn:hl7-org:elm-types:r1}Integer': - case '{urn:hl7-org:elm-types:r1}Long': return typeof val === 'number' && Math.floor(val) === val; + case '{urn:hl7-org:elm-types:r1}Long': + return typeof val === 'bigint'; case '{urn:hl7-org:elm-types:r1}String': return typeof val === 'string'; case '{urn:hl7-org:elm-types:r1}Concept': @@ -374,7 +375,7 @@ export class Context { } else if (inst.isIntegerLiteral) { return typeof val === 'number' && Math.floor(val) === val; } else if (inst.isLongLiteral) { - return typeof val === 'number' && Math.floor(val) === val; + return typeof val === 'bigint'; } else if (inst.isStringLiteral) { return typeof val === 'string'; } else if (inst.isCode) { diff --git a/src/util/math.ts b/src/util/math.ts index c2c9e8b49..1d2744dc1 100644 --- a/src/util/math.ts +++ b/src/util/math.ts @@ -12,8 +12,8 @@ import { Uncertainty } from '../datatypes/uncertainty'; export const MAX_INT_VALUE = Math.pow(2, 31) - 1; export const MIN_INT_VALUE = Math.pow(-2, 31); -export const MAX_LONG_VALUE = Math.pow(2, 63) - 1; -export const MIN_LONG_VALUE = Math.pow(-2, 63); +export const MAX_LONG_VALUE = 9223372036854775807n; +export const MIN_LONG_VALUE = -9223372036854775808n; export const MAX_FLOAT_VALUE = 99999999999999999999.99999999; export const MIN_FLOAT_VALUE = -99999999999999999999.99999999; export const MIN_FLOAT_PRECISION_VALUE = Math.pow(10, -8); @@ -53,8 +53,11 @@ export function overflowsOrUnderflows(value: any): boolean { if (value.before(MIN_DATE_VALUE)) { return true; } + } else if (typeof value === 'bigint') { + if (!isValidLong(value)) { + return true; + } } else if (Number.isInteger(value)) { - // TODO: Somehow distinguish Integer from Long if (!isValidInteger(value)) { return true; } @@ -69,7 +72,7 @@ export function overflowsOrUnderflows(value: any): boolean { } export function isValidInteger(integer: any) { - if (isNaN(integer)) { + if (!Number.isInteger(integer)) { return false; } if (integer > MAX_INT_VALUE) { @@ -82,7 +85,7 @@ export function isValidInteger(integer: any) { } export function isValidLong(long: any) { - if (isNaN(long)) { + if (typeof long !== 'bigint') { return false; } if (long > MAX_LONG_VALUE) { @@ -98,6 +101,9 @@ export function isValidDecimal(decimal: any) { if (isNaN(decimal)) { return false; } + if (typeof decimal !== 'number') { + return false; + } if (decimal > MAX_FLOAT_VALUE) { return false; } @@ -129,7 +135,6 @@ export class OverFlowException extends Exception {} export function successor(val: any): any { if (typeof val === 'number') { if (Number.isInteger(val)) { - // TODO: Somehow distinguish Integer from Long if (val >= MAX_INT_VALUE) { throw new OverFlowException(); } else { @@ -142,6 +147,12 @@ export function successor(val: any): any { return val + MIN_FLOAT_PRECISION_VALUE; } } + } else if (typeof val === 'bigint') { + if (val >= MAX_LONG_VALUE) { + throw new OverFlowException(); + } else { + return val + 1n; + } } else if (val && val.isTime && val.isTime()) { if (val.sameAs(MAX_TIME_VALUE)) { throw new OverFlowException(); @@ -182,7 +193,6 @@ export function successor(val: any): any { export function predecessor(val: any): any { if (typeof val === 'number') { if (Number.isInteger(val)) { - // TODO: Somehow distinguish Integer from Long if (val <= MIN_INT_VALUE) { throw new OverFlowException(); } else { @@ -195,6 +205,12 @@ export function predecessor(val: any): any { return val - MIN_FLOAT_PRECISION_VALUE; } } + } else if (typeof val === 'bigint') { + if (val <= MIN_LONG_VALUE) { + throw new OverFlowException(); + } else { + return val - 1n; + } } else if (val && val.isTime && val.isTime()) { if (val.sameAs(MIN_TIME_VALUE)) { throw new OverFlowException(); @@ -234,12 +250,13 @@ export function predecessor(val: any): any { export function maxValueForInstance(val: any) { if (typeof val === 'number') { - // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return MAX_INT_VALUE; } else { return MAX_FLOAT_VALUE; } + } else if (typeof val === 'bigint') { + return MAX_LONG_VALUE; } else if (val && val.isTime && val.isTime()) { return MAX_TIME_VALUE?.copy(); } else if (val && val.isDateTime) { @@ -284,12 +301,13 @@ export function maxValueForType(type: string, quantityInstance?: Quantity) { export function minValueForInstance(val: any) { if (typeof val === 'number') { - // TODO: Somehow distinguish Integer from Long if (Number.isInteger(val)) { return MIN_INT_VALUE; } else { return MIN_FLOAT_VALUE; } + } else if (typeof val === 'bigint') { + return MIN_LONG_VALUE; } else if (val && val.isTime && val.isTime()) { return MIN_TIME_VALUE?.copy(); } else if (val && val.isDateTime) { @@ -358,3 +376,10 @@ export function decimalAdjust(type: MathFn, value: any, exp: any) { export function decimalOrNull(value: any) { return isValidDecimal(value) ? value : null; } + +export function decimalLongOrNull(value: any) { + return (typeof value === 'number' && isValidDecimal(value)) || + (typeof value === 'bigint' && isValidLong(value)) + ? value + : null; +} diff --git a/test-server/src/convert/convert.ts b/test-server/src/convert/convert.ts index 02b6b55fb..feff0c3bd 100644 --- a/test-server/src/convert/convert.ts +++ b/test-server/src/convert/convert.ts @@ -308,6 +308,8 @@ function toFhirQuantity(val: CqlQuantity | number, isIntegerOrLong = false): Fhi let fq: FhirQuantity; if (typeof val === 'number') { fq = { value: val }; + } else if (typeof val === 'bigint') { + fq = { value: Number(val) }; } else { const cq = val as CqlQuantity; fq = { value: cq.value } as FhirQuantity; diff --git a/test-server/tests/convert/convert.test.ts b/test-server/tests/convert/convert.test.ts index 4f16fbaee..47153d6d4 100644 --- a/test-server/tests/convert/convert.test.ts +++ b/test-server/tests/convert/convert.test.ts @@ -49,7 +49,7 @@ describe('convert.toParameters', () => { }); it('converts long to valueString (R4)', () => { - expect(toParameters(1234567890123, 'System.Long')).toEqual({ + expect(toParameters(1234567890123n, 'System.Long')).toEqual({ resourceType: 'Parameters', parameter: [ { extension: cqlTypeExt('System.Long'), name: 'return', valueString: '1234567890123' } diff --git a/test/datatypes/bigint-test.ts b/test/datatypes/bigint-test.ts new file mode 100644 index 000000000..c570dee3b --- /dev/null +++ b/test/datatypes/bigint-test.ts @@ -0,0 +1,8 @@ +import '../../src/datatypes/bigint'; + +describe('BigInt', () => { + it('should serialize bigint values to a string', () => { + const big = { big: 1234567890123456789n }; + JSON.stringify(big).should.eql('{"big":"1234567890123456789"}'); + }); +}); diff --git a/test/elm/arithmetic/arithmetic-test.ts b/test/elm/arithmetic/arithmetic-test.ts index 66f9ee81d..83549c39e 100644 --- a/test/elm/arithmetic/arithmetic-test.ts +++ b/test/elm/arithmetic/arithmetic-test.ts @@ -75,8 +75,16 @@ describe('Add', () => { (await this.addVariables.exec(this.ctx)).should.equal(21); }); - it('should add two short longs', async function () { - (await this.onePlusTwoLong.exec(this.ctx)).should.equal(3); + it('should add two longs', async function () { + (await this.onePlusTwoLong.exec(this.ctx)).should.equal(3n); + }); + + it('should add integer and long', async function () { + (await this.onePlusTwoMixed.exec(this.ctx)).should.equal(3n); + }); + + it('should add long and integer', async function () { + (await this.onePlusTwoReverseMixed.exec(this.ctx)).should.equal(3n); }); it('should add Time/Quantity', async function () { @@ -120,7 +128,15 @@ describe('Subtract', () => { }); it('should subtract two longs', async function () { - (await this.fiveMinusTwoLong.exec(this.ctx)).should.equal(3); + (await this.fiveMinusTwoLong.exec(this.ctx)).should.equal(3n); + }); + + it('should subtract long from integer', async function () { + (await this.fiveMinusTwoMixed.exec(this.ctx)).should.equal(3n); + }); + + it('should subtract integer from long', async function () { + (await this.fiveMinusTwoReverseMixed.exec(this.ctx)).should.equal(3n); }); it('should subtract uncertainty from uncertainty', async function () { @@ -160,7 +176,15 @@ describe('Multiply', () => { }); it('should multiply two longs', async function () { - (await this.fiveTimesTwoLong.exec(this.ctx)).should.equal(10); + (await this.fiveTimesTwoLong.exec(this.ctx)).should.equal(10n); + }); + + it('should multiply two integer by long', async function () { + (await this.fiveTimesTwoMixed.exec(this.ctx)).should.equal(10n); + }); + + it('should multiply long by integer', async function () { + (await this.fiveTimesTwoReverseMixed.exec(this.ctx)).should.equal(10n); }); it('should multiply uncertainty and uncertainty', async function () { @@ -204,9 +228,32 @@ describe('Divide', () => { }); it('should divide two longs', async function () { + // NOTE: Divide always returns a Decimal (await this.tenDividedByTwoLong.exec(this.ctx)).should.equal(5); }); + it('should divide integer by long', async function () { + // NOTE: Divide always returns a Decimal + (await this.tenDividedByTwoMixed.exec(this.ctx)).should.equal(5); + }); + + it('should divide long by integer', async function () { + // NOTE: Divide always returns a Decimal + (await this.tenDividedByTwoReverseMixed.exec(this.ctx)).should.equal(5); + }); + + it('should divide two longs with decimal result', async function () { + (await this.tenDividedByFourLong.exec(this.ctx)).should.equal(2.5); + }); + + it('should divide integer by long with decimal result', async function () { + (await this.tenDividedByFourMixed.exec(this.ctx)).should.equal(2.5); + }); + + it('should divide long by integer with decimal result', async function () { + (await this.tenDividedByFourReverseMixed.exec(this.ctx)).should.equal(2.5); + }); + it('should divide uncertainty by uncertainty', async function () { const result = await this.divideUncertainties.exec(this.ctx); result.low.should.equal(6 / 14); @@ -236,7 +283,7 @@ describe('Negate', () => { }); it('should negate a long', async function () { - (await this.negativeOneLong.exec(this.ctx)).should.equal(-1); + (await this.negativeOneLong.exec(this.ctx)).should.equal(-1n); }); }); @@ -264,7 +311,15 @@ describe('Power', () => { }); it('should be able to calculate the power of a long', async function () { - (await this.threeExpFourLong.exec(this.ctx)).should.equal(81); + (await this.threeExpFourLong.exec(this.ctx)).should.equal(81n); + }); + + it('should be able to calculate the long power of an integer', async function () { + (await this.threeExpFourMixed.exec(this.ctx)).should.equal(81n); + }); + + it('should be able to calculate the integer power of a long', async function () { + (await this.threeExpFourReverseMixed.exec(this.ctx)).should.equal(81n); }); }); @@ -281,15 +336,8 @@ describe('MinValue', () => { String(minIntegerResult).should.equal(minIntegerStringValue); }); - // JS number doesn't handle limits of Long precisely, but this ensures we are in the ballpark - it('of Long should return approximate minimum representable Long value', async function () { - const minLongResult = await this.minLong.exec(this.ctx); - minLongResult.should.be.aboveOrEqual(-9223372036854776000); - minLongResult.should.be.belowOrEqual(-9223372036854775000); - }); - - it.skip('of Long should return exact minimum representable Long value', async function () { - const minLongValue = -9223372036854775808; + it('of Long should return exact minimum representable Long value', async function () { + const minLongValue = -9223372036854775808n; const minLongStringValue = '-9223372036854775808'; const minLongResult = await this.minLong.exec(this.ctx); minLongResult.should.equal(minLongValue); @@ -348,15 +396,8 @@ describe('MaxValue', () => { String(maxIntegerResult).should.equal(maxIntegerStringValue); }); - // JS number doesn't handle limits of Long precisely, but this ensures we are in the ballpark - it('of Long should return approximate maximum representable Long value', async function () { - const maxLongResult = await this.maxLong.exec(this.ctx); - maxLongResult.should.be.aboveOrEqual(9223372036854775000); - maxLongResult.should.be.belowOrEqual(9223372036854776000); - }); - - it.skip('of Long should return exact maximum representable Long value', async function () { - const maxLongValue = 9223372036854775807; + it('of Long should return exact maximum representable Long value', async function () { + const maxLongValue = 9223372036854775807n; const maxLongStringValue = '9223372036854775807'; const maxLongResult = await this.maxLong.exec(this.ctx); maxLongResult.should.equal(maxLongValue); @@ -426,7 +467,15 @@ describe('TruncatedDivide', () => { }); it('should be able to return just the long portion of a division', async function () { - (await this.tenDivThreeLong.exec(this.ctx)).should.equal(3); + (await this.tenDivThreeLong.exec(this.ctx)).should.equal(3n); + }); + + it('should be able to return just the long portion of a dividing an integer by a long', async function () { + (await this.tenDivThreeMixed.exec(this.ctx)).should.equal(3n); + }); + + it('should be able to return just the long portion of a dividing a long by an integer', async function () { + (await this.tenDivThreeReverseMixed.exec(this.ctx)).should.equal(3n); }); }); @@ -441,6 +490,7 @@ describe('Truncate', () => { }); it('should be able to return the long portion of a number', async function () { + // NOTE: Truncate returns an integer (not specified to return a Long) (await this.truncTenLong.exec(this.ctx)).should.equal(10); }); }); @@ -509,7 +559,15 @@ describe('Modulo', () => { }); it('should be able to return the long remainder of a division', async function () { - (await this.threeModTwoLong.exec(this.ctx)).should.equal(1); + (await this.threeModTwoLong.exec(this.ctx)).should.equal(1n); + }); + + it('should be able to return the long remainder of a dividing an integer by a long', async function () { + (await this.threeModTwoMixed.exec(this.ctx)).should.equal(1n); + }); + + it('should be able to return the long remainder of a dividing a long by an integer', async function () { + (await this.threeModTwoReverseMixed.exec(this.ctx)).should.equal(1n); }); }); @@ -528,7 +586,7 @@ describe('Abs', () => { (await this.zero.exec(this.ctx)).should.equal(0); }); it('should be able to return the absolute value of a negative long', async function () { - (await this.absNegTenLong.exec(this.ctx)).should.equal(10); + (await this.absNegTenLong.exec(this.ctx)).should.equal(10n); }); }); @@ -557,7 +615,7 @@ describe('Successor', () => { }); it('should be able to get Long Successor', async function () { - (await this.ls.exec(this.ctx)).should.equal(3); + (await this.ls.exec(this.ctx)).should.equal(3n); }); it('should be able to get Real Successor', async function () { @@ -660,7 +718,7 @@ describe('Predecessor', () => { }); it('should be able to get Long Predecessor', async function () { - (await this.ls.exec(this.ctx)).should.equal(1); + (await this.ls.exec(this.ctx)).should.equal(1n); }); it('should be able to get Real Predecessor', async function () { @@ -975,13 +1033,11 @@ describe('OutOfBounds', () => { should(await this.longAddUnderflow.exec(this.ctx)).be.null(); }); - // skipping this and other long tests because logic can't distinguish between integer and long - // so it doesn't know when to overflow (and currently defaults to integer overflows) - it.skip('should return value for Add near overflow', async function () { + it('should return value for Add near overflow', async function () { should(await this.longAddNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); }); - it.skip('should return value for Add near underflow', async function () { + it('should return value for Add near underflow', async function () { should(await this.longAddNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); }); @@ -993,11 +1049,11 @@ describe('OutOfBounds', () => { should(await this.longSubtractUnderflow.exec(this.ctx)).be.null(); }); - it.skip('should return value for Subtract near overflow', async function () { + it('should return value for Subtract near overflow', async function () { should(await this.longSubtractNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); }); - it.skip('should return value for Subtract near underflow', async function () { + it('should return value for Subtract near underflow', async function () { should(await this.longSubtractNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); }); @@ -1009,11 +1065,11 @@ describe('OutOfBounds', () => { should(await this.longMultiplyUnderflow.exec(this.ctx)).be.null(); }); - it.skip('should return value for Multiply near overflow', async function () { + it('should return value for Multiply near overflow', async function () { should(await this.longMultiplyNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); }); - it.skip('should return value for Multiply near underflow', async function () { + it('should return value for Multiply near underflow', async function () { should(await this.longMultiplyNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); }); @@ -1025,12 +1081,14 @@ describe('OutOfBounds', () => { should(await this.longDivideUnderflow.exec(this.ctx)).be.null(); }); - it.skip('should return value for Divide near overflow', async function () { - should(await this.longDivideNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); + it('should return value for Divide near overflow', async function () { + // Since Divide does not return Longs, use max int value + should(await this.longDivideNearOverflow.exec(this.ctx)).equal(MAX_INT_VALUE); }); - it.skip('should return value for Divide near underflow', async function () { - should(await this.longDivideNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); + it('should return value for Divide near underflow', async function () { + // Since Divide does not return Longs, use min int value + should(await this.longDivideNearUnderflow.exec(this.ctx)).equal(MIN_INT_VALUE); }); it('should return null for Divide By Zero', async function () { @@ -1045,11 +1103,11 @@ describe('OutOfBounds', () => { should(await this.longPowerUnderflow.exec(this.ctx)).be.null(); }); - it.skip('should return value for Power near overflow', async function () { + it('should return value for Power near overflow', async function () { should(await this.longPowerNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); }); - it.skip('should return value for Power near underflow', async function () { + it('should return value for Power near underflow', async function () { should(await this.longPowerNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); }); @@ -1061,11 +1119,11 @@ describe('OutOfBounds', () => { should(await this.longPredecessorUnderflow.exec(this.ctx)).be.null(); }); - it.skip('should return value for successor near overflow', async function () { + it('should return value for successor near overflow', async function () { should(await this.longSuccessorNearOverflow.exec(this.ctx)).equal(MAX_LONG_VALUE); }); - it.skip('should return value for predecessor near underflow', async function () { + it('should return value for predecessor near underflow', async function () { should(await this.longPredecessorNearUnderflow.exec(this.ctx)).equal(MIN_LONG_VALUE); }); }); diff --git a/test/elm/arithmetic/data.cql b/test/elm/arithmetic/data.cql index 2aaa87261..de59e45e1 100644 --- a/test/elm/arithmetic/data.cql +++ b/test/elm/arithmetic/data.cql @@ -5,6 +5,8 @@ define OnePlusTwo: 1 + 2 define AddMultiple: 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 define AddVariables: Ten + Eleven define OnePlusTwoLong: 1L + 2L +define OnePlusTwoMixed: 1 + 2L +define OnePlusTwoReverseMixed: 1L + 2 define AddTime: Time(12) + 1 'hour' define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) @@ -19,6 +21,8 @@ define FiveMinusTwo: 5 - 2 define SubtractMultiple: 100 - 50 - 25 - 10 define SubtractVariables: Eleven - Ten define FiveMinusTwoLong: 5L - 2L +define FiveMinusTwoMixed: 5 - 2L +define FiveMinusTwoReverseMixed: 5L - 2 define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define SubtractUncertainties: UncertaintySixToEighteen - UncertaintyZeroToTwelve @@ -31,7 +35,9 @@ define Eleven: 11 define FiveTimesTwo: 5 * 2 define MultiplyMultiple: 1 * 2 * 3 * 4 * 5 define MultiplyVariables: Eleven * Ten -define FiveTimesTwoLong: 5 * 2 +define FiveTimesTwoLong: 5L * 2L +define FiveTimesTwoMixed: 5 * 2L +define FiveTimesTwoReverseMixed: 5L * 2 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define MultiplyUncertainties: UncertaintyTwoToFourteen * UncertaintySixToEighteen @@ -45,7 +51,12 @@ define TenDividedByTwo: 10 / 2 define TenDividedByFour: 10 / 4 define DivideMultiple: 1000 / 4 / 10 / 5 define DivideVariables: Hundred / Four -define TenDividedByTwoLong: 10 / 2 +define TenDividedByTwoLong: 10L / 2L +define TenDividedByTwoMixed: 10 / 2L +define TenDividedByTwoReverseMixed: 10L / 2 +define TenDividedByFourLong: 10L / 4L +define TenDividedByFourMixed: 10 / 4L +define TenDividedByFourReverseMixed: 10L / 4 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define DivideUncertainties: UncertaintySixToEighteen / UncertaintyTwoToFourteen @@ -63,6 +74,8 @@ define Parenthetical: (1 + 5) * (10 - 15) / 3 // @Test: Power define Pow: 3 ^ 4 define ThreeExpFourLong: 3L ^ 4L +define ThreeExpFourMixed: 3 ^ 4L +define ThreeExpFourReverseMixed: 3L ^ 4 // @Test: MinValue define MinInteger: minimum Integer @@ -84,10 +97,15 @@ define MaxWrongType: maximum Quantity define Trunc: 10 div 3 define Even: 9 div 3 define TenDivThreeLong: 10L div 3L +define TenDivThreeMixed: 10 div 3L +define TenDivThreeReverseMixed: 10L div 3 // @Test: Modulo define Mod: 3 mod 2 define ThreeModTwoLong: 3L mod 2L +define ThreeModTwoMixed: 3 mod 2L +define ThreeModTwoReverseMixed: 3L mod 2 + // @Test: Ceiling define Ceil: Ceiling(10.1) @@ -219,8 +237,8 @@ define LongMultiplyNearOverflow: maximum Long * 1L define LongMultiplyNearUnderflow: minimum Long * 1L define LongDivideOverflow: maximum Long / 0.5 define LongDivideUnderflow: minimum Long / 0.5 -define LongDivideNearOverflow: maximum Long / 1L -define LongDivideNearUnderflow: minimum Long / 1L +define LongDivideNearOverflow: ToLong(maximum Integer) / 1L +define LongDivideNearUnderflow: ToLong(minimum Integer) / 1L define LongDivideByZero: 1L / 0L define LongPowerOverflow: (maximum Long)^3L define LongPowerUnderflow: (minimum Long)^3L diff --git a/test/elm/arithmetic/data.js b/test/elm/arithmetic/data.js index 1bb115bf9..90209f6cd 100644 --- a/test/elm/arithmetic/data.js +++ b/test/elm/arithmetic/data.js @@ -18,6 +18,8 @@ define OnePlusTwo: 1 + 2 define AddMultiple: 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 define AddVariables: Ten + Eleven define OnePlusTwoLong: 1L + 2L +define OnePlusTwoMixed: 1 + 2L +define OnePlusTwoReverseMixed: 1L + 2 define AddTime: Time(12) + 1 'hour' define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) @@ -38,7 +40,7 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "357", + "r" : "379", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -625,6 +627,136 @@ module.exports['Add'] = { } }, { "localId" : "286", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "OnePlusTwoMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "286", + "s" : [ { + "value" : [ "", "define ", "OnePlusTwoMixed", ": " ] + }, { + "r" : "287", + "s" : [ { + "r" : "288", + "value" : [ "1", " + ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "287", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "293", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "294", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToLong", + "localId" : "291", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "292", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "288", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "1", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "289", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "297", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "OnePlusTwoReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "297", + "s" : [ { + "value" : [ "", "define ", "OnePlusTwoReverseMixed", ": " ] + }, { + "r" : "298", + "s" : [ { + "r" : "299", + "value" : [ "1L", " + ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Add", + "localId" : "298", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "304", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "305", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "299", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "1", + "annotation" : [ ] + }, { + "type" : "ToLong", + "localId" : "302", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "303", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "300", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "308", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "AddTime", "context" : "Patient", @@ -633,21 +765,21 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "286", + "r" : "308", "s" : [ { "value" : [ "", "define ", "AddTime", ": " ] }, { - "r" : "287", + "r" : "309", "s" : [ { - "r" : "292", + "r" : "314", "s" : [ { - "r" : "288", + "r" : "310", "value" : [ "Time", "(", "12", ")" ] } ] }, { "value" : [ " + " ] }, { - "r" : "294", + "r" : "316", "s" : [ { "value" : [ "1 ", "'hour'" ] } ] @@ -657,34 +789,34 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "287", + "localId" : "309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "295", + "localId" : "317", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "296", + "localId" : "318", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "Time", - "localId" : "292", + "localId" : "314", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "293", + "localId" : "315", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "hour" : { "type" : "Literal", - "localId" : "288", + "localId" : "310", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -692,7 +824,7 @@ module.exports['Add'] = { } }, { "type" : "Quantity", - "localId" : "294", + "localId" : "316", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "hour", @@ -700,7 +832,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "299", + "localId" : "321", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "context" : "Patient", @@ -709,25 +841,25 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "299", + "r" : "321", "s" : [ { "value" : [ "", "define ", "UncertaintyZeroToTwelve", ": " ] }, { - "r" : "300", + "r" : "322", "s" : [ { "value" : [ "months between " ] }, { - "r" : "307", + "r" : "329", "s" : [ { - "r" : "301", + "r" : "323", "value" : [ "DateTime", "(", "2005", ", ", "12", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "314", + "r" : "336", "s" : [ { - "r" : "310", + "r" : "332", "value" : [ "DateTime", "(", "2006", ")" ] } ] } ] @@ -736,40 +868,40 @@ module.exports['Add'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "300", + "localId" : "322", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "316", + "localId" : "338", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "317", + "localId" : "339", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "307", + "localId" : "329", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "330", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "309", + "localId" : "331", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "301", + "localId" : "323", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -777,7 +909,7 @@ module.exports['Add'] = { }, "month" : { "type" : "Literal", - "localId" : "302", + "localId" : "324", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -785,18 +917,18 @@ module.exports['Add'] = { } }, { "type" : "DateTime", - "localId" : "314", + "localId" : "336", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "315", + "localId" : "337", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "310", + "localId" : "332", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -805,7 +937,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "320", + "localId" : "342", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -814,25 +946,25 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "320", + "r" : "342", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "321", + "r" : "343", "s" : [ { "value" : [ "months between " ] }, { - "r" : "326", + "r" : "348", "s" : [ { - "r" : "322", + "r" : "344", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "334", + "r" : "356", "s" : [ { - "r" : "328", + "r" : "350", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -841,35 +973,35 @@ module.exports['Add'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "321", + "localId" : "343", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "337", + "localId" : "359", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "338", + "localId" : "360", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "326", + "localId" : "348", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "327", + "localId" : "349", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "322", + "localId" : "344", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -877,23 +1009,23 @@ module.exports['Add'] = { } }, { "type" : "DateTime", - "localId" : "334", + "localId" : "356", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "335", + "localId" : "357", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "336", + "localId" : "358", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "328", + "localId" : "350", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -901,7 +1033,7 @@ module.exports['Add'] = { }, "month" : { "type" : "Literal", - "localId" : "329", + "localId" : "351", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -910,7 +1042,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "341", + "localId" : "363", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "AddUncertainties", "context" : "Patient", @@ -919,20 +1051,20 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "341", + "r" : "363", "s" : [ { "value" : [ "", "define ", "AddUncertainties", ": " ] }, { - "r" : "342", + "r" : "364", "s" : [ { - "r" : "343", + "r" : "365", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] }, { "value" : [ " + " ] }, { - "r" : "344", + "r" : "366", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -942,36 +1074,36 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "342", + "localId" : "364", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "345", + "localId" : "367", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "346", + "localId" : "368", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "343", + "localId" : "365", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "344", + "localId" : "366", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } ] } }, { - "localId" : "349", + "localId" : "371", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "AddUncertaintyAndNumber", "context" : "Patient", @@ -980,18 +1112,18 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "349", + "r" : "371", "s" : [ { "value" : [ "", "define ", "AddUncertaintyAndNumber", ": " ] }, { - "r" : "350", + "r" : "372", "s" : [ { - "r" : "351", + "r" : "373", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] }, { - "r" : "352", + "r" : "374", "value" : [ " + ", "5" ] } ] } ] @@ -999,29 +1131,29 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "350", + "localId" : "372", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "353", + "localId" : "375", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "354", + "localId" : "376", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "351", + "localId" : "373", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "352", + "localId" : "374", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "5", @@ -1029,7 +1161,7 @@ module.exports['Add'] = { } ] } }, { - "localId" : "357", + "localId" : "379", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "AddNumberAndUncertainty", "context" : "Patient", @@ -1038,16 +1170,16 @@ module.exports['Add'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "357", + "r" : "379", "s" : [ { "value" : [ "", "define ", "AddNumberAndUncertainty", ": " ] }, { - "r" : "358", + "r" : "380", "s" : [ { - "r" : "359", + "r" : "381", "value" : [ "10", " + " ] }, { - "r" : "360", + "r" : "382", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] @@ -1057,30 +1189,30 @@ module.exports['Add'] = { } ], "expression" : { "type" : "Add", - "localId" : "358", + "localId" : "380", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "361", + "localId" : "383", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "362", + "localId" : "384", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "359", + "localId" : "381", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "360", + "localId" : "382", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] @@ -1101,6 +1233,8 @@ define FiveMinusTwo: 5 - 2 define SubtractMultiple: 100 - 50 - 25 - 10 define SubtractVariables: Eleven - Ten define FiveMinusTwoLong: 5L - 2L +define FiveMinusTwoMixed: 5 - 2L +define FiveMinusTwoReverseMixed: 5L - 2 define UncertaintyZeroToTwelve: months between DateTime(2005, 12) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define SubtractUncertainties: UncertaintySixToEighteen - UncertaintyZeroToTwelve @@ -1120,7 +1254,7 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "320", + "r" : "342", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -1527,8 +1661,8 @@ module.exports['Subtract'] = { } }, { "localId" : "262", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "UncertaintyZeroToTwelve", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "FiveMinusTwoMixed", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -1537,65 +1671,195 @@ module.exports['Subtract'] = { "s" : { "r" : "262", "s" : [ { - "value" : [ "", "define ", "UncertaintyZeroToTwelve", ": " ] + "value" : [ "", "define ", "FiveMinusTwoMixed", ": " ] }, { "r" : "263", "s" : [ { - "value" : [ "months between " ] - }, { - "r" : "270", - "s" : [ { - "r" : "264", - "value" : [ "DateTime", "(", "2005", ", ", "12", ")" ] - } ] - }, { - "value" : [ " and " ] - }, { - "r" : "277", - "s" : [ { - "r" : "273", - "value" : [ "DateTime", "(", "2006", ")" ] - } ] + "r" : "264", + "value" : [ "5", " - ", "2L" ] } ] } ] } } ], "expression" : { - "type" : "DurationBetween", + "type" : "Subtract", "localId" : "263", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "precision" : "Month", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "279", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "269", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "280", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "270", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "DateTime", - "localId" : "270", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "ToLong", + "localId" : "267", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "271", + "localId" : "268", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "272", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + } ], + "operand" : { + "type" : "Literal", + "localId" : "264", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "5", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "265", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "273", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "FiveMinusTwoReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "273", + "s" : [ { + "value" : [ "", "define ", "FiveMinusTwoReverseMixed", ": " ] + }, { + "r" : "274", + "s" : [ { + "r" : "275", + "value" : [ "5L", " - ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Subtract", + "localId" : "274", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "280", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "281", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "275", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "5", + "annotation" : [ ] + }, { + "type" : "ToLong", + "localId" : "278", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "279", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "276", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "284", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "UncertaintyZeroToTwelve", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "284", + "s" : [ { + "value" : [ "", "define ", "UncertaintyZeroToTwelve", ": " ] + }, { + "r" : "285", + "s" : [ { + "value" : [ "months between " ] + }, { + "r" : "292", + "s" : [ { + "r" : "286", + "value" : [ "DateTime", "(", "2005", ", ", "12", ")" ] + } ] + }, { + "value" : [ " and " ] + }, { + "r" : "299", + "s" : [ { + "r" : "295", + "value" : [ "DateTime", "(", "2006", ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "DurationBetween", + "localId" : "285", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "precision" : "Month", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "301", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "302", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "DateTime", + "localId" : "292", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "293", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "294", + "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "264", + "localId" : "286", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -1603,7 +1867,7 @@ module.exports['Subtract'] = { }, "month" : { "type" : "Literal", - "localId" : "265", + "localId" : "287", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12", @@ -1611,18 +1875,18 @@ module.exports['Subtract'] = { } }, { "type" : "DateTime", - "localId" : "277", + "localId" : "299", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "278", + "localId" : "300", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "273", + "localId" : "295", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -1631,7 +1895,7 @@ module.exports['Subtract'] = { } ] } }, { - "localId" : "283", + "localId" : "305", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -1640,25 +1904,25 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "283", + "r" : "305", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "284", + "r" : "306", "s" : [ { "value" : [ "months between " ] }, { - "r" : "289", + "r" : "311", "s" : [ { - "r" : "285", + "r" : "307", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "297", + "r" : "319", "s" : [ { - "r" : "291", + "r" : "313", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -1667,35 +1931,35 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "284", + "localId" : "306", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "300", + "localId" : "322", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "301", + "localId" : "323", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "289", + "localId" : "311", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "290", + "localId" : "312", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "285", + "localId" : "307", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -1703,23 +1967,23 @@ module.exports['Subtract'] = { } }, { "type" : "DateTime", - "localId" : "297", + "localId" : "319", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "298", + "localId" : "320", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "299", + "localId" : "321", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "291", + "localId" : "313", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -1727,7 +1991,7 @@ module.exports['Subtract'] = { }, "month" : { "type" : "Literal", - "localId" : "292", + "localId" : "314", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -1736,7 +2000,7 @@ module.exports['Subtract'] = { } ] } }, { - "localId" : "304", + "localId" : "326", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "SubtractUncertainties", "context" : "Patient", @@ -1745,20 +2009,20 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "304", + "r" : "326", "s" : [ { "value" : [ "", "define ", "SubtractUncertainties", ": " ] }, { - "r" : "305", + "r" : "327", "s" : [ { - "r" : "306", + "r" : "328", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { "value" : [ " - " ] }, { - "r" : "307", + "r" : "329", "s" : [ { "value" : [ "UncertaintyZeroToTwelve" ] } ] @@ -1768,36 +2032,36 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "305", + "localId" : "327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "330", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "309", + "localId" : "331", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "306", + "localId" : "328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "307", + "localId" : "329", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyZeroToTwelve", "annotation" : [ ] } ] } }, { - "localId" : "312", + "localId" : "334", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "SubtractNumberFromUncertainty", "context" : "Patient", @@ -1806,18 +2070,18 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "312", + "r" : "334", "s" : [ { "value" : [ "", "define ", "SubtractNumberFromUncertainty", ": " ] }, { - "r" : "313", + "r" : "335", "s" : [ { - "r" : "314", + "r" : "336", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { - "r" : "315", + "r" : "337", "value" : [ " - ", "5" ] } ] } ] @@ -1825,29 +2089,29 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "313", + "localId" : "335", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "316", + "localId" : "338", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "317", + "localId" : "339", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "314", + "localId" : "336", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "315", + "localId" : "337", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "5", @@ -1855,7 +2119,7 @@ module.exports['Subtract'] = { } ] } }, { - "localId" : "320", + "localId" : "342", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "SubtractUncertaintyFromNumber", "context" : "Patient", @@ -1864,16 +2128,16 @@ module.exports['Subtract'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "320", + "r" : "342", "s" : [ { "value" : [ "", "define ", "SubtractUncertaintyFromNumber", ": " ] }, { - "r" : "321", + "r" : "343", "s" : [ { - "r" : "322", + "r" : "344", "value" : [ "10", " - " ] }, { - "r" : "323", + "r" : "345", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -1883,30 +2147,30 @@ module.exports['Subtract'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "321", + "localId" : "343", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "324", + "localId" : "346", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "325", + "localId" : "347", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "322", + "localId" : "344", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "323", + "localId" : "345", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] @@ -1926,7 +2190,9 @@ define Eleven: 11 define FiveTimesTwo: 5 * 2 define MultiplyMultiple: 1 * 2 * 3 * 4 * 5 define MultiplyVariables: Eleven * Ten -define FiveTimesTwoLong: 5 * 2 +define FiveTimesTwoLong: 5L * 2L +define FiveTimesTwoMixed: 5 * 2L +define FiveTimesTwoReverseMixed: 5L * 2 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define MultiplyUncertainties: UncertaintyTwoToFourteen * UncertaintySixToEighteen @@ -1946,7 +2212,7 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "324", + "r" : "346", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -2329,7 +2595,7 @@ module.exports['Multiply'] = { } }, { "localId" : "258", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "FiveTimesTwoLong", "context" : "Patient", "accessLevel" : "Public", @@ -2344,7 +2610,7 @@ module.exports['Multiply'] = { "r" : "259", "s" : [ { "r" : "260", - "value" : [ "5", " * ", "2" ] + "value" : [ "5L", " * ", "2L" ] } ] } ] } @@ -2352,39 +2618,39 @@ module.exports['Multiply'] = { "expression" : { "type" : "Multiply", "localId" : "259", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", "localId" : "262", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", "localId" : "263", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", "localId" : "260", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "5", "annotation" : [ ] }, { "type" : "Literal", "localId" : "261", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "2", "annotation" : [ ] } ] } }, { "localId" : "266", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "UncertaintyTwoToFourteen", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "FiveTimesTwoMixed", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -2393,73 +2659,203 @@ module.exports['Multiply'] = { "s" : { "r" : "266", "s" : [ { - "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] + "value" : [ "", "define ", "FiveTimesTwoMixed", ": " ] }, { "r" : "267", "s" : [ { - "value" : [ "months between " ] - }, { - "r" : "274", - "s" : [ { - "r" : "268", - "value" : [ "DateTime", "(", "2005", ", ", "10", ")" ] - } ] - }, { - "value" : [ " and " ] - }, { - "r" : "281", - "s" : [ { - "r" : "277", - "value" : [ "DateTime", "(", "2006", ")" ] - } ] + "r" : "268", + "value" : [ "5", " * ", "2L" ] } ] } ] } } ], "expression" : { - "type" : "DurationBetween", + "type" : "Multiply", "localId" : "267", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "precision" : "Month", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "283", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "273", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "284", - "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "localId" : "274", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { - "type" : "DateTime", - "localId" : "274", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "type" : "ToLong", + "localId" : "271", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "275", - "name" : "{urn:hl7-org:elm-types:r1}Integer", - "annotation" : [ ] - }, { - "type" : "NamedTypeSpecifier", - "localId" : "276", + "localId" : "272", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], - "year" : { + "operand" : { "type" : "Literal", "localId" : "268", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "5", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "269", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "277", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "FiveTimesTwoReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "277", + "s" : [ { + "value" : [ "", "define ", "FiveTimesTwoReverseMixed", ": " ] + }, { + "r" : "278", + "s" : [ { + "r" : "279", + "value" : [ "5L", " * ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Multiply", + "localId" : "278", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "284", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "285", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "279", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "5", + "annotation" : [ ] + }, { + "type" : "ToLong", + "localId" : "282", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "283", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "280", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "288", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "UncertaintyTwoToFourteen", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "288", + "s" : [ { + "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] + }, { + "r" : "289", + "s" : [ { + "value" : [ "months between " ] + }, { + "r" : "296", + "s" : [ { + "r" : "290", + "value" : [ "DateTime", "(", "2005", ", ", "10", ")" ] + } ] + }, { + "value" : [ " and " ] + }, { + "r" : "303", + "s" : [ { + "r" : "299", + "value" : [ "DateTime", "(", "2006", ")" ] + } ] + } ] + } ] + } + } ], + "expression" : { + "type" : "DurationBetween", + "localId" : "289", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "precision" : "Month", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "305", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "306", + "name" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "DateTime", + "localId" : "296", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "297", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "298", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "year" : { + "type" : "Literal", + "localId" : "290", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", "annotation" : [ ] }, "month" : { "type" : "Literal", - "localId" : "269", + "localId" : "291", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", @@ -2467,18 +2863,18 @@ module.exports['Multiply'] = { } }, { "type" : "DateTime", - "localId" : "281", + "localId" : "303", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "282", + "localId" : "304", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "277", + "localId" : "299", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -2487,7 +2883,7 @@ module.exports['Multiply'] = { } ] } }, { - "localId" : "287", + "localId" : "309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -2496,25 +2892,25 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "287", + "r" : "309", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "288", + "r" : "310", "s" : [ { "value" : [ "months between " ] }, { - "r" : "293", + "r" : "315", "s" : [ { - "r" : "289", + "r" : "311", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "301", + "r" : "323", "s" : [ { - "r" : "295", + "r" : "317", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -2523,35 +2919,35 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "288", + "localId" : "310", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "304", + "localId" : "326", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "305", + "localId" : "327", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "293", + "localId" : "315", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "294", + "localId" : "316", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "289", + "localId" : "311", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -2559,23 +2955,23 @@ module.exports['Multiply'] = { } }, { "type" : "DateTime", - "localId" : "301", + "localId" : "323", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "302", + "localId" : "324", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "303", + "localId" : "325", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "295", + "localId" : "317", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -2583,7 +2979,7 @@ module.exports['Multiply'] = { }, "month" : { "type" : "Literal", - "localId" : "296", + "localId" : "318", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -2592,7 +2988,7 @@ module.exports['Multiply'] = { } ] } }, { - "localId" : "308", + "localId" : "330", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "MultiplyUncertainties", "context" : "Patient", @@ -2601,20 +2997,20 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "308", + "r" : "330", "s" : [ { "value" : [ "", "define ", "MultiplyUncertainties", ": " ] }, { - "r" : "309", + "r" : "331", "s" : [ { - "r" : "310", + "r" : "332", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] }, { "value" : [ " * " ] }, { - "r" : "311", + "r" : "333", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -2624,36 +3020,36 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "309", + "localId" : "331", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "312", + "localId" : "334", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "313", + "localId" : "335", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "310", + "localId" : "332", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "311", + "localId" : "333", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } ] } }, { - "localId" : "316", + "localId" : "338", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "MultiplyUncertaintyAndNumber", "context" : "Patient", @@ -2662,18 +3058,18 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "316", + "r" : "338", "s" : [ { "value" : [ "", "define ", "MultiplyUncertaintyAndNumber", ": " ] }, { - "r" : "317", + "r" : "339", "s" : [ { - "r" : "318", + "r" : "340", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] }, { - "r" : "319", + "r" : "341", "value" : [ " * ", "5" ] } ] } ] @@ -2681,29 +3077,29 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "317", + "localId" : "339", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "320", + "localId" : "342", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "321", + "localId" : "343", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "318", + "localId" : "340", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "319", + "localId" : "341", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "5", @@ -2711,7 +3107,7 @@ module.exports['Multiply'] = { } ] } }, { - "localId" : "324", + "localId" : "346", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "MultiplyNumberAndUncertainty", "context" : "Patient", @@ -2720,16 +3116,16 @@ module.exports['Multiply'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "324", + "r" : "346", "s" : [ { "value" : [ "", "define ", "MultiplyNumberAndUncertainty", ": " ] }, { - "r" : "325", + "r" : "347", "s" : [ { - "r" : "326", + "r" : "348", "value" : [ "10", " * " ] }, { - "r" : "327", + "r" : "349", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] @@ -2739,30 +3135,30 @@ module.exports['Multiply'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "325", + "localId" : "347", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "328", + "localId" : "350", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "329", + "localId" : "351", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "326", + "localId" : "348", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", "annotation" : [ ] }, { "type" : "ExpressionRef", - "localId" : "327", + "localId" : "349", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] @@ -2783,7 +3179,12 @@ define TenDividedByTwo: 10 / 2 define TenDividedByFour: 10 / 4 define DivideMultiple: 1000 / 4 / 10 / 5 define DivideVariables: Hundred / Four -define TenDividedByTwoLong: 10 / 2 +define TenDividedByTwoLong: 10L / 2L +define TenDividedByTwoMixed: 10 / 2L +define TenDividedByTwoReverseMixed: 10L / 2 +define TenDividedByFourLong: 10L / 4L +define TenDividedByFourMixed: 10 / 4L +define TenDividedByFourReverseMixed: 10L / 4 define UncertaintyTwoToFourteen: months between DateTime(2005, 10) and DateTime(2006) define UncertaintySixToEighteen: months between DateTime(2005) and DateTime(2006, 7) define DivideUncertainties: UncertaintySixToEighteen / UncertaintyTwoToFourteen @@ -2803,7 +3204,7 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "376", + "r" : "446", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -3293,109 +3694,489 @@ module.exports['Divide'] = { "annotation" : [ ] } ], "operand" : { - "type" : "ExpressionRef", - "localId" : "280", + "type" : "ExpressionRef", + "localId" : "280", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "Hundred", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "286", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "287", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "ExpressionRef", + "localId" : "281", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "name" : "Four", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "292", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TenDividedByTwoLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "292", + "s" : [ { + "value" : [ "", "define ", "TenDividedByTwoLong", ": " ] + }, { + "r" : "293", + "s" : [ { + "r" : "294", + "value" : [ "10L", " / ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "293", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "302", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "303", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "297", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "298", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "294", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "300", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "301", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "295", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "306", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TenDividedByTwoMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "306", + "s" : [ { + "value" : [ "", "define ", "TenDividedByTwoMixed", ": " ] + }, { + "r" : "307", + "s" : [ { + "r" : "308", + "value" : [ "10", " / ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "307", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "316", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "317", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "311", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "312", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "308", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "314", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "315", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "309", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "320", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TenDividedByTwoReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "320", + "s" : [ { + "value" : [ "", "define ", "TenDividedByTwoReverseMixed", ": " ] + }, { + "r" : "321", + "s" : [ { + "r" : "322", + "value" : [ "10L", " / ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "321", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "330", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "331", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "325", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "326", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "322", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "328", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "329", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "323", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "334", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TenDividedByFourLong", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "334", + "s" : [ { + "value" : [ "", "define ", "TenDividedByFourLong", ": " ] + }, { + "r" : "335", + "s" : [ { + "r" : "336", + "value" : [ "10L", " / ", "4L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "335", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "344", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "345", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "339", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "340", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "336", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "ToDecimal", + "localId" : "342", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "343", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "337", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "4", + "annotation" : [ ] + } + } ] + } + }, { + "localId" : "348", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "name" : "TenDividedByFourMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "348", + "s" : [ { + "value" : [ "", "define ", "TenDividedByFourMixed", ": " ] + }, { + "r" : "349", + "s" : [ { + "r" : "350", + "value" : [ "10", " / ", "4L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Divide", + "localId" : "349", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "358", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "359", + "name" : "{urn:hl7-org:elm-types:r1}Decimal", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToDecimal", + "localId" : "353", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "354", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "350", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "Hundred", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", "annotation" : [ ] } }, { "type" : "ToDecimal", - "localId" : "286", + "localId" : "356", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "287", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + "localId" : "357", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { - "type" : "ExpressionRef", - "localId" : "281", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "Four", + "type" : "Literal", + "localId" : "351", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "4", "annotation" : [ ] } } ] } }, { - "localId" : "292", + "localId" : "362", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", - "name" : "TenDividedByTwoLong", + "name" : "TenDividedByFourReverseMixed", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "292", + "r" : "362", "s" : [ { - "value" : [ "", "define ", "TenDividedByTwoLong", ": " ] + "value" : [ "", "define ", "TenDividedByFourReverseMixed", ": " ] }, { - "r" : "293", + "r" : "363", "s" : [ { - "r" : "294", - "value" : [ "10", " / ", "2" ] + "r" : "364", + "value" : [ "10L", " / ", "4" ] } ] } ] } } ], "expression" : { "type" : "Divide", - "localId" : "293", + "localId" : "363", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "302", + "localId" : "372", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "303", + "localId" : "373", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "297", + "localId" : "367", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "298", - "name" : "{urn:hl7-org:elm-types:r1}Integer", + "localId" : "368", + "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "294", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "localId" : "364", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "10", "annotation" : [ ] } }, { "type" : "ToDecimal", - "localId" : "300", + "localId" : "370", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "301", + "localId" : "371", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "295", + "localId" : "365", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", - "value" : "2", + "value" : "4", "annotation" : [ ] } } ] } }, { - "localId" : "306", + "localId" : "376", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "context" : "Patient", @@ -3404,25 +4185,25 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "306", + "r" : "376", "s" : [ { "value" : [ "", "define ", "UncertaintyTwoToFourteen", ": " ] }, { - "r" : "307", + "r" : "377", "s" : [ { "value" : [ "months between " ] }, { - "r" : "314", + "r" : "384", "s" : [ { - "r" : "308", + "r" : "378", "value" : [ "DateTime", "(", "2005", ", ", "10", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "321", + "r" : "391", "s" : [ { - "r" : "317", + "r" : "387", "value" : [ "DateTime", "(", "2006", ")" ] } ] } ] @@ -3431,40 +4212,40 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "307", + "localId" : "377", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "323", + "localId" : "393", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "324", + "localId" : "394", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "314", + "localId" : "384", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "315", + "localId" : "385", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "316", + "localId" : "386", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "308", + "localId" : "378", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -3472,7 +4253,7 @@ module.exports['Divide'] = { }, "month" : { "type" : "Literal", - "localId" : "309", + "localId" : "379", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "10", @@ -3480,18 +4261,18 @@ module.exports['Divide'] = { } }, { "type" : "DateTime", - "localId" : "321", + "localId" : "391", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "322", + "localId" : "392", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "317", + "localId" : "387", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -3500,7 +4281,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "327", + "localId" : "397", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "context" : "Patient", @@ -3509,25 +4290,25 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "327", + "r" : "397", "s" : [ { "value" : [ "", "define ", "UncertaintySixToEighteen", ": " ] }, { - "r" : "328", + "r" : "398", "s" : [ { "value" : [ "months between " ] }, { - "r" : "333", + "r" : "403", "s" : [ { - "r" : "329", + "r" : "399", "value" : [ "DateTime", "(", "2005", ")" ] } ] }, { "value" : [ " and " ] }, { - "r" : "341", + "r" : "411", "s" : [ { - "r" : "335", + "r" : "405", "value" : [ "DateTime", "(", "2006", ", ", "7", ")" ] } ] } ] @@ -3536,35 +4317,35 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "DurationBetween", - "localId" : "328", + "localId" : "398", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "precision" : "Month", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "344", + "localId" : "414", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "345", + "localId" : "415", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : [ { "type" : "DateTime", - "localId" : "333", + "localId" : "403", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "334", + "localId" : "404", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "329", + "localId" : "399", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2005", @@ -3572,23 +4353,23 @@ module.exports['Divide'] = { } }, { "type" : "DateTime", - "localId" : "341", + "localId" : "411", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "342", + "localId" : "412", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "343", + "localId" : "413", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "year" : { "type" : "Literal", - "localId" : "335", + "localId" : "405", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2006", @@ -3596,7 +4377,7 @@ module.exports['Divide'] = { }, "month" : { "type" : "Literal", - "localId" : "336", + "localId" : "406", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "7", @@ -3605,7 +4386,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "348", + "localId" : "418", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DivideUncertainties", "context" : "Patient", @@ -3614,20 +4395,20 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "348", + "r" : "418", "s" : [ { "value" : [ "", "define ", "DivideUncertainties", ": " ] }, { - "r" : "349", + "r" : "419", "s" : [ { - "r" : "350", + "r" : "420", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { "value" : [ " / " ] }, { - "r" : "351", + "r" : "421", "s" : [ { "value" : [ "UncertaintyTwoToFourteen" ] } ] @@ -3637,50 +4418,50 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "Divide", - "localId" : "349", + "localId" : "419", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "358", + "localId" : "428", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "359", + "localId" : "429", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "353", + "localId" : "423", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "354", + "localId" : "424", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "350", + "localId" : "420", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } }, { "type" : "ToDecimal", - "localId" : "356", + "localId" : "426", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "357", + "localId" : "427", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "351", + "localId" : "421", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintyTwoToFourteen", "annotation" : [ ] @@ -3688,7 +4469,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "362", + "localId" : "432", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DivideUncertaintyByNumber", "context" : "Patient", @@ -3697,18 +4478,18 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "362", + "r" : "432", "s" : [ { "value" : [ "", "define ", "DivideUncertaintyByNumber", ": " ] }, { - "r" : "363", + "r" : "433", "s" : [ { - "r" : "364", + "r" : "434", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] }, { - "r" : "365", + "r" : "435", "value" : [ " / ", "2" ] } ] } ] @@ -3716,50 +4497,50 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "Divide", - "localId" : "363", + "localId" : "433", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "372", + "localId" : "442", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "373", + "localId" : "443", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "367", + "localId" : "437", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "368", + "localId" : "438", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "364", + "localId" : "434", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] } }, { "type" : "ToDecimal", - "localId" : "370", + "localId" : "440", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "371", + "localId" : "441", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "365", + "localId" : "435", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2", @@ -3768,7 +4549,7 @@ module.exports['Divide'] = { } ] } }, { - "localId" : "376", + "localId" : "446", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DivideNumberByUncertainty", "context" : "Patient", @@ -3777,16 +4558,16 @@ module.exports['Divide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "376", + "r" : "446", "s" : [ { "value" : [ "", "define ", "DivideNumberByUncertainty", ": " ] }, { - "r" : "377", + "r" : "447", "s" : [ { - "r" : "378", + "r" : "448", "value" : [ "36", " / " ] }, { - "r" : "379", + "r" : "449", "s" : [ { "value" : [ "UncertaintySixToEighteen" ] } ] @@ -3796,33 +4577,33 @@ module.exports['Divide'] = { } ], "expression" : { "type" : "Divide", - "localId" : "377", + "localId" : "447", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "386", + "localId" : "456", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "387", + "localId" : "457", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "381", + "localId" : "451", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "382", + "localId" : "452", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "378", + "localId" : "448", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "36", @@ -3830,17 +4611,17 @@ module.exports['Divide'] = { } }, { "type" : "ToDecimal", - "localId" : "384", + "localId" : "454", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "385", + "localId" : "455", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "379", + "localId" : "449", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "name" : "UncertaintySixToEighteen", "annotation" : [ ] @@ -4491,6 +5272,8 @@ using Simple version '1.0.0' context Patient define Pow: 3 ^ 4 define ThreeExpFourLong: 3L ^ 4L +define ThreeExpFourMixed: 3 ^ 4L +define ThreeExpFourReverseMixed: 3L ^ 4 */ module.exports['Power'] = { @@ -4505,7 +5288,7 @@ module.exports['Power'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "222", + "r" : "241", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -4660,29 +5443,159 @@ module.exports['Power'] = { "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "226", + "localId" : "226", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "4", + "annotation" : [ ] + } ] + } + }, { + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "ThreeExpFourMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "230", + "s" : [ { + "value" : [ "", "define ", "ThreeExpFourMixed", ": " ] + }, { + "r" : "231", + "s" : [ { + "r" : "232", + "value" : [ "3", " ^ ", "4L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "231", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "237", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "238", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToLong", + "localId" : "235", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "236", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "3", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "233", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "4", + "annotation" : [ ] + } ] + } + }, { + "localId" : "241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "ThreeExpFourReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "241", + "s" : [ { + "value" : [ "", "define ", "ThreeExpFourReverseMixed", ": " ] + }, { + "r" : "242", + "s" : [ { + "r" : "243", + "value" : [ "3L", " ^ ", "4" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Power", + "localId" : "242", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "248", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "227", + "localId" : "249", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "224", + "localId" : "243", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "3", "annotation" : [ ] }, { - "type" : "Literal", - "localId" : "225", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "valueType" : "{urn:hl7-org:elm-types:r1}Long", - "value" : "4", - "annotation" : [ ] + "type" : "ToLong", + "localId" : "246", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "247", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "4", + "annotation" : [ ] + } } ] } } ] @@ -5295,6 +6208,8 @@ context Patient define Trunc: 10 div 3 define Even: 9 div 3 define TenDivThreeLong: 10L div 3L +define TenDivThreeMixed: 10 div 3L +define TenDivThreeReverseMixed: 10L div 3 */ module.exports['TruncatedDivide'] = { @@ -5309,7 +6224,7 @@ module.exports['TruncatedDivide'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "230", + "r" : "249", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5543,6 +6458,136 @@ module.exports['TruncatedDivide'] = { "annotation" : [ ] } ] } + }, { + "localId" : "238", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "TenDivThreeMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "238", + "s" : [ { + "value" : [ "", "define ", "TenDivThreeMixed", ": " ] + }, { + "r" : "239", + "s" : [ { + "r" : "240", + "value" : [ "10", " div ", "3L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "TruncatedDivide", + "localId" : "239", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "245", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "246", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToLong", + "localId" : "243", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "244", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "240", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "10", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + } ] + } + }, { + "localId" : "249", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "TenDivThreeReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "249", + "s" : [ { + "value" : [ "", "define ", "TenDivThreeReverseMixed", ": " ] + }, { + "r" : "250", + "s" : [ { + "r" : "251", + "value" : [ "10L", " div ", "3" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "TruncatedDivide", + "localId" : "250", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "256", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "257", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "251", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "10", + "annotation" : [ ] + }, { + "type" : "ToLong", + "localId" : "254", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "255", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "252", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "3", + "annotation" : [ ] + } + } ] + } } ] } } @@ -5554,6 +6599,8 @@ using Simple version '1.0.0' context Patient define Mod: 3 mod 2 define ThreeModTwoLong: 3L mod 2L +define ThreeModTwoMixed: 3 mod 2L +define ThreeModTwoReverseMixed: 3L mod 2 */ module.exports['Modulo'] = { @@ -5568,7 +6615,7 @@ module.exports['Modulo'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "222", + "r" : "241", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5718,34 +6765,164 @@ module.exports['Modulo'] = { } ], "expression" : { "type" : "Modulo", - "localId" : "223", + "localId" : "223", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "226", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "227", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "Literal", + "localId" : "224", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "3", + "annotation" : [ ] + }, { + "type" : "Literal", + "localId" : "225", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "230", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "ThreeModTwoMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "230", + "s" : [ { + "value" : [ "", "define ", "ThreeModTwoMixed", ": " ] + }, { + "r" : "231", + "s" : [ { + "r" : "232", + "value" : [ "3", " mod ", "2L" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Modulo", + "localId" : "231", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "237", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + }, { + "type" : "NamedTypeSpecifier", + "localId" : "238", + "name" : "{urn:hl7-org:elm-types:r1}Long", + "annotation" : [ ] + } ], + "operand" : [ { + "type" : "ToLong", + "localId" : "235", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "236", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "232", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "3", + "annotation" : [ ] + } + }, { + "type" : "Literal", + "localId" : "233", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "valueType" : "{urn:hl7-org:elm-types:r1}Long", + "value" : "2", + "annotation" : [ ] + } ] + } + }, { + "localId" : "241", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", + "name" : "ThreeModTwoReverseMixed", + "context" : "Patient", + "accessLevel" : "Public", + "annotation" : [ { + "type" : "Annotation", + "t" : [ ], + "s" : { + "r" : "241", + "s" : [ { + "value" : [ "", "define ", "ThreeModTwoReverseMixed", ": " ] + }, { + "r" : "242", + "s" : [ { + "r" : "243", + "value" : [ "3L", " mod ", "2" ] + } ] + } ] + } + } ], + "expression" : { + "type" : "Modulo", + "localId" : "242", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "226", + "localId" : "248", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "227", + "localId" : "249", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "224", + "localId" : "243", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "3", "annotation" : [ ] }, { - "type" : "Literal", - "localId" : "225", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "valueType" : "{urn:hl7-org:elm-types:r1}Long", - "value" : "2", - "annotation" : [ ] + "type" : "ToLong", + "localId" : "246", + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "247", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "Literal", + "localId" : "244", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "value" : "2", + "annotation" : [ ] + } } ] } } ] @@ -11437,8 +12614,8 @@ define LongMultiplyNearOverflow: maximum Long * 1L define LongMultiplyNearUnderflow: minimum Long * 1L define LongDivideOverflow: maximum Long / 0.5 define LongDivideUnderflow: minimum Long / 0.5 -define LongDivideNearOverflow: maximum Long / 1L -define LongDivideNearUnderflow: minimum Long / 1L +define LongDivideNearOverflow: ToLong(maximum Integer) / 1L +define LongDivideNearUnderflow: ToLong(minimum Integer) / 1L define LongDivideByZero: 1L / 0L define LongPowerOverflow: (maximum Long)^3L define LongPowerUnderflow: (minimum Long)^3L @@ -11553,7 +12730,7 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1509", + "r" : "1519", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -14317,17 +15494,24 @@ module.exports['OutOfBounds'] = { }, { "r" : "603", "s" : [ { - "r" : "605", + "r" : "609", "s" : [ { - "value" : [ "maximum", " " ] + "value" : [ "ToLong", "(" ] }, { - "r" : "604", + "r" : "605", "s" : [ { - "value" : [ "Long" ] + "value" : [ "maximum", " " ] + }, { + "r" : "604", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "value" : [ ")" ] } ] }, { - "r" : "606", + "r" : "611", "value" : [ " / ", "1L" ] } ] } ] @@ -14340,45 +15524,57 @@ module.exports['OutOfBounds'] = { "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "613", + "localId" : "618", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "614", + "localId" : "619", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "608", + "localId" : "613", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "609", + "localId" : "614", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { - "type" : "MaxValue", - "localId" : "605", + "type" : "ToLong", + "localId" : "609", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "valueType" : "{urn:hl7-org:elm-types:r1}Long", - "annotation" : [ ] + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "610", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MaxValue", + "localId" : "605", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } } }, { "type" : "ToDecimal", - "localId" : "611", + "localId" : "616", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "612", + "localId" : "617", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "606", + "localId" : "611", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -14387,7 +15583,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "617", + "localId" : "622", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "LongDivideNearUnderflow", "context" : "Patient", @@ -14396,23 +15592,30 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "617", + "r" : "622", "s" : [ { "value" : [ "", "define ", "LongDivideNearUnderflow", ": " ] }, { - "r" : "618", + "r" : "623", "s" : [ { - "r" : "620", + "r" : "629", "s" : [ { - "value" : [ "minimum", " " ] + "value" : [ "ToLong", "(" ] }, { - "r" : "619", + "r" : "625", "s" : [ { - "value" : [ "Long" ] + "value" : [ "minimum", " " ] + }, { + "r" : "624", + "s" : [ { + "value" : [ "Integer" ] + } ] } ] + }, { + "value" : [ ")" ] } ] }, { - "r" : "621", + "r" : "631", "value" : [ " / ", "1L" ] } ] } ] @@ -14420,50 +15623,62 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "618", + "localId" : "623", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "628", + "localId" : "638", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "629", + "localId" : "639", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "623", + "localId" : "633", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "624", + "localId" : "634", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { - "type" : "MinValue", - "localId" : "620", + "type" : "ToLong", + "localId" : "629", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "valueType" : "{urn:hl7-org:elm-types:r1}Long", - "annotation" : [ ] + "annotation" : [ ], + "signature" : [ { + "type" : "NamedTypeSpecifier", + "localId" : "630", + "name" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } ], + "operand" : { + "type" : "MinValue", + "localId" : "625", + "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", + "valueType" : "{urn:hl7-org:elm-types:r1}Integer", + "annotation" : [ ] + } } }, { "type" : "ToDecimal", - "localId" : "626", + "localId" : "636", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "627", + "localId" : "637", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "621", + "localId" : "631", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -14472,7 +15687,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "632", + "localId" : "642", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "LongDivideByZero", "context" : "Patient", @@ -14481,13 +15696,13 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "632", + "r" : "642", "s" : [ { "value" : [ "", "define ", "LongDivideByZero", ": " ] }, { - "r" : "633", + "r" : "643", "s" : [ { - "r" : "634", + "r" : "644", "value" : [ "1L", " / ", "0L" ] } ] } ] @@ -14495,33 +15710,33 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "633", + "localId" : "643", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "642", + "localId" : "652", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "643", + "localId" : "653", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "ToDecimal", - "localId" : "637", + "localId" : "647", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "638", + "localId" : "648", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "634", + "localId" : "644", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -14529,17 +15744,17 @@ module.exports['OutOfBounds'] = { } }, { "type" : "ToDecimal", - "localId" : "640", + "localId" : "650", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "641", + "localId" : "651", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "635", + "localId" : "645", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "0", @@ -14548,7 +15763,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "646", + "localId" : "656", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongPowerOverflow", "context" : "Patient", @@ -14557,21 +15772,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "646", + "r" : "656", "s" : [ { "value" : [ "", "define ", "LongPowerOverflow", ": " ] }, { - "r" : "647", + "r" : "657", "s" : [ { - "r" : "649", + "r" : "659", "s" : [ { "value" : [ "(" ] }, { - "r" : "649", + "r" : "659", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "648", + "r" : "658", "s" : [ { "value" : [ "Long" ] } ] @@ -14580,7 +15795,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "650", + "r" : "660", "value" : [ "^", "3L" ] } ] } ] @@ -14588,29 +15803,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "647", + "localId" : "657", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "651", + "localId" : "661", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "652", + "localId" : "662", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "649", + "localId" : "659", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "650", + "localId" : "660", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "3", @@ -14618,7 +15833,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "655", + "localId" : "665", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongPowerUnderflow", "context" : "Patient", @@ -14627,21 +15842,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "655", + "r" : "665", "s" : [ { "value" : [ "", "define ", "LongPowerUnderflow", ": " ] }, { - "r" : "656", + "r" : "666", "s" : [ { - "r" : "658", + "r" : "668", "s" : [ { "value" : [ "(" ] }, { - "r" : "658", + "r" : "668", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "657", + "r" : "667", "s" : [ { "value" : [ "Long" ] } ] @@ -14650,7 +15865,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "659", + "r" : "669", "value" : [ "^", "3L" ] } ] } ] @@ -14658,29 +15873,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "656", + "localId" : "666", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "660", + "localId" : "670", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "661", + "localId" : "671", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "658", + "localId" : "668", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "659", + "localId" : "669", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "3", @@ -14688,7 +15903,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "664", + "localId" : "674", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongPowerNearOverflow", "context" : "Patient", @@ -14697,21 +15912,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "664", + "r" : "674", "s" : [ { "value" : [ "", "define ", "LongPowerNearOverflow", ": " ] }, { - "r" : "665", + "r" : "675", "s" : [ { - "r" : "667", + "r" : "677", "s" : [ { "value" : [ "(" ] }, { - "r" : "667", + "r" : "677", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "666", + "r" : "676", "s" : [ { "value" : [ "Long" ] } ] @@ -14720,7 +15935,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "668", + "r" : "678", "value" : [ "^", "1L" ] } ] } ] @@ -14728,29 +15943,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "665", + "localId" : "675", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "669", + "localId" : "679", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "670", + "localId" : "680", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "667", + "localId" : "677", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "668", + "localId" : "678", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -14758,7 +15973,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "673", + "localId" : "683", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongPowerNearUnderflow", "context" : "Patient", @@ -14767,21 +15982,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "673", + "r" : "683", "s" : [ { "value" : [ "", "define ", "LongPowerNearUnderflow", ": " ] }, { - "r" : "674", + "r" : "684", "s" : [ { - "r" : "676", + "r" : "686", "s" : [ { "value" : [ "(" ] }, { - "r" : "676", + "r" : "686", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "675", + "r" : "685", "s" : [ { "value" : [ "Long" ] } ] @@ -14790,7 +16005,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "677", + "r" : "687", "value" : [ "^", "1L" ] } ] } ] @@ -14798,29 +16013,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "674", + "localId" : "684", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "678", + "localId" : "688", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "679", + "localId" : "689", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "676", + "localId" : "686", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "677", + "localId" : "687", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -14828,7 +16043,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "682", + "localId" : "692", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongSuccessorOverflow", "context" : "Patient", @@ -14837,19 +16052,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "682", + "r" : "692", "s" : [ { "value" : [ "", "define ", "LongSuccessorOverflow", ": " ] }, { - "r" : "685", + "r" : "695", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "684", + "r" : "694", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "683", + "r" : "693", "s" : [ { "value" : [ "Long" ] } ] @@ -14860,25 +16075,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "685", + "localId" : "695", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "686", + "localId" : "696", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "684", + "localId" : "694", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } } }, { - "localId" : "689", + "localId" : "699", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongPredecessorUnderflow", "context" : "Patient", @@ -14887,19 +16102,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "689", + "r" : "699", "s" : [ { "value" : [ "", "define ", "LongPredecessorUnderflow", ": " ] }, { - "r" : "692", + "r" : "702", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "691", + "r" : "701", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "690", + "r" : "700", "s" : [ { "value" : [ "Long" ] } ] @@ -14910,25 +16125,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "692", + "localId" : "702", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "693", + "localId" : "703", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "MinValue", - "localId" : "691", + "localId" : "701", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } } }, { - "localId" : "696", + "localId" : "706", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongSuccessorNearOverflow", "context" : "Patient", @@ -14937,31 +16152,31 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "696", + "r" : "706", "s" : [ { "value" : [ "", "define ", "LongSuccessorNearOverflow", ": " ] }, { - "r" : "703", + "r" : "713", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "697", + "r" : "707", "s" : [ { "value" : [ "(" ] }, { - "r" : "697", + "r" : "707", "s" : [ { - "r" : "699", + "r" : "709", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "698", + "r" : "708", "s" : [ { "value" : [ "Long" ] } ] } ] }, { - "r" : "700", + "r" : "710", "value" : [ " - ", "1L" ] } ] }, { @@ -14973,40 +16188,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "703", + "localId" : "713", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "704", + "localId" : "714", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Subtract", - "localId" : "697", + "localId" : "707", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "701", + "localId" : "711", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "702", + "localId" : "712", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "699", + "localId" : "709", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "700", + "localId" : "710", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -15015,7 +16230,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "707", + "localId" : "717", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "LongPredecessorNearUnderflow", "context" : "Patient", @@ -15024,31 +16239,31 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "707", + "r" : "717", "s" : [ { "value" : [ "", "define ", "LongPredecessorNearUnderflow", ": " ] }, { - "r" : "714", + "r" : "724", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "708", + "r" : "718", "s" : [ { "value" : [ "(" ] }, { - "r" : "708", + "r" : "718", "s" : [ { - "r" : "710", + "r" : "720", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "709", + "r" : "719", "s" : [ { "value" : [ "Long" ] } ] } ] }, { - "r" : "711", + "r" : "721", "value" : [ " + ", "1L" ] } ] }, { @@ -15060,40 +16275,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "714", + "localId" : "724", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "715", + "localId" : "725", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : { "type" : "Add", - "localId" : "708", + "localId" : "718", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "712", + "localId" : "722", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "713", + "localId" : "723", "name" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "710", + "localId" : "720", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "711", + "localId" : "721", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "valueType" : "{urn:hl7-org:elm-types:r1}Long", "value" : "1", @@ -15102,7 +16317,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "718", + "localId" : "728", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalAddOverflow", "context" : "Patient", @@ -15111,23 +16326,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "718", + "r" : "728", "s" : [ { "value" : [ "", "define ", "DecimalAddOverflow", ": " ] }, { - "r" : "719", + "r" : "729", "s" : [ { - "r" : "721", + "r" : "731", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "720", + "r" : "730", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "722", + "r" : "732", "value" : [ " + ", "1.0" ] } ] } ] @@ -15135,29 +16350,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "719", + "localId" : "729", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "723", + "localId" : "733", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "724", + "localId" : "734", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "721", + "localId" : "731", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "722", + "localId" : "732", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", @@ -15165,7 +16380,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "727", + "localId" : "737", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalAddUnderflow", "context" : "Patient", @@ -15174,17 +16389,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "727", + "r" : "737", "s" : [ { "value" : [ "", "define ", "DecimalAddUnderflow", ": " ] }, { - "r" : "728", + "r" : "738", "s" : [ { - "r" : "730", + "r" : "740", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "729", + "r" : "739", "s" : [ { "value" : [ "Decimal" ] } ] @@ -15192,9 +16407,9 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "731", + "r" : "741", "s" : [ { - "r" : "732", + "r" : "742", "value" : [ "-", "1.0" ] } ] } ] @@ -15203,40 +16418,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "728", + "localId" : "738", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "734", + "localId" : "744", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "735", + "localId" : "745", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "730", + "localId" : "740", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "731", + "localId" : "741", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "733", + "localId" : "743", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "732", + "localId" : "742", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", @@ -15245,7 +16460,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "738", + "localId" : "748", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalAddNearOverflow", "context" : "Patient", @@ -15254,23 +16469,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "738", + "r" : "748", "s" : [ { "value" : [ "", "define ", "DecimalAddNearOverflow", ": " ] }, { - "r" : "739", + "r" : "749", "s" : [ { - "r" : "741", + "r" : "751", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "740", + "r" : "750", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "742", + "r" : "752", "value" : [ " + ", "0.0" ] } ] } ] @@ -15278,29 +16493,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "739", + "localId" : "749", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "743", + "localId" : "753", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "744", + "localId" : "754", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "741", + "localId" : "751", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "742", + "localId" : "752", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.0", @@ -15308,7 +16523,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "747", + "localId" : "757", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalAddNearUnderflow", "context" : "Patient", @@ -15317,23 +16532,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "747", + "r" : "757", "s" : [ { "value" : [ "", "define ", "DecimalAddNearUnderflow", ": " ] }, { - "r" : "748", + "r" : "758", "s" : [ { - "r" : "750", + "r" : "760", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "749", + "r" : "759", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "751", + "r" : "761", "value" : [ " + ", "0.0" ] } ] } ] @@ -15341,29 +16556,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "748", + "localId" : "758", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "752", + "localId" : "762", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "753", + "localId" : "763", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "750", + "localId" : "760", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "751", + "localId" : "761", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.0", @@ -15371,7 +16586,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "756", + "localId" : "766", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalSubtractOverflow", "context" : "Patient", @@ -15380,17 +16595,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "756", + "r" : "766", "s" : [ { "value" : [ "", "define ", "DecimalSubtractOverflow", ": " ] }, { - "r" : "757", + "r" : "767", "s" : [ { - "r" : "759", + "r" : "769", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "758", + "r" : "768", "s" : [ { "value" : [ "Decimal" ] } ] @@ -15398,9 +16613,9 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "760", + "r" : "770", "s" : [ { - "r" : "761", + "r" : "771", "value" : [ "-", "1.0" ] } ] } ] @@ -15409,40 +16624,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "757", + "localId" : "767", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "763", + "localId" : "773", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "764", + "localId" : "774", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "759", + "localId" : "769", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "760", + "localId" : "770", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "762", + "localId" : "772", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "761", + "localId" : "771", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", @@ -15451,7 +16666,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "767", + "localId" : "777", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalSubtractUnderflow", "context" : "Patient", @@ -15460,23 +16675,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "767", + "r" : "777", "s" : [ { "value" : [ "", "define ", "DecimalSubtractUnderflow", ": " ] }, { - "r" : "768", + "r" : "778", "s" : [ { - "r" : "770", + "r" : "780", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "769", + "r" : "779", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "771", + "r" : "781", "value" : [ " - ", "1.0" ] } ] } ] @@ -15484,29 +16699,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "768", + "localId" : "778", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "772", + "localId" : "782", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "773", + "localId" : "783", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "770", + "localId" : "780", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "771", + "localId" : "781", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", @@ -15514,7 +16729,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "776", + "localId" : "786", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalSubtractNearOverflow", "context" : "Patient", @@ -15523,23 +16738,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "776", + "r" : "786", "s" : [ { "value" : [ "", "define ", "DecimalSubtractNearOverflow", ": " ] }, { - "r" : "777", + "r" : "787", "s" : [ { - "r" : "779", + "r" : "789", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "778", + "r" : "788", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "780", + "r" : "790", "value" : [ " - ", "0.0" ] } ] } ] @@ -15547,29 +16762,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "777", + "localId" : "787", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "781", + "localId" : "791", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "782", + "localId" : "792", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "779", + "localId" : "789", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "780", + "localId" : "790", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.0", @@ -15577,7 +16792,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "785", + "localId" : "795", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalSubtractNearUnderflow", "context" : "Patient", @@ -15586,23 +16801,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "785", + "r" : "795", "s" : [ { "value" : [ "", "define ", "DecimalSubtractNearUnderflow", ": " ] }, { - "r" : "786", + "r" : "796", "s" : [ { - "r" : "788", + "r" : "798", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "787", + "r" : "797", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "789", + "r" : "799", "value" : [ " - ", "0.0" ] } ] } ] @@ -15610,29 +16825,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "786", + "localId" : "796", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "790", + "localId" : "800", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "791", + "localId" : "801", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "788", + "localId" : "798", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "789", + "localId" : "799", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.0", @@ -15640,7 +16855,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "794", + "localId" : "804", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalMultiplyOverflow", "context" : "Patient", @@ -15649,23 +16864,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "794", + "r" : "804", "s" : [ { "value" : [ "", "define ", "DecimalMultiplyOverflow", ": " ] }, { - "r" : "795", + "r" : "805", "s" : [ { - "r" : "797", + "r" : "807", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "796", + "r" : "806", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "798", + "r" : "808", "value" : [ " * ", "2" ] } ] } ] @@ -15673,39 +16888,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "795", + "localId" : "805", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "802", + "localId" : "812", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "803", + "localId" : "813", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "797", + "localId" : "807", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "800", + "localId" : "810", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "801", + "localId" : "811", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "798", + "localId" : "808", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2", @@ -15714,7 +16929,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "806", + "localId" : "816", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalMultiplyUnderflow", "context" : "Patient", @@ -15723,23 +16938,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "806", + "r" : "816", "s" : [ { "value" : [ "", "define ", "DecimalMultiplyUnderflow", ": " ] }, { - "r" : "807", + "r" : "817", "s" : [ { - "r" : "809", + "r" : "819", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "808", + "r" : "818", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "810", + "r" : "820", "value" : [ " * ", "2" ] } ] } ] @@ -15747,39 +16962,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "807", + "localId" : "817", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "814", + "localId" : "824", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "815", + "localId" : "825", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "809", + "localId" : "819", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "812", + "localId" : "822", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "813", + "localId" : "823", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "810", + "localId" : "820", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2", @@ -15788,7 +17003,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "818", + "localId" : "828", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalMultiplyNearOverflow", "context" : "Patient", @@ -15797,23 +17012,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "818", + "r" : "828", "s" : [ { "value" : [ "", "define ", "DecimalMultiplyNearOverflow", ": " ] }, { - "r" : "819", + "r" : "829", "s" : [ { - "r" : "821", + "r" : "831", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "820", + "r" : "830", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "822", + "r" : "832", "value" : [ " * ", "1" ] } ] } ] @@ -15821,39 +17036,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "819", + "localId" : "829", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "826", + "localId" : "836", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "827", + "localId" : "837", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "821", + "localId" : "831", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "824", + "localId" : "834", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "825", + "localId" : "835", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "822", + "localId" : "832", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "1", @@ -15862,7 +17077,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "830", + "localId" : "840", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalMultiplyNearUnderflow", "context" : "Patient", @@ -15871,23 +17086,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "830", + "r" : "840", "s" : [ { "value" : [ "", "define ", "DecimalMultiplyNearUnderflow", ": " ] }, { - "r" : "831", + "r" : "841", "s" : [ { - "r" : "833", + "r" : "843", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "832", + "r" : "842", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "834", + "r" : "844", "value" : [ " * ", "1" ] } ] } ] @@ -15895,39 +17110,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "831", + "localId" : "841", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "838", + "localId" : "848", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "839", + "localId" : "849", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "833", + "localId" : "843", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "836", + "localId" : "846", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "837", + "localId" : "847", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "834", + "localId" : "844", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "1", @@ -15936,7 +17151,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "842", + "localId" : "852", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalDivideOverflow", "context" : "Patient", @@ -15945,23 +17160,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "842", + "r" : "852", "s" : [ { "value" : [ "", "define ", "DecimalDivideOverflow", ": " ] }, { - "r" : "843", + "r" : "853", "s" : [ { - "r" : "845", + "r" : "855", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "844", + "r" : "854", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "846", + "r" : "856", "value" : [ " / ", "0.5" ] } ] } ] @@ -15969,29 +17184,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "843", + "localId" : "853", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "847", + "localId" : "857", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "848", + "localId" : "858", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "845", + "localId" : "855", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "846", + "localId" : "856", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.5", @@ -15999,7 +17214,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "851", + "localId" : "861", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalDivideUnderflow", "context" : "Patient", @@ -16008,23 +17223,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "851", + "r" : "861", "s" : [ { "value" : [ "", "define ", "DecimalDivideUnderflow", ": " ] }, { - "r" : "852", + "r" : "862", "s" : [ { - "r" : "854", + "r" : "864", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "853", + "r" : "863", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "855", + "r" : "865", "value" : [ " / ", "0.5" ] } ] } ] @@ -16032,29 +17247,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "852", + "localId" : "862", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "856", + "localId" : "866", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "857", + "localId" : "867", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "854", + "localId" : "864", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "855", + "localId" : "865", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.5", @@ -16062,7 +17277,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "860", + "localId" : "870", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalDivideNearOverflow", "context" : "Patient", @@ -16071,23 +17286,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "860", + "r" : "870", "s" : [ { "value" : [ "", "define ", "DecimalDivideNearOverflow", ": " ] }, { - "r" : "861", + "r" : "871", "s" : [ { - "r" : "863", + "r" : "873", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "862", + "r" : "872", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "864", + "r" : "874", "value" : [ " / ", "1.0" ] } ] } ] @@ -16095,29 +17310,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "861", + "localId" : "871", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "865", + "localId" : "875", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "866", + "localId" : "876", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "863", + "localId" : "873", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "864", + "localId" : "874", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", @@ -16125,7 +17340,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "869", + "localId" : "879", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalDivideNearUnderflow", "context" : "Patient", @@ -16134,23 +17349,23 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "869", + "r" : "879", "s" : [ { "value" : [ "", "define ", "DecimalDivideNearUnderflow", ": " ] }, { - "r" : "870", + "r" : "880", "s" : [ { - "r" : "872", + "r" : "882", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "871", + "r" : "881", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "873", + "r" : "883", "value" : [ " / ", "1.0" ] } ] } ] @@ -16158,29 +17373,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "870", + "localId" : "880", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "874", + "localId" : "884", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "875", + "localId" : "885", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "872", + "localId" : "882", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "873", + "localId" : "883", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", @@ -16188,7 +17403,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "878", + "localId" : "888", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalDivideByZero", "context" : "Patient", @@ -16197,13 +17412,13 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "878", + "r" : "888", "s" : [ { "value" : [ "", "define ", "DecimalDivideByZero", ": " ] }, { - "r" : "879", + "r" : "889", "s" : [ { - "r" : "880", + "r" : "890", "value" : [ "1.0", " / ", "0" ] } ] } ] @@ -16211,40 +17426,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "879", + "localId" : "889", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "885", + "localId" : "895", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "886", + "localId" : "896", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "Literal", - "localId" : "880", + "localId" : "890", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "1.0", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "883", + "localId" : "893", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "884", + "localId" : "894", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "881", + "localId" : "891", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "0", @@ -16253,7 +17468,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "889", + "localId" : "899", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalPowerOverflow", "context" : "Patient", @@ -16262,21 +17477,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "889", + "r" : "899", "s" : [ { "value" : [ "", "define ", "DecimalPowerOverflow", ": " ] }, { - "r" : "890", + "r" : "900", "s" : [ { - "r" : "892", + "r" : "902", "s" : [ { "value" : [ "(" ] }, { - "r" : "892", + "r" : "902", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "891", + "r" : "901", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16285,7 +17500,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "893", + "r" : "903", "value" : [ "^", "2" ] } ] } ] @@ -16293,39 +17508,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "890", + "localId" : "900", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "897", + "localId" : "907", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "898", + "localId" : "908", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "892", + "localId" : "902", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "895", + "localId" : "905", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "896", + "localId" : "906", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "893", + "localId" : "903", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "2", @@ -16334,7 +17549,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "901", + "localId" : "911", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalPowerUnderflow", "context" : "Patient", @@ -16343,21 +17558,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "901", + "r" : "911", "s" : [ { "value" : [ "", "define ", "DecimalPowerUnderflow", ": " ] }, { - "r" : "902", + "r" : "912", "s" : [ { - "r" : "904", + "r" : "914", "s" : [ { "value" : [ "(" ] }, { - "r" : "904", + "r" : "914", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "903", + "r" : "913", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16366,7 +17581,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "905", + "r" : "915", "value" : [ "^", "3" ] } ] } ] @@ -16374,39 +17589,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "902", + "localId" : "912", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "909", + "localId" : "919", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "910", + "localId" : "920", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "904", + "localId" : "914", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "907", + "localId" : "917", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "908", + "localId" : "918", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "905", + "localId" : "915", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "3", @@ -16415,7 +17630,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "913", + "localId" : "923", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalPowerNearOverflow", "context" : "Patient", @@ -16424,21 +17639,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "913", + "r" : "923", "s" : [ { "value" : [ "", "define ", "DecimalPowerNearOverflow", ": " ] }, { - "r" : "914", + "r" : "924", "s" : [ { - "r" : "916", + "r" : "926", "s" : [ { "value" : [ "(" ] }, { - "r" : "916", + "r" : "926", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "915", + "r" : "925", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16447,7 +17662,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "917", + "r" : "927", "value" : [ "^", "1" ] } ] } ] @@ -16455,39 +17670,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "914", + "localId" : "924", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "921", + "localId" : "931", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "922", + "localId" : "932", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "916", + "localId" : "926", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "919", + "localId" : "929", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "920", + "localId" : "930", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "917", + "localId" : "927", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "1", @@ -16496,7 +17711,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "925", + "localId" : "935", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalPowerNearUnderflow", "context" : "Patient", @@ -16505,21 +17720,21 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "925", + "r" : "935", "s" : [ { "value" : [ "", "define ", "DecimalPowerNearUnderflow", ": " ] }, { - "r" : "926", + "r" : "936", "s" : [ { - "r" : "928", + "r" : "938", "s" : [ { "value" : [ "(" ] }, { - "r" : "928", + "r" : "938", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "927", + "r" : "937", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16528,7 +17743,7 @@ module.exports['OutOfBounds'] = { "value" : [ ")" ] } ] }, { - "r" : "929", + "r" : "939", "value" : [ "^", "1" ] } ] } ] @@ -16536,39 +17751,39 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Power", - "localId" : "926", + "localId" : "936", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "933", + "localId" : "943", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "934", + "localId" : "944", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "928", + "localId" : "938", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "ToDecimal", - "localId" : "931", + "localId" : "941", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "932", + "localId" : "942", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "929", + "localId" : "939", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "1", @@ -16577,7 +17792,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "937", + "localId" : "947", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalSuccessorOverflow", "context" : "Patient", @@ -16586,19 +17801,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "937", + "r" : "947", "s" : [ { "value" : [ "", "define ", "DecimalSuccessorOverflow", ": " ] }, { - "r" : "940", + "r" : "950", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "939", + "r" : "949", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "938", + "r" : "948", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16609,25 +17824,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "940", + "localId" : "950", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "941", + "localId" : "951", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "939", + "localId" : "949", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } } }, { - "localId" : "944", + "localId" : "954", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalPredecessorUnderflow", "context" : "Patient", @@ -16636,19 +17851,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "944", + "r" : "954", "s" : [ { "value" : [ "", "define ", "DecimalPredecessorUnderflow", ": " ] }, { - "r" : "947", + "r" : "957", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "946", + "r" : "956", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "945", + "r" : "955", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16659,25 +17874,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "947", + "localId" : "957", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "948", + "localId" : "958", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "MinValue", - "localId" : "946", + "localId" : "956", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } } }, { - "localId" : "951", + "localId" : "961", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalSuccessorNearOverflow", "context" : "Patient", @@ -16686,31 +17901,31 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "951", + "r" : "961", "s" : [ { "value" : [ "", "define ", "DecimalSuccessorNearOverflow", ": " ] }, { - "r" : "958", + "r" : "968", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "952", + "r" : "962", "s" : [ { "value" : [ "(" ] }, { - "r" : "952", + "r" : "962", "s" : [ { - "r" : "954", + "r" : "964", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "953", + "r" : "963", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "955", + "r" : "965", "value" : [ " - ", "0.00000001" ] } ] }, { @@ -16722,40 +17937,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "958", + "localId" : "968", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "959", + "localId" : "969", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "Subtract", - "localId" : "952", + "localId" : "962", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "956", + "localId" : "966", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "957", + "localId" : "967", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "954", + "localId" : "964", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "955", + "localId" : "965", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.00000001", @@ -16764,7 +17979,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "962", + "localId" : "972", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "DecimalPredecessorNearUnderflow", "context" : "Patient", @@ -16773,31 +17988,31 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "962", + "r" : "972", "s" : [ { "value" : [ "", "define ", "DecimalPredecessorNearUnderflow", ": " ] }, { - "r" : "969", + "r" : "979", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "963", + "r" : "973", "s" : [ { "value" : [ "(" ] }, { - "r" : "963", + "r" : "973", "s" : [ { - "r" : "965", + "r" : "975", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "964", + "r" : "974", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "966", + "r" : "976", "value" : [ " + ", "0.00000001" ] } ] }, { @@ -16809,40 +18024,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "969", + "localId" : "979", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "970", + "localId" : "980", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "Add", - "localId" : "963", + "localId" : "973", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "967", + "localId" : "977", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "968", + "localId" : "978", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "965", + "localId" : "975", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "966", + "localId" : "976", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.00000001", @@ -16851,7 +18066,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "973", + "localId" : "983", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "context" : "Patient", @@ -16860,22 +18075,22 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "973", + "r" : "983", "s" : [ { "value" : [ "", "define ", "MaxQuantity", ": " ] }, { - "r" : "974", + "r" : "984", "s" : [ { "value" : [ "Quantity", " { " ] }, { "s" : [ { "value" : [ "value", ": " ] }, { - "r" : "977", + "r" : "987", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "976", + "r" : "986", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16887,7 +18102,7 @@ module.exports['OutOfBounds'] = { "s" : [ { "value" : [ "unit", ": " ] }, { - "r" : "978", + "r" : "988", "s" : [ { "value" : [ "'mm'" ] } ] @@ -16900,7 +18115,7 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Instance", - "localId" : "974", + "localId" : "984", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "classType" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], @@ -16908,7 +18123,7 @@ module.exports['OutOfBounds'] = { "name" : "value", "value" : { "type" : "MaxValue", - "localId" : "977", + "localId" : "987", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] @@ -16917,7 +18132,7 @@ module.exports['OutOfBounds'] = { "name" : "unit", "value" : { "type" : "Literal", - "localId" : "978", + "localId" : "988", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", "value" : "mm", @@ -16926,7 +18141,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "982", + "localId" : "992", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "context" : "Patient", @@ -16935,22 +18150,22 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "982", + "r" : "992", "s" : [ { "value" : [ "", "define ", "MinQuantity", ": " ] }, { - "r" : "983", + "r" : "993", "s" : [ { "value" : [ "Quantity", " { " ] }, { "s" : [ { "value" : [ "value", ": " ] }, { - "r" : "986", + "r" : "996", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "985", + "r" : "995", "s" : [ { "value" : [ "Decimal" ] } ] @@ -16962,7 +18177,7 @@ module.exports['OutOfBounds'] = { "s" : [ { "value" : [ "unit", ": " ] }, { - "r" : "987", + "r" : "997", "s" : [ { "value" : [ "'mm'" ] } ] @@ -16975,7 +18190,7 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Instance", - "localId" : "983", + "localId" : "993", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "classType" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], @@ -16983,7 +18198,7 @@ module.exports['OutOfBounds'] = { "name" : "value", "value" : { "type" : "MinValue", - "localId" : "986", + "localId" : "996", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] @@ -16992,7 +18207,7 @@ module.exports['OutOfBounds'] = { "name" : "unit", "value" : { "type" : "Literal", - "localId" : "987", + "localId" : "997", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", "value" : "mm", @@ -17001,7 +18216,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "991", + "localId" : "1001", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityAddOverflow", "context" : "Patient", @@ -17010,20 +18225,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "991", + "r" : "1001", "s" : [ { "value" : [ "", "define ", "QuantityAddOverflow", ": " ] }, { - "r" : "992", + "r" : "1002", "s" : [ { - "r" : "993", + "r" : "1003", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " + " ] }, { - "r" : "994", + "r" : "1004", "s" : [ { "value" : [ "1.0 ", "'mm'" ] } ] @@ -17033,29 +18248,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "992", + "localId" : "1002", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "995", + "localId" : "1005", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "996", + "localId" : "1006", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "993", + "localId" : "1003", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "994", + "localId" : "1004", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1.0, "unit" : "mm", @@ -17063,7 +18278,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "999", + "localId" : "1009", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityAddUnderflow", "context" : "Patient", @@ -17072,28 +18287,28 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "999", + "r" : "1009", "s" : [ { "value" : [ "", "define ", "QuantityAddUnderflow", ": " ] }, { - "r" : "1000", + "r" : "1010", "s" : [ { - "r" : "1001", + "r" : "1011", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " + " ] }, { - "r" : "1002", + "r" : "1012", "s" : [ { "value" : [ "(" ] }, { - "r" : "1002", + "r" : "1012", "s" : [ { "value" : [ "-" ] }, { - "r" : "1003", + "r" : "1013", "s" : [ { "value" : [ "1.0 ", "'mm'" ] } ] @@ -17107,40 +18322,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1000", + "localId" : "1010", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1005", + "localId" : "1015", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1006", + "localId" : "1016", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1001", + "localId" : "1011", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1002", + "localId" : "1012", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1004", + "localId" : "1014", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1003", + "localId" : "1013", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1.0, "unit" : "mm", @@ -17149,7 +18364,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1009", + "localId" : "1019", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityAddNearOverflow", "context" : "Patient", @@ -17158,20 +18373,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1009", + "r" : "1019", "s" : [ { "value" : [ "", "define ", "QuantityAddNearOverflow", ": " ] }, { - "r" : "1010", + "r" : "1020", "s" : [ { - "r" : "1011", + "r" : "1021", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " + " ] }, { - "r" : "1012", + "r" : "1022", "s" : [ { "value" : [ "0.0 ", "'mm'" ] } ] @@ -17181,29 +18396,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1010", + "localId" : "1020", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1013", + "localId" : "1023", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1014", + "localId" : "1024", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1011", + "localId" : "1021", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1012", + "localId" : "1022", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0.0, "unit" : "mm", @@ -17211,7 +18426,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1017", + "localId" : "1027", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityAddNearUnderflow", "context" : "Patient", @@ -17220,20 +18435,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1017", + "r" : "1027", "s" : [ { "value" : [ "", "define ", "QuantityAddNearUnderflow", ": " ] }, { - "r" : "1018", + "r" : "1028", "s" : [ { - "r" : "1019", + "r" : "1029", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " + " ] }, { - "r" : "1020", + "r" : "1030", "s" : [ { "value" : [ "0.0 ", "'mm'" ] } ] @@ -17243,29 +18458,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1018", + "localId" : "1028", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1021", + "localId" : "1031", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1022", + "localId" : "1032", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1019", + "localId" : "1029", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1020", + "localId" : "1030", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0.0, "unit" : "mm", @@ -17273,7 +18488,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1025", + "localId" : "1035", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantitySubtractOverflow", "context" : "Patient", @@ -17282,28 +18497,28 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1025", + "r" : "1035", "s" : [ { "value" : [ "", "define ", "QuantitySubtractOverflow", ": " ] }, { - "r" : "1026", + "r" : "1036", "s" : [ { - "r" : "1027", + "r" : "1037", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " - " ] }, { - "r" : "1028", + "r" : "1038", "s" : [ { "value" : [ "(" ] }, { - "r" : "1028", + "r" : "1038", "s" : [ { "value" : [ "-" ] }, { - "r" : "1029", + "r" : "1039", "s" : [ { "value" : [ "1 ", "'mm'" ] } ] @@ -17317,40 +18532,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1026", + "localId" : "1036", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1031", + "localId" : "1041", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1032", + "localId" : "1042", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1027", + "localId" : "1037", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1028", + "localId" : "1038", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1030", + "localId" : "1040", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1029", + "localId" : "1039", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "mm", @@ -17359,7 +18574,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1035", + "localId" : "1045", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantitySubtractUnderflow", "context" : "Patient", @@ -17368,20 +18583,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1035", + "r" : "1045", "s" : [ { "value" : [ "", "define ", "QuantitySubtractUnderflow", ": " ] }, { - "r" : "1036", + "r" : "1046", "s" : [ { - "r" : "1037", + "r" : "1047", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " - " ] }, { - "r" : "1038", + "r" : "1048", "s" : [ { "value" : [ "1 ", "'mm'" ] } ] @@ -17391,29 +18606,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1036", + "localId" : "1046", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1039", + "localId" : "1049", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1040", + "localId" : "1050", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1037", + "localId" : "1047", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1038", + "localId" : "1048", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "mm", @@ -17421,7 +18636,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1043", + "localId" : "1053", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantitySubtractNearOverflow", "context" : "Patient", @@ -17430,20 +18645,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1043", + "r" : "1053", "s" : [ { "value" : [ "", "define ", "QuantitySubtractNearOverflow", ": " ] }, { - "r" : "1044", + "r" : "1054", "s" : [ { - "r" : "1045", + "r" : "1055", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " - " ] }, { - "r" : "1046", + "r" : "1056", "s" : [ { "value" : [ "0.0 ", "'mm'" ] } ] @@ -17453,29 +18668,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1044", + "localId" : "1054", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1047", + "localId" : "1057", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1048", + "localId" : "1058", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1045", + "localId" : "1055", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1046", + "localId" : "1056", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0.0, "unit" : "mm", @@ -17483,7 +18698,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1051", + "localId" : "1061", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantitySubtractNearUnderflow", "context" : "Patient", @@ -17492,20 +18707,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1051", + "r" : "1061", "s" : [ { "value" : [ "", "define ", "QuantitySubtractNearUnderflow", ": " ] }, { - "r" : "1052", + "r" : "1062", "s" : [ { - "r" : "1053", + "r" : "1063", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " - " ] }, { - "r" : "1054", + "r" : "1064", "s" : [ { "value" : [ "0.0 ", "'mm'" ] } ] @@ -17515,29 +18730,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1052", + "localId" : "1062", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1055", + "localId" : "1065", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1056", + "localId" : "1066", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1053", + "localId" : "1063", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1054", + "localId" : "1064", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0.0, "unit" : "mm", @@ -17545,7 +18760,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1059", + "localId" : "1069", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityMultiplyOverflow", "context" : "Patient", @@ -17554,20 +18769,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1059", + "r" : "1069", "s" : [ { "value" : [ "", "define ", "QuantityMultiplyOverflow", ": " ] }, { - "r" : "1060", + "r" : "1070", "s" : [ { - "r" : "1061", + "r" : "1071", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " * " ] }, { - "r" : "1062", + "r" : "1072", "s" : [ { "value" : [ "2 ", "'mm'" ] } ] @@ -17577,29 +18792,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "1060", + "localId" : "1070", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1063", + "localId" : "1073", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1064", + "localId" : "1074", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1061", + "localId" : "1071", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1062", + "localId" : "1072", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 2, "unit" : "mm", @@ -17607,7 +18822,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1067", + "localId" : "1077", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityMultiplyUnderflow", "context" : "Patient", @@ -17616,20 +18831,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1067", + "r" : "1077", "s" : [ { "value" : [ "", "define ", "QuantityMultiplyUnderflow", ": " ] }, { - "r" : "1068", + "r" : "1078", "s" : [ { - "r" : "1069", + "r" : "1079", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " * " ] }, { - "r" : "1070", + "r" : "1080", "s" : [ { "value" : [ "2 ", "'mm'" ] } ] @@ -17639,29 +18854,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "1068", + "localId" : "1078", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1071", + "localId" : "1081", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1072", + "localId" : "1082", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1069", + "localId" : "1079", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1070", + "localId" : "1080", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 2, "unit" : "mm", @@ -17669,7 +18884,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1075", + "localId" : "1085", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityMultiplyNearOverflow", "context" : "Patient", @@ -17678,20 +18893,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1075", + "r" : "1085", "s" : [ { "value" : [ "", "define ", "QuantityMultiplyNearOverflow", ": " ] }, { - "r" : "1076", + "r" : "1086", "s" : [ { - "r" : "1077", + "r" : "1087", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " * " ] }, { - "r" : "1078", + "r" : "1088", "s" : [ { "value" : [ "1 ", "'mm'" ] } ] @@ -17701,29 +18916,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "1076", + "localId" : "1086", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1079", + "localId" : "1089", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1080", + "localId" : "1090", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1077", + "localId" : "1087", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1078", + "localId" : "1088", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "mm", @@ -17731,7 +18946,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1083", + "localId" : "1093", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityMultiplyNearUnderflow", "context" : "Patient", @@ -17740,20 +18955,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1083", + "r" : "1093", "s" : [ { "value" : [ "", "define ", "QuantityMultiplyNearUnderflow", ": " ] }, { - "r" : "1084", + "r" : "1094", "s" : [ { - "r" : "1085", + "r" : "1095", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " * " ] }, { - "r" : "1086", + "r" : "1096", "s" : [ { "value" : [ "1 ", "'mm'" ] } ] @@ -17763,29 +18978,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Multiply", - "localId" : "1084", + "localId" : "1094", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1087", + "localId" : "1097", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1088", + "localId" : "1098", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1085", + "localId" : "1095", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1086", + "localId" : "1096", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "mm", @@ -17793,7 +19008,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1091", + "localId" : "1101", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityDivideOverflow", "context" : "Patient", @@ -17802,20 +19017,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1091", + "r" : "1101", "s" : [ { "value" : [ "", "define ", "QuantityDivideOverflow", ": " ] }, { - "r" : "1092", + "r" : "1102", "s" : [ { - "r" : "1093", + "r" : "1103", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " / " ] }, { - "r" : "1094", + "r" : "1104", "s" : [ { "value" : [ "0.5 ", "'mm'" ] } ] @@ -17825,29 +19040,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "1092", + "localId" : "1102", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1095", + "localId" : "1105", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1096", + "localId" : "1106", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1093", + "localId" : "1103", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1094", + "localId" : "1104", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0.5, "unit" : "mm", @@ -17855,7 +19070,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1099", + "localId" : "1109", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityDivideUnderflow", "context" : "Patient", @@ -17864,20 +19079,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1099", + "r" : "1109", "s" : [ { "value" : [ "", "define ", "QuantityDivideUnderflow", ": " ] }, { - "r" : "1100", + "r" : "1110", "s" : [ { - "r" : "1101", + "r" : "1111", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " / " ] }, { - "r" : "1102", + "r" : "1112", "s" : [ { "value" : [ "0.5 ", "'mm'" ] } ] @@ -17887,29 +19102,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "1100", + "localId" : "1110", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1103", + "localId" : "1113", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1104", + "localId" : "1114", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1101", + "localId" : "1111", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1102", + "localId" : "1112", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0.5, "unit" : "mm", @@ -17917,7 +19132,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1107", + "localId" : "1117", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityDivideNearOverflow", "context" : "Patient", @@ -17926,20 +19141,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1107", + "r" : "1117", "s" : [ { "value" : [ "", "define ", "QuantityDivideNearOverflow", ": " ] }, { - "r" : "1108", + "r" : "1118", "s" : [ { - "r" : "1109", + "r" : "1119", "s" : [ { "value" : [ "MaxQuantity" ] } ] }, { "value" : [ " / " ] }, { - "r" : "1110", + "r" : "1120", "s" : [ { "value" : [ "1 ", "'mm'" ] } ] @@ -17949,29 +19164,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "1108", + "localId" : "1118", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1111", + "localId" : "1121", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1112", + "localId" : "1122", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1109", + "localId" : "1119", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1110", + "localId" : "1120", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "mm", @@ -17979,7 +19194,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1115", + "localId" : "1125", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityDivideNearUnderflow", "context" : "Patient", @@ -17988,20 +19203,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1115", + "r" : "1125", "s" : [ { "value" : [ "", "define ", "QuantityDivideNearUnderflow", ": " ] }, { - "r" : "1116", + "r" : "1126", "s" : [ { - "r" : "1117", + "r" : "1127", "s" : [ { "value" : [ "MinQuantity" ] } ] }, { "value" : [ " / " ] }, { - "r" : "1118", + "r" : "1128", "s" : [ { "value" : [ "1 ", "'mm'" ] } ] @@ -18011,29 +19226,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "1116", + "localId" : "1126", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1119", + "localId" : "1129", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1120", + "localId" : "1130", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "ExpressionRef", - "localId" : "1117", + "localId" : "1127", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1118", + "localId" : "1128", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "mm", @@ -18041,7 +19256,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1123", + "localId" : "1133", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityDivideByZero", "context" : "Patient", @@ -18050,20 +19265,20 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1123", + "r" : "1133", "s" : [ { "value" : [ "", "define ", "QuantityDivideByZero", ": " ] }, { - "r" : "1124", + "r" : "1134", "s" : [ { - "r" : "1125", + "r" : "1135", "s" : [ { "value" : [ "1.0 ", "'mm'" ] } ] }, { "value" : [ " / " ] }, { - "r" : "1126", + "r" : "1136", "s" : [ { "value" : [ "0 ", "'mm'" ] } ] @@ -18073,30 +19288,30 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Divide", - "localId" : "1124", + "localId" : "1134", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1127", + "localId" : "1137", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1128", + "localId" : "1138", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "Quantity", - "localId" : "1125", + "localId" : "1135", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1.0, "unit" : "mm", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1126", + "localId" : "1136", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "mm", @@ -18104,7 +19319,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1131", + "localId" : "1141", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantitySuccessorOverflow", "context" : "Patient", @@ -18113,15 +19328,15 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1131", + "r" : "1141", "s" : [ { "value" : [ "", "define ", "QuantitySuccessorOverflow", ": " ] }, { - "r" : "1133", + "r" : "1143", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1132", + "r" : "1142", "s" : [ { "value" : [ "MaxQuantity" ] } ] @@ -18131,25 +19346,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1133", + "localId" : "1143", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1134", + "localId" : "1144", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "1132", + "localId" : "1142", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MaxQuantity", "annotation" : [ ] } } }, { - "localId" : "1137", + "localId" : "1147", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityPredecessorUnderflow", "context" : "Patient", @@ -18158,15 +19373,15 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1137", + "r" : "1147", "s" : [ { "value" : [ "", "define ", "QuantityPredecessorUnderflow", ": " ] }, { - "r" : "1139", + "r" : "1149", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1138", + "r" : "1148", "s" : [ { "value" : [ "MinQuantity" ] } ] @@ -18176,25 +19391,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1139", + "localId" : "1149", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1140", + "localId" : "1150", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "ExpressionRef", - "localId" : "1138", + "localId" : "1148", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "MinQuantity", "annotation" : [ ] } } }, { - "localId" : "1143", + "localId" : "1153", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantitySuccessorNearOverflow", "context" : "Patient", @@ -18203,34 +19418,34 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1143", + "r" : "1153", "s" : [ { "value" : [ "", "define ", "QuantitySuccessorNearOverflow", ": " ] }, { - "r" : "1154", + "r" : "1164", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1144", + "r" : "1154", "s" : [ { "value" : [ "Quantity", " { " ] }, { "s" : [ { "value" : [ "value", ": " ] }, { - "r" : "1146", + "r" : "1156", "s" : [ { - "r" : "1148", + "r" : "1158", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1147", + "r" : "1157", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "1149", + "r" : "1159", "value" : [ " - ", "0.00000001" ] } ] } ] @@ -18240,7 +19455,7 @@ module.exports['OutOfBounds'] = { "s" : [ { "value" : [ "unit", ": " ] }, { - "r" : "1152", + "r" : "1162", "s" : [ { "value" : [ "'mm'" ] } ] @@ -18254,18 +19469,18 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1154", + "localId" : "1164", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1155", + "localId" : "1165", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Instance", - "localId" : "1144", + "localId" : "1154", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "classType" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], @@ -18273,29 +19488,29 @@ module.exports['OutOfBounds'] = { "name" : "value", "value" : { "type" : "Subtract", - "localId" : "1146", + "localId" : "1156", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1150", + "localId" : "1160", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1151", + "localId" : "1161", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1148", + "localId" : "1158", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "1149", + "localId" : "1159", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.00000001", @@ -18306,7 +19521,7 @@ module.exports['OutOfBounds'] = { "name" : "unit", "value" : { "type" : "Literal", - "localId" : "1152", + "localId" : "1162", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", "value" : "mm", @@ -18316,7 +19531,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1158", + "localId" : "1168", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "name" : "QuantityPredecessorNearUnderflow", "context" : "Patient", @@ -18325,34 +19540,34 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1158", + "r" : "1168", "s" : [ { "value" : [ "", "define ", "QuantityPredecessorNearUnderflow", ": " ] }, { - "r" : "1169", + "r" : "1179", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1159", + "r" : "1169", "s" : [ { "value" : [ "Quantity", " { " ] }, { "s" : [ { "value" : [ "value", ": " ] }, { - "r" : "1161", + "r" : "1171", "s" : [ { - "r" : "1163", + "r" : "1173", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1162", + "r" : "1172", "s" : [ { "value" : [ "Decimal" ] } ] } ] }, { - "r" : "1164", + "r" : "1174", "value" : [ " + ", "0.00000001" ] } ] } ] @@ -18362,7 +19577,7 @@ module.exports['OutOfBounds'] = { "s" : [ { "value" : [ "unit", ": " ] }, { - "r" : "1167", + "r" : "1177", "s" : [ { "value" : [ "'mm'" ] } ] @@ -18376,18 +19591,18 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1169", + "localId" : "1179", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1170", + "localId" : "1180", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Instance", - "localId" : "1159", + "localId" : "1169", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "classType" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], @@ -18395,29 +19610,29 @@ module.exports['OutOfBounds'] = { "name" : "value", "value" : { "type" : "Add", - "localId" : "1161", + "localId" : "1171", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1165", + "localId" : "1175", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1166", + "localId" : "1176", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1163", + "localId" : "1173", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] }, { "type" : "Literal", - "localId" : "1164", + "localId" : "1174", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "value" : "0.00000001", @@ -18428,7 +19643,7 @@ module.exports['OutOfBounds'] = { "name" : "unit", "value" : { "type" : "Literal", - "localId" : "1167", + "localId" : "1177", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", "value" : "mm", @@ -18438,7 +19653,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1173", + "localId" : "1183", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeAddOverflow", "context" : "Patient", @@ -18447,17 +19662,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1173", + "r" : "1183", "s" : [ { "value" : [ "", "define ", "DateTimeAddOverflow", ": " ] }, { - "r" : "1174", + "r" : "1184", "s" : [ { - "r" : "1176", + "r" : "1186", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1175", + "r" : "1185", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18465,7 +19680,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1177", + "r" : "1187", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -18475,29 +19690,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1174", + "localId" : "1184", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1178", + "localId" : "1188", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1179", + "localId" : "1189", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1176", + "localId" : "1186", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1177", + "localId" : "1187", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -18505,7 +19720,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1182", + "localId" : "1192", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeAddUnderflow", "context" : "Patient", @@ -18514,17 +19729,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1182", + "r" : "1192", "s" : [ { "value" : [ "", "define ", "DateTimeAddUnderflow", ": " ] }, { - "r" : "1183", + "r" : "1193", "s" : [ { - "r" : "1185", + "r" : "1195", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1184", + "r" : "1194", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18532,15 +19747,15 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1186", + "r" : "1196", "s" : [ { "value" : [ "(" ] }, { - "r" : "1186", + "r" : "1196", "s" : [ { "value" : [ "-" ] }, { - "r" : "1187", + "r" : "1197", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -18554,40 +19769,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1183", + "localId" : "1193", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1189", + "localId" : "1199", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1190", + "localId" : "1200", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1185", + "localId" : "1195", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1186", + "localId" : "1196", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1188", + "localId" : "1198", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1187", + "localId" : "1197", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -18596,7 +19811,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1193", + "localId" : "1203", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeAddNearOverflow", "context" : "Patient", @@ -18605,17 +19820,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1193", + "r" : "1203", "s" : [ { "value" : [ "", "define ", "DateTimeAddNearOverflow", ": " ] }, { - "r" : "1194", + "r" : "1204", "s" : [ { - "r" : "1196", + "r" : "1206", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1195", + "r" : "1205", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18623,7 +19838,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1197", + "r" : "1207", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -18633,29 +19848,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1194", + "localId" : "1204", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1198", + "localId" : "1208", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1199", + "localId" : "1209", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1196", + "localId" : "1206", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1197", + "localId" : "1207", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -18663,7 +19878,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1202", + "localId" : "1212", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeAddNearUnderflow", "context" : "Patient", @@ -18672,17 +19887,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1202", + "r" : "1212", "s" : [ { "value" : [ "", "define ", "DateTimeAddNearUnderflow", ": " ] }, { - "r" : "1203", + "r" : "1213", "s" : [ { - "r" : "1205", + "r" : "1215", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1204", + "r" : "1214", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18690,7 +19905,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1206", + "r" : "1216", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -18700,29 +19915,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1203", + "localId" : "1213", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1207", + "localId" : "1217", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1208", + "localId" : "1218", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1205", + "localId" : "1215", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1206", + "localId" : "1216", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -18730,7 +19945,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1211", + "localId" : "1221", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeSubtractOverflow", "context" : "Patient", @@ -18739,17 +19954,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1211", + "r" : "1221", "s" : [ { "value" : [ "", "define ", "DateTimeSubtractOverflow", ": " ] }, { - "r" : "1212", + "r" : "1222", "s" : [ { - "r" : "1214", + "r" : "1224", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1213", + "r" : "1223", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18757,15 +19972,15 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1215", + "r" : "1225", "s" : [ { "value" : [ "(" ] }, { - "r" : "1215", + "r" : "1225", "s" : [ { "value" : [ "-" ] }, { - "r" : "1216", + "r" : "1226", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -18779,40 +19994,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1212", + "localId" : "1222", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1218", + "localId" : "1228", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1219", + "localId" : "1229", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1214", + "localId" : "1224", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1215", + "localId" : "1225", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1217", + "localId" : "1227", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1216", + "localId" : "1226", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -18821,7 +20036,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1222", + "localId" : "1232", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeSubtractUnderflow", "context" : "Patient", @@ -18830,17 +20045,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1222", + "r" : "1232", "s" : [ { "value" : [ "", "define ", "DateTimeSubtractUnderflow", ": " ] }, { - "r" : "1223", + "r" : "1233", "s" : [ { - "r" : "1225", + "r" : "1235", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1224", + "r" : "1234", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18848,7 +20063,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1226", + "r" : "1236", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -18858,29 +20073,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1223", + "localId" : "1233", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1227", + "localId" : "1237", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1228", + "localId" : "1238", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1225", + "localId" : "1235", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1226", + "localId" : "1236", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -18888,7 +20103,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1231", + "localId" : "1241", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeSubtractNearOverflow", "context" : "Patient", @@ -18897,17 +20112,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1231", + "r" : "1241", "s" : [ { "value" : [ "", "define ", "DateTimeSubtractNearOverflow", ": " ] }, { - "r" : "1232", + "r" : "1242", "s" : [ { - "r" : "1234", + "r" : "1244", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1233", + "r" : "1243", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18915,7 +20130,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1235", + "r" : "1245", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -18925,29 +20140,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1232", + "localId" : "1242", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1236", + "localId" : "1246", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1237", + "localId" : "1247", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1234", + "localId" : "1244", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1235", + "localId" : "1245", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -18955,7 +20170,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1240", + "localId" : "1250", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeSubtractNearUnderflow", "context" : "Patient", @@ -18964,17 +20179,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1240", + "r" : "1250", "s" : [ { "value" : [ "", "define ", "DateTimeSubtractNearUnderflow", ": " ] }, { - "r" : "1241", + "r" : "1251", "s" : [ { - "r" : "1243", + "r" : "1253", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1242", + "r" : "1252", "s" : [ { "value" : [ "DateTime" ] } ] @@ -18982,7 +20197,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1244", + "r" : "1254", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -18992,29 +20207,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1241", + "localId" : "1251", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1245", + "localId" : "1255", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1246", + "localId" : "1256", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1243", + "localId" : "1253", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1244", + "localId" : "1254", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -19022,7 +20237,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1249", + "localId" : "1259", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeSuccessorOverflow", "context" : "Patient", @@ -19031,19 +20246,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1249", + "r" : "1259", "s" : [ { "value" : [ "", "define ", "DateTimeSuccessorOverflow", ": " ] }, { - "r" : "1252", + "r" : "1262", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1251", + "r" : "1261", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1250", + "r" : "1260", "s" : [ { "value" : [ "DateTime" ] } ] @@ -19054,25 +20269,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1252", + "localId" : "1262", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1253", + "localId" : "1263", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "1251", + "localId" : "1261", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } } }, { - "localId" : "1256", + "localId" : "1266", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimePredecessorUnderflow", "context" : "Patient", @@ -19081,19 +20296,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1256", + "r" : "1266", "s" : [ { "value" : [ "", "define ", "DateTimePredecessorUnderflow", ": " ] }, { - "r" : "1259", + "r" : "1269", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1258", + "r" : "1268", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1257", + "r" : "1267", "s" : [ { "value" : [ "DateTime" ] } ] @@ -19104,25 +20319,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1259", + "localId" : "1269", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1260", + "localId" : "1270", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "MinValue", - "localId" : "1258", + "localId" : "1268", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } } }, { - "localId" : "1263", + "localId" : "1273", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimeSuccessorNearOverflow", "context" : "Patient", @@ -19131,25 +20346,25 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1263", + "r" : "1273", "s" : [ { "value" : [ "", "define ", "DateTimeSuccessorNearOverflow", ": " ] }, { - "r" : "1270", + "r" : "1280", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1264", + "r" : "1274", "s" : [ { "value" : [ "(" ] }, { - "r" : "1264", + "r" : "1274", "s" : [ { - "r" : "1266", + "r" : "1276", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1265", + "r" : "1275", "s" : [ { "value" : [ "DateTime" ] } ] @@ -19157,7 +20372,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1267", + "r" : "1277", "s" : [ { "value" : [ "1 ", "millisecond" ] } ] @@ -19171,40 +20386,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1270", + "localId" : "1280", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1271", + "localId" : "1281", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "Subtract", - "localId" : "1264", + "localId" : "1274", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1268", + "localId" : "1278", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1269", + "localId" : "1279", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1266", + "localId" : "1276", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1267", + "localId" : "1277", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "millisecond", @@ -19213,7 +20428,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1274", + "localId" : "1284", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "name" : "DateTimePredecessorNearUnderflow", "context" : "Patient", @@ -19222,25 +20437,25 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1274", + "r" : "1284", "s" : [ { "value" : [ "", "define ", "DateTimePredecessorNearUnderflow", ": " ] }, { - "r" : "1281", + "r" : "1291", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1275", + "r" : "1285", "s" : [ { "value" : [ "(" ] }, { - "r" : "1275", + "r" : "1285", "s" : [ { - "r" : "1277", + "r" : "1287", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1276", + "r" : "1286", "s" : [ { "value" : [ "DateTime" ] } ] @@ -19248,7 +20463,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1278", + "r" : "1288", "s" : [ { "value" : [ "1 ", "millisecond" ] } ] @@ -19262,40 +20477,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1281", + "localId" : "1291", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1282", + "localId" : "1292", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] } ], "operand" : { "type" : "Add", - "localId" : "1275", + "localId" : "1285", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1279", + "localId" : "1289", "name" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1280", + "localId" : "1290", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1277", + "localId" : "1287", "resultTypeName" : "{urn:hl7-org:elm-types:r1}DateTime", "valueType" : "{urn:hl7-org:elm-types:r1}DateTime", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1278", + "localId" : "1288", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "millisecond", @@ -19304,7 +20519,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1285", + "localId" : "1295", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateAddOverflow", "context" : "Patient", @@ -19313,17 +20528,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1285", + "r" : "1295", "s" : [ { "value" : [ "", "define ", "DateAddOverflow", ": " ] }, { - "r" : "1286", + "r" : "1296", "s" : [ { - "r" : "1288", + "r" : "1298", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1287", + "r" : "1297", "s" : [ { "value" : [ "Date" ] } ] @@ -19331,7 +20546,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1289", + "r" : "1299", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -19341,29 +20556,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1286", + "localId" : "1296", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1290", + "localId" : "1300", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1291", + "localId" : "1301", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1288", + "localId" : "1298", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1289", + "localId" : "1299", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -19371,7 +20586,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1294", + "localId" : "1304", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateAddUnderflow", "context" : "Patient", @@ -19380,17 +20595,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1294", + "r" : "1304", "s" : [ { "value" : [ "", "define ", "DateAddUnderflow", ": " ] }, { - "r" : "1295", + "r" : "1305", "s" : [ { - "r" : "1297", + "r" : "1307", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1296", + "r" : "1306", "s" : [ { "value" : [ "Date" ] } ] @@ -19398,15 +20613,15 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1298", + "r" : "1308", "s" : [ { "value" : [ "(" ] }, { - "r" : "1298", + "r" : "1308", "s" : [ { "value" : [ "-" ] }, { - "r" : "1299", + "r" : "1309", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -19420,40 +20635,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1295", + "localId" : "1305", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1301", + "localId" : "1311", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1302", + "localId" : "1312", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1297", + "localId" : "1307", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1298", + "localId" : "1308", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1300", + "localId" : "1310", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1299", + "localId" : "1309", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -19462,7 +20677,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1305", + "localId" : "1315", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateAddNearOverflow", "context" : "Patient", @@ -19471,17 +20686,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1305", + "r" : "1315", "s" : [ { "value" : [ "", "define ", "DateAddNearOverflow", ": " ] }, { - "r" : "1306", + "r" : "1316", "s" : [ { - "r" : "1308", + "r" : "1318", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1307", + "r" : "1317", "s" : [ { "value" : [ "Date" ] } ] @@ -19489,7 +20704,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1309", + "r" : "1319", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -19499,29 +20714,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1306", + "localId" : "1316", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1310", + "localId" : "1320", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1311", + "localId" : "1321", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1308", + "localId" : "1318", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1309", + "localId" : "1319", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -19529,7 +20744,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1314", + "localId" : "1324", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateAddNearUnderflow", "context" : "Patient", @@ -19538,17 +20753,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1314", + "r" : "1324", "s" : [ { "value" : [ "", "define ", "DateAddNearUnderflow", ": " ] }, { - "r" : "1315", + "r" : "1325", "s" : [ { - "r" : "1317", + "r" : "1327", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1316", + "r" : "1326", "s" : [ { "value" : [ "Date" ] } ] @@ -19556,7 +20771,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1318", + "r" : "1328", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -19566,29 +20781,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1315", + "localId" : "1325", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1319", + "localId" : "1329", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1320", + "localId" : "1330", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1317", + "localId" : "1327", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1318", + "localId" : "1328", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -19596,7 +20811,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1323", + "localId" : "1333", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateSubtractOverflow", "context" : "Patient", @@ -19605,17 +20820,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1323", + "r" : "1333", "s" : [ { "value" : [ "", "define ", "DateSubtractOverflow", ": " ] }, { - "r" : "1324", + "r" : "1334", "s" : [ { - "r" : "1326", + "r" : "1336", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1325", + "r" : "1335", "s" : [ { "value" : [ "Date" ] } ] @@ -19623,15 +20838,15 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1327", + "r" : "1337", "s" : [ { "value" : [ "(" ] }, { - "r" : "1327", + "r" : "1337", "s" : [ { "value" : [ "-" ] }, { - "r" : "1328", + "r" : "1338", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -19645,40 +20860,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1324", + "localId" : "1334", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1330", + "localId" : "1340", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1331", + "localId" : "1341", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1326", + "localId" : "1336", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1327", + "localId" : "1337", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1329", + "localId" : "1339", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1328", + "localId" : "1338", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -19687,7 +20902,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1334", + "localId" : "1344", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateSubtractUnderflow", "context" : "Patient", @@ -19696,17 +20911,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1334", + "r" : "1344", "s" : [ { "value" : [ "", "define ", "DateSubtractUnderflow", ": " ] }, { - "r" : "1335", + "r" : "1345", "s" : [ { - "r" : "1337", + "r" : "1347", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1336", + "r" : "1346", "s" : [ { "value" : [ "Date" ] } ] @@ -19714,7 +20929,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1338", + "r" : "1348", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -19724,29 +20939,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1335", + "localId" : "1345", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1339", + "localId" : "1349", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1340", + "localId" : "1350", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1337", + "localId" : "1347", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1338", + "localId" : "1348", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -19754,7 +20969,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1343", + "localId" : "1353", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateSubtractNearOverflow", "context" : "Patient", @@ -19763,17 +20978,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1343", + "r" : "1353", "s" : [ { "value" : [ "", "define ", "DateSubtractNearOverflow", ": " ] }, { - "r" : "1344", + "r" : "1354", "s" : [ { - "r" : "1346", + "r" : "1356", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1345", + "r" : "1355", "s" : [ { "value" : [ "Date" ] } ] @@ -19781,7 +20996,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1347", + "r" : "1357", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -19791,29 +21006,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1344", + "localId" : "1354", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1348", + "localId" : "1358", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1349", + "localId" : "1359", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1346", + "localId" : "1356", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1347", + "localId" : "1357", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -19821,7 +21036,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1352", + "localId" : "1362", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateSubtractNearUnderflow", "context" : "Patient", @@ -19830,17 +21045,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1352", + "r" : "1362", "s" : [ { "value" : [ "", "define ", "DateSubtractNearUnderflow", ": " ] }, { - "r" : "1353", + "r" : "1363", "s" : [ { - "r" : "1355", + "r" : "1365", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1354", + "r" : "1364", "s" : [ { "value" : [ "Date" ] } ] @@ -19848,7 +21063,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1356", + "r" : "1366", "s" : [ { "value" : [ "0 ", "days" ] } ] @@ -19858,29 +21073,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1353", + "localId" : "1363", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1357", + "localId" : "1367", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1358", + "localId" : "1368", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1355", + "localId" : "1365", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1356", + "localId" : "1366", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "days", @@ -19888,7 +21103,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1361", + "localId" : "1371", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateSuccessorOverflow", "context" : "Patient", @@ -19897,19 +21112,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1361", + "r" : "1371", "s" : [ { "value" : [ "", "define ", "DateSuccessorOverflow", ": " ] }, { - "r" : "1364", + "r" : "1374", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1363", + "r" : "1373", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1362", + "r" : "1372", "s" : [ { "value" : [ "Date" ] } ] @@ -19920,25 +21135,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1364", + "localId" : "1374", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1365", + "localId" : "1375", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "1363", + "localId" : "1373", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] } } }, { - "localId" : "1368", + "localId" : "1378", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DatePredecessorUnderflow", "context" : "Patient", @@ -19947,19 +21162,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1368", + "r" : "1378", "s" : [ { "value" : [ "", "define ", "DatePredecessorUnderflow", ": " ] }, { - "r" : "1371", + "r" : "1381", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1370", + "r" : "1380", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1369", + "r" : "1379", "s" : [ { "value" : [ "Date" ] } ] @@ -19970,25 +21185,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1371", + "localId" : "1381", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1372", + "localId" : "1382", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] } ], "operand" : { "type" : "MinValue", - "localId" : "1370", + "localId" : "1380", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] } } }, { - "localId" : "1375", + "localId" : "1385", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DateSuccessorNearOverflow", "context" : "Patient", @@ -19997,25 +21212,25 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1375", + "r" : "1385", "s" : [ { "value" : [ "", "define ", "DateSuccessorNearOverflow", ": " ] }, { - "r" : "1382", + "r" : "1392", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1376", + "r" : "1386", "s" : [ { "value" : [ "(" ] }, { - "r" : "1376", + "r" : "1386", "s" : [ { - "r" : "1378", + "r" : "1388", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1377", + "r" : "1387", "s" : [ { "value" : [ "Date" ] } ] @@ -20023,7 +21238,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1379", + "r" : "1389", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -20037,40 +21252,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1382", + "localId" : "1392", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1383", + "localId" : "1393", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] } ], "operand" : { "type" : "Subtract", - "localId" : "1376", + "localId" : "1386", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1380", + "localId" : "1390", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1381", + "localId" : "1391", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1378", + "localId" : "1388", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1379", + "localId" : "1389", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -20079,7 +21294,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1386", + "localId" : "1396", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "name" : "DatePredecessorNearUnderflow", "context" : "Patient", @@ -20088,25 +21303,25 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1386", + "r" : "1396", "s" : [ { "value" : [ "", "define ", "DatePredecessorNearUnderflow", ": " ] }, { - "r" : "1393", + "r" : "1403", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1387", + "r" : "1397", "s" : [ { "value" : [ "(" ] }, { - "r" : "1387", + "r" : "1397", "s" : [ { - "r" : "1389", + "r" : "1399", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1388", + "r" : "1398", "s" : [ { "value" : [ "Date" ] } ] @@ -20114,7 +21329,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1390", + "r" : "1400", "s" : [ { "value" : [ "1 ", "day" ] } ] @@ -20128,40 +21343,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1393", + "localId" : "1403", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1394", + "localId" : "1404", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] } ], "operand" : { "type" : "Add", - "localId" : "1387", + "localId" : "1397", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1391", + "localId" : "1401", "name" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1392", + "localId" : "1402", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1389", + "localId" : "1399", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Date", "valueType" : "{urn:hl7-org:elm-types:r1}Date", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1390", + "localId" : "1400", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "day", @@ -20170,7 +21385,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1397", + "localId" : "1407", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeAddOverflow", "context" : "Patient", @@ -20179,17 +21394,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1397", + "r" : "1407", "s" : [ { "value" : [ "", "define ", "TimeAddOverflow", ": " ] }, { - "r" : "1398", + "r" : "1408", "s" : [ { - "r" : "1400", + "r" : "1410", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1399", + "r" : "1409", "s" : [ { "value" : [ "Time" ] } ] @@ -20197,7 +21412,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1401", + "r" : "1411", "s" : [ { "value" : [ "1 ", "second" ] } ] @@ -20207,29 +21422,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1398", + "localId" : "1408", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1402", + "localId" : "1412", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1403", + "localId" : "1413", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1400", + "localId" : "1410", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1401", + "localId" : "1411", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "second", @@ -20237,7 +21452,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1406", + "localId" : "1416", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeAddUnderflow", "context" : "Patient", @@ -20246,17 +21461,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1406", + "r" : "1416", "s" : [ { "value" : [ "", "define ", "TimeAddUnderflow", ": " ] }, { - "r" : "1407", + "r" : "1417", "s" : [ { - "r" : "1409", + "r" : "1419", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1408", + "r" : "1418", "s" : [ { "value" : [ "Time" ] } ] @@ -20264,15 +21479,15 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1410", + "r" : "1420", "s" : [ { "value" : [ "(" ] }, { - "r" : "1410", + "r" : "1420", "s" : [ { "value" : [ "-" ] }, { - "r" : "1411", + "r" : "1421", "s" : [ { "value" : [ "1 ", "second" ] } ] @@ -20286,40 +21501,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1407", + "localId" : "1417", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1413", + "localId" : "1423", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1414", + "localId" : "1424", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1409", + "localId" : "1419", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1410", + "localId" : "1420", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1412", + "localId" : "1422", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1411", + "localId" : "1421", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "second", @@ -20328,7 +21543,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1417", + "localId" : "1427", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeAddNearOverflow", "context" : "Patient", @@ -20337,17 +21552,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1417", + "r" : "1427", "s" : [ { "value" : [ "", "define ", "TimeAddNearOverflow", ": " ] }, { - "r" : "1418", + "r" : "1428", "s" : [ { - "r" : "1420", + "r" : "1430", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1419", + "r" : "1429", "s" : [ { "value" : [ "Time" ] } ] @@ -20355,7 +21570,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1421", + "r" : "1431", "s" : [ { "value" : [ "0 ", "seconds" ] } ] @@ -20365,29 +21580,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1418", + "localId" : "1428", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1422", + "localId" : "1432", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1423", + "localId" : "1433", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1420", + "localId" : "1430", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1421", + "localId" : "1431", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "seconds", @@ -20395,7 +21610,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1426", + "localId" : "1436", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeAddNearUnderflow", "context" : "Patient", @@ -20404,17 +21619,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1426", + "r" : "1436", "s" : [ { "value" : [ "", "define ", "TimeAddNearUnderflow", ": " ] }, { - "r" : "1427", + "r" : "1437", "s" : [ { - "r" : "1429", + "r" : "1439", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1428", + "r" : "1438", "s" : [ { "value" : [ "Time" ] } ] @@ -20422,7 +21637,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1430", + "r" : "1440", "s" : [ { "value" : [ "0 ", "seconds" ] } ] @@ -20432,29 +21647,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Add", - "localId" : "1427", + "localId" : "1437", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1431", + "localId" : "1441", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1432", + "localId" : "1442", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1429", + "localId" : "1439", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1430", + "localId" : "1440", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "seconds", @@ -20462,7 +21677,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1435", + "localId" : "1445", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSubtractOverflow", "context" : "Patient", @@ -20471,17 +21686,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1435", + "r" : "1445", "s" : [ { "value" : [ "", "define ", "TimeSubtractOverflow", ": " ] }, { - "r" : "1436", + "r" : "1446", "s" : [ { - "r" : "1438", + "r" : "1448", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1437", + "r" : "1447", "s" : [ { "value" : [ "Time" ] } ] @@ -20489,15 +21704,15 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1439", + "r" : "1449", "s" : [ { "value" : [ "(" ] }, { - "r" : "1439", + "r" : "1449", "s" : [ { "value" : [ "-" ] }, { - "r" : "1440", + "r" : "1450", "s" : [ { "value" : [ "1 ", "second" ] } ] @@ -20511,40 +21726,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1436", + "localId" : "1446", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1442", + "localId" : "1452", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1443", + "localId" : "1453", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1438", + "localId" : "1448", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Negate", - "localId" : "1439", + "localId" : "1449", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1441", + "localId" : "1451", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : { "type" : "Quantity", - "localId" : "1440", + "localId" : "1450", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "second", @@ -20553,7 +21768,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1446", + "localId" : "1456", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSubtractUnderflow", "context" : "Patient", @@ -20562,17 +21777,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1446", + "r" : "1456", "s" : [ { "value" : [ "", "define ", "TimeSubtractUnderflow", ": " ] }, { - "r" : "1447", + "r" : "1457", "s" : [ { - "r" : "1449", + "r" : "1459", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1448", + "r" : "1458", "s" : [ { "value" : [ "Time" ] } ] @@ -20580,7 +21795,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1450", + "r" : "1460", "s" : [ { "value" : [ "1 ", "second" ] } ] @@ -20590,29 +21805,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1447", + "localId" : "1457", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1451", + "localId" : "1461", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1452", + "localId" : "1462", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1449", + "localId" : "1459", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1450", + "localId" : "1460", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "second", @@ -20620,7 +21835,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1455", + "localId" : "1465", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSubtractNearOverflow", "context" : "Patient", @@ -20629,17 +21844,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1455", + "r" : "1465", "s" : [ { "value" : [ "", "define ", "TimeSubtractNearOverflow", ": " ] }, { - "r" : "1456", + "r" : "1466", "s" : [ { - "r" : "1458", + "r" : "1468", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1457", + "r" : "1467", "s" : [ { "value" : [ "Time" ] } ] @@ -20647,7 +21862,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1459", + "r" : "1469", "s" : [ { "value" : [ "0 ", "seconds" ] } ] @@ -20657,29 +21872,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1456", + "localId" : "1466", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1460", + "localId" : "1470", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1461", + "localId" : "1471", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1458", + "localId" : "1468", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1459", + "localId" : "1469", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "seconds", @@ -20687,7 +21902,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1464", + "localId" : "1474", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSubtractNearUnderflow", "context" : "Patient", @@ -20696,17 +21911,17 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1464", + "r" : "1474", "s" : [ { "value" : [ "", "define ", "TimeSubtractNearUnderflow", ": " ] }, { - "r" : "1465", + "r" : "1475", "s" : [ { - "r" : "1467", + "r" : "1477", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1466", + "r" : "1476", "s" : [ { "value" : [ "Time" ] } ] @@ -20714,7 +21929,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1468", + "r" : "1478", "s" : [ { "value" : [ "0 ", "seconds" ] } ] @@ -20724,29 +21939,29 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Subtract", - "localId" : "1465", + "localId" : "1475", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1469", + "localId" : "1479", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1470", + "localId" : "1480", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1467", + "localId" : "1477", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1468", + "localId" : "1478", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 0, "unit" : "seconds", @@ -20754,7 +21969,7 @@ module.exports['OutOfBounds'] = { } ] } }, { - "localId" : "1473", + "localId" : "1483", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSuccessorOverflow", "context" : "Patient", @@ -20763,19 +21978,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1473", + "r" : "1483", "s" : [ { "value" : [ "", "define ", "TimeSuccessorOverflow", ": " ] }, { - "r" : "1476", + "r" : "1486", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1475", + "r" : "1485", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1474", + "r" : "1484", "s" : [ { "value" : [ "Time" ] } ] @@ -20786,25 +22001,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1476", + "localId" : "1486", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1477", + "localId" : "1487", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "1475", + "localId" : "1485", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } } }, { - "localId" : "1480", + "localId" : "1490", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimePredecessorUnderflow", "context" : "Patient", @@ -20813,19 +22028,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1480", + "r" : "1490", "s" : [ { "value" : [ "", "define ", "TimePredecessorUnderflow", ": " ] }, { - "r" : "1483", + "r" : "1493", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1482", + "r" : "1492", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1481", + "r" : "1491", "s" : [ { "value" : [ "Time" ] } ] @@ -20836,25 +22051,25 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1483", + "localId" : "1493", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1484", + "localId" : "1494", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } ], "operand" : { "type" : "MinValue", - "localId" : "1482", + "localId" : "1492", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } } }, { - "localId" : "1487", + "localId" : "1497", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimeSuccessorNearOverflow", "context" : "Patient", @@ -20863,25 +22078,25 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1487", + "r" : "1497", "s" : [ { "value" : [ "", "define ", "TimeSuccessorNearOverflow", ": " ] }, { - "r" : "1494", + "r" : "1504", "s" : [ { "value" : [ "successor of " ] }, { - "r" : "1488", + "r" : "1498", "s" : [ { "value" : [ "(" ] }, { - "r" : "1488", + "r" : "1498", "s" : [ { - "r" : "1490", + "r" : "1500", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1489", + "r" : "1499", "s" : [ { "value" : [ "Time" ] } ] @@ -20889,7 +22104,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " - " ] }, { - "r" : "1491", + "r" : "1501", "s" : [ { "value" : [ "1 ", "millisecond" ] } ] @@ -20903,40 +22118,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Successor", - "localId" : "1494", + "localId" : "1504", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1495", + "localId" : "1505", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } ], "operand" : { "type" : "Subtract", - "localId" : "1488", + "localId" : "1498", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1492", + "localId" : "1502", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1493", + "localId" : "1503", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MaxValue", - "localId" : "1490", + "localId" : "1500", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1491", + "localId" : "1501", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "millisecond", @@ -20945,7 +22160,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1498", + "localId" : "1508", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "name" : "TimePredecessorNearUnderflow", "context" : "Patient", @@ -20954,25 +22169,25 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1498", + "r" : "1508", "s" : [ { "value" : [ "", "define ", "TimePredecessorNearUnderflow", ": " ] }, { - "r" : "1505", + "r" : "1515", "s" : [ { "value" : [ "predecessor of " ] }, { - "r" : "1499", + "r" : "1509", "s" : [ { "value" : [ "(" ] }, { - "r" : "1499", + "r" : "1509", "s" : [ { - "r" : "1501", + "r" : "1511", "s" : [ { "value" : [ "minimum", " " ] }, { - "r" : "1500", + "r" : "1510", "s" : [ { "value" : [ "Time" ] } ] @@ -20980,7 +22195,7 @@ module.exports['OutOfBounds'] = { }, { "value" : [ " + " ] }, { - "r" : "1502", + "r" : "1512", "s" : [ { "value" : [ "1 ", "millisecond" ] } ] @@ -20994,40 +22209,40 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Predecessor", - "localId" : "1505", + "localId" : "1515", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1506", + "localId" : "1516", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] } ], "operand" : { "type" : "Add", - "localId" : "1499", + "localId" : "1509", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1503", + "localId" : "1513", "name" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "NamedTypeSpecifier", - "localId" : "1504", + "localId" : "1514", "name" : "{urn:hl7-org:elm-types:r1}Quantity", "annotation" : [ ] } ], "operand" : [ { "type" : "MinValue", - "localId" : "1501", + "localId" : "1511", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Time", "valueType" : "{urn:hl7-org:elm-types:r1}Time", "annotation" : [ ] }, { "type" : "Quantity", - "localId" : "1502", + "localId" : "1512", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Quantity", "value" : 1, "unit" : "millisecond", @@ -21036,7 +22251,7 @@ module.exports['OutOfBounds'] = { } } }, { - "localId" : "1509", + "localId" : "1519", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "name" : "ExpOverflow", "context" : "Patient", @@ -21045,19 +22260,19 @@ module.exports['OutOfBounds'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "1509", + "r" : "1519", "s" : [ { "value" : [ "", "define ", "ExpOverflow", ": " ] }, { - "r" : "1515", + "r" : "1525", "s" : [ { "value" : [ "Exp", "(" ] }, { - "r" : "1511", + "r" : "1521", "s" : [ { "value" : [ "maximum", " " ] }, { - "r" : "1510", + "r" : "1520", "s" : [ { "value" : [ "Decimal" ] } ] @@ -21070,18 +22285,18 @@ module.exports['OutOfBounds'] = { } ], "expression" : { "type" : "Exp", - "localId" : "1515", + "localId" : "1525", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "1516", + "localId" : "1526", "name" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] } ], "operand" : { "type" : "MaxValue", - "localId" : "1511", + "localId" : "1521", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Decimal", "valueType" : "{urn:hl7-org:elm-types:r1}Decimal", "annotation" : [ ] diff --git a/test/elm/convert/convert-test.ts b/test/elm/convert/convert-test.ts index 3913025f6..84235ddba 100644 --- a/test/elm/convert/convert-test.ts +++ b/test/elm/convert/convert-test.ts @@ -39,8 +39,8 @@ describe('FromString', () => { (await this.integerValid.exec(this.ctx)).should.equal(10); }); - it("should convert '10.2' to Integer 10", async function () { - (await this.integerDropDecimal.exec(this.ctx)).should.equal(10); + it("should be null trying to convert '10.2' to Integer", async function () { + should(await this.integerWithDecimal.exec(this.ctx)).be.null(); }); it("should be null trying to convert 'abc' to Integer", async function () { @@ -48,11 +48,11 @@ describe('FromString', () => { }); it("should convert '10' to Long", async function () { - (await this.longValid.exec(this.ctx)).should.equal(10); + (await this.longValid.exec(this.ctx)).should.equal(10n); }); - it("should convert '10.2' to Long 10", async function () { - (await this.longDropDecimal.exec(this.ctx)).should.equal(10); + it("should be null trying to convert '10.2' to Long", async function () { + should(await this.longWithDecimal.exec(this.ctx)).be.null(); }); it("should be null trying to convert 'abc' to Long", async function () { @@ -124,7 +124,7 @@ describe('FromInteger', () => { }); it('should convert 10 to 10L', async function () { - (await this.long10.exec(this.ctx)).should.equal(10); + (await this.long10.exec(this.ctx)).should.equal(10n); }); it('should convert 10 to 10.0', async function () { @@ -162,7 +162,7 @@ describe('FromLong', () => { }); it('should convert 10L to 10L', async function () { - (await this.longLong.exec(this.ctx)).should.equal(10); + (await this.longLong.exec(this.ctx)).should.equal(10n); }); }); @@ -429,45 +429,35 @@ describe('ToLong', () => { }); it('should return positive long without polarity sign', async function () { - (await this.noSign.exec(this.ctx)).should.equal(12345); + (await this.noSign.exec(this.ctx)).should.equal(12345n); }); it('should return positive long with polarity sign', async function () { - (await this.positiveSign.exec(this.ctx)).should.equal(12345); + (await this.positiveSign.exec(this.ctx)).should.equal(12345n); }); it('should return negative long', async function () { - (await this.negativeSign.exec(this.ctx)).should.equal(-12345); - }); - - it('should return null if long larger than max by a significant amount', async function () { - should(await this.definitelyTooLargeLong.exec(this.ctx)).be.null(); + (await this.negativeSign.exec(this.ctx)).should.equal(-12345n); }); - // skipping because js number is imprecise at long max - it.skip('should return null if long larger than max', async function () { + it('should return null if long larger than max', async function () { should(await this.tooLargeLong.exec(this.ctx)).be.null(); }); - it('should return null if long smaller than min by a significant amount', async function () { - should(await this.definitelyTooSmallLong.exec(this.ctx)).be.null(); - }); - - // skipping because js number is imprecise at long max - it.skip('should return null if long smaller than min', async function () { + it('should return null if long smaller than min', async function () { should(await this.tooSmallLong.exec(this.ctx)).be.null(); }); it('should return 12345 for integer 12345', async function () { - (await this.int.exec(this.ctx)).should.equal(12345); + (await this.int.exec(this.ctx)).should.equal(12345n); }); it('should return 1 for boolean true', async function () { - (await this.booleanTrue.exec(this.ctx)).should.equal(1); + (await this.booleanTrue.exec(this.ctx)).should.equal(1n); }); it('should return 0 for boolean false', async function () { - (await this.booleanFalse.exec(this.ctx)).should.equal(0); + (await this.booleanFalse.exec(this.ctx)).should.equal(0n); }); }); diff --git a/test/elm/convert/data.cql b/test/elm/convert/data.cql index 9a377d306..46ead6eef 100644 --- a/test/elm/convert/data.cql +++ b/test/elm/convert/data.cql @@ -6,10 +6,10 @@ define boolFalse: convert 'false' to Boolean define decimalValid: convert '10.2' to Decimal define decimalInvalid: convert 'abc' to Decimal define integerValid: convert '10' to Integer -define integerDropDecimal: convert '10.2' to Integer +define integerWithDecimal: convert '10.2' to Integer define integerInvalid: convert 'abc' to Integer define longValid: convert '10' to Long -define longDropDecimal: convert '10.2' to Long +define longWithDecimal: convert '10.2' to Long define longInvalid: convert 'abc' to Long define quantityStr: convert '10 \'A\'' to Quantity define posQuantityStr: convert '+10 \'A\'' to Quantity @@ -88,8 +88,8 @@ define PositiveSign: ToInteger('+12345') define NegativeSign: ToInteger('-12345') define TooLargeInt: ToInteger('2147483648') define TooSmallInt: ToInteger('-2147483649') -define LongTwenty: ToInteger(20L); -define TooLargeLong: ToInteger(2147483648L); +define LongTwenty: ToInteger(20L) +define TooLargeLong: ToInteger(2147483648L) define TooSmallLong: ToInteger(-2147483649L) define BooleanTrue: ToInteger(true) define BooleanFalse: ToInteger(false) @@ -99,9 +99,7 @@ define NoSign: ToLong('12345') define PositiveSign: ToLong('+12345') define NegativeSign: ToLong('-12345') define TooLargeLong: ToLong('9223372036854775808') -define DefinitelyTooLargeLong: ToLong('9223372036854780000') define TooSmallLong: ToLong('-9223372036854775809') -define DefinitelyTooSmallLong: ToLong('-92233720368547800000') define Int: ToLong(12345) define BooleanTrue: ToLong(true) define BooleanFalse: ToLong(false) diff --git a/test/elm/convert/data.js b/test/elm/convert/data.js index 6112735ca..53f79c132 100644 --- a/test/elm/convert/data.js +++ b/test/elm/convert/data.js @@ -19,10 +19,10 @@ define boolFalse: convert 'false' to Boolean define decimalValid: convert '10.2' to Decimal define decimalInvalid: convert 'abc' to Decimal define integerValid: convert '10' to Integer -define integerDropDecimal: convert '10.2' to Integer +define integerWithDecimal: convert '10.2' to Integer define integerInvalid: convert 'abc' to Integer define longValid: convert '10' to Long -define longDropDecimal: convert '10.2' to Long +define longWithDecimal: convert '10.2' to Long define longInvalid: convert 'abc' to Long define quantityStr: convert '10 \'A\'' to Quantity define posQuantityStr: convert '+10 \'A\'' to Quantity @@ -470,7 +470,7 @@ module.exports['FromString'] = { }, { "localId" : "271", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", - "name" : "integerDropDecimal", + "name" : "integerWithDecimal", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -479,7 +479,7 @@ module.exports['FromString'] = { "s" : { "r" : "271", "s" : [ { - "value" : [ "", "define ", "integerDropDecimal", ": " ] + "value" : [ "", "define ", "integerWithDecimal", ": " ] }, { "r" : "276", "s" : [ { @@ -629,7 +629,7 @@ module.exports['FromString'] = { }, { "localId" : "298", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "name" : "longDropDecimal", + "name" : "longWithDecimal", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -638,7 +638,7 @@ module.exports['FromString'] = { "s" : { "r" : "298", "s" : [ { - "value" : [ "", "define ", "longDropDecimal", ": " ] + "value" : [ "", "define ", "longWithDecimal", ": " ] }, { "r" : "303", "s" : [ { @@ -4364,18 +4364,13 @@ define PositiveSign: ToInteger('+12345') define NegativeSign: ToInteger('-12345') define TooLargeInt: ToInteger('2147483648') define TooSmallInt: ToInteger('-2147483649') -define LongTwenty: ToInteger(20L); -define TooLargeLong: ToInteger(2147483648L); +define LongTwenty: ToInteger(20L) +define TooLargeLong: ToInteger(2147483648L) define TooSmallLong: ToInteger(-2147483649L) define BooleanTrue: ToInteger(true) define BooleanFalse: ToInteger(false) */ -/* -Translation Error(s): -[9:33, 9:33] Syntax error -[10:43, 10:43] Syntax error -*/ module.exports['ToInteger'] = { "library" : { "localId" : "0", @@ -4384,28 +4379,6 @@ module.exports['ToInteger'] = { "translatorVersion" : "4.2.0", "translatorOptions" : "EnableDateRangeOptimization,EnableAnnotations,EnableResultTypes", "signatureLevel" : "All" - }, { - "type" : "CqlToElmError", - "librarySystem" : "text/cql", - "libraryId" : "Anonymous", - "startLine" : 9, - "startChar" : 33, - "endLine" : 9, - "endChar" : 33, - "message" : "Syntax error", - "errorType" : "syntax", - "errorSeverity" : "error" - }, { - "type" : "CqlToElmError", - "librarySystem" : "text/cql", - "libraryId" : "Anonymous", - "startLine" : 10, - "startChar" : 43, - "endLine" : 10, - "endChar" : 43, - "message" : "Syntax error", - "errorType" : "syntax", - "errorSeverity" : "error" }, { "type" : "Annotation", "t" : [ ], @@ -4964,9 +4937,7 @@ define NoSign: ToLong('12345') define PositiveSign: ToLong('+12345') define NegativeSign: ToLong('-12345') define TooLargeLong: ToLong('9223372036854775808') -define DefinitelyTooLargeLong: ToLong('9223372036854780000') define TooSmallLong: ToLong('-9223372036854775809') -define DefinitelyTooSmallLong: ToLong('-92233720368547800000') define Int: ToLong(12345) define BooleanTrue: ToLong(true) define BooleanFalse: ToLong(false) @@ -4984,7 +4955,7 @@ module.exports['ToLong'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "302", + "r" : "282", "s" : [ { "value" : [ "", "library TestSnippet version '1'" ] } ] @@ -5251,7 +5222,7 @@ module.exports['ToLong'] = { }, { "localId" : "254", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "name" : "DefinitelyTooLargeLong", + "name" : "TooSmallLong", "context" : "Patient", "accessLevel" : "Public", "annotation" : [ { @@ -5260,7 +5231,7 @@ module.exports['ToLong'] = { "s" : { "r" : "254", "s" : [ { - "value" : [ "", "define ", "DefinitelyTooLargeLong", ": " ] + "value" : [ "", "define ", "TooSmallLong", ": " ] }, { "r" : "260", "s" : [ { @@ -5268,7 +5239,7 @@ module.exports['ToLong'] = { }, { "r" : "255", "s" : [ { - "value" : [ "'9223372036854780000'" ] + "value" : [ "'-9223372036854775809'" ] } ] }, { "value" : [ ")" ] @@ -5292,108 +5263,12 @@ module.exports['ToLong'] = { "localId" : "255", "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "9223372036854780000", - "annotation" : [ ] - } - } - }, { - "localId" : "264", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "name" : "TooSmallLong", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "264", - "s" : [ { - "value" : [ "", "define ", "TooSmallLong", ": " ] - }, { - "r" : "270", - "s" : [ { - "value" : [ "ToLong", "(" ] - }, { - "r" : "265", - "s" : [ { - "value" : [ "'-9223372036854775809'" ] - } ] - }, { - "value" : [ ")" ] - } ] - } ] - } - } ], - "expression" : { - "type" : "ToLong", - "localId" : "270", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "271", - "name" : "{urn:hl7-org:elm-types:r1}String", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "265", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", "value" : "-9223372036854775809", "annotation" : [ ] } } }, { - "localId" : "274", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "name" : "DefinitelyTooSmallLong", - "context" : "Patient", - "accessLevel" : "Public", - "annotation" : [ { - "type" : "Annotation", - "t" : [ ], - "s" : { - "r" : "274", - "s" : [ { - "value" : [ "", "define ", "DefinitelyTooSmallLong", ": " ] - }, { - "r" : "280", - "s" : [ { - "value" : [ "ToLong", "(" ] - }, { - "r" : "275", - "s" : [ { - "value" : [ "'-92233720368547800000'" ] - } ] - }, { - "value" : [ ")" ] - } ] - } ] - } - } ], - "expression" : { - "type" : "ToLong", - "localId" : "280", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", - "annotation" : [ ], - "signature" : [ { - "type" : "NamedTypeSpecifier", - "localId" : "281", - "name" : "{urn:hl7-org:elm-types:r1}String", - "annotation" : [ ] - } ], - "operand" : { - "type" : "Literal", - "localId" : "275", - "resultTypeName" : "{urn:hl7-org:elm-types:r1}String", - "valueType" : "{urn:hl7-org:elm-types:r1}String", - "value" : "-92233720368547800000", - "annotation" : [ ] - } - } - }, { - "localId" : "284", + "localId" : "264", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "Int", "context" : "Patient", @@ -5402,13 +5277,13 @@ module.exports['ToLong'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "284", + "r" : "264", "s" : [ { "value" : [ "", "define ", "Int", ": " ] }, { - "r" : "289", + "r" : "269", "s" : [ { - "r" : "285", + "r" : "265", "value" : [ "ToLong", "(", "12345", ")" ] } ] } ] @@ -5416,18 +5291,18 @@ module.exports['ToLong'] = { } ], "expression" : { "type" : "ToLong", - "localId" : "289", + "localId" : "269", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "290", + "localId" : "270", "name" : "{urn:hl7-org:elm-types:r1}Integer", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "285", + "localId" : "265", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Integer", "valueType" : "{urn:hl7-org:elm-types:r1}Integer", "value" : "12345", @@ -5435,7 +5310,7 @@ module.exports['ToLong'] = { } } }, { - "localId" : "293", + "localId" : "273", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "BooleanTrue", "context" : "Patient", @@ -5444,13 +5319,13 @@ module.exports['ToLong'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "293", + "r" : "273", "s" : [ { "value" : [ "", "define ", "BooleanTrue", ": " ] }, { - "r" : "298", + "r" : "278", "s" : [ { - "r" : "294", + "r" : "274", "value" : [ "ToLong", "(", "true", ")" ] } ] } ] @@ -5458,18 +5333,18 @@ module.exports['ToLong'] = { } ], "expression" : { "type" : "ToLong", - "localId" : "298", + "localId" : "278", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "299", + "localId" : "279", "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "294", + "localId" : "274", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", "value" : "true", @@ -5477,7 +5352,7 @@ module.exports['ToLong'] = { } } }, { - "localId" : "302", + "localId" : "282", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "name" : "BooleanFalse", "context" : "Patient", @@ -5486,13 +5361,13 @@ module.exports['ToLong'] = { "type" : "Annotation", "t" : [ ], "s" : { - "r" : "302", + "r" : "282", "s" : [ { "value" : [ "", "define ", "BooleanFalse", ": " ] }, { - "r" : "307", + "r" : "287", "s" : [ { - "r" : "303", + "r" : "283", "value" : [ "ToLong", "(", "false", ")" ] } ] } ] @@ -5500,18 +5375,18 @@ module.exports['ToLong'] = { } ], "expression" : { "type" : "ToLong", - "localId" : "307", + "localId" : "287", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Long", "annotation" : [ ], "signature" : [ { "type" : "NamedTypeSpecifier", - "localId" : "308", + "localId" : "288", "name" : "{urn:hl7-org:elm-types:r1}Boolean", "annotation" : [ ] } ], "operand" : { "type" : "Literal", - "localId" : "303", + "localId" : "283", "resultTypeName" : "{urn:hl7-org:elm-types:r1}Boolean", "valueType" : "{urn:hl7-org:elm-types:r1}Boolean", "value" : "false", diff --git a/test/elm/literal/literal-test.ts b/test/elm/literal/literal-test.ts index ccd87ab42..d30d7cc70 100644 --- a/test/elm/literal/literal-test.ts +++ b/test/elm/literal/literal-test.ts @@ -32,11 +32,11 @@ describe('Literal', () => { }); it('should convert 1L to 1', function () { - this.longOne.value.should.equal(1); + this.longOne.value.should.equal(1n); }); it('should execute 1L as 1', async function () { - (await this.longOne.exec(this.ctx)).should.equal(1); + (await this.longOne.exec(this.ctx)).should.equal(1n); }); it('should convert .1 to decimal .1', function () { diff --git a/tsconfig.json b/tsconfig.json index 30ddc73f2..9a4d79340 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,8 +1,8 @@ { "include": ["src"], "compilerOptions": { - "target": "ES2017", - "lib": ["es2015.core", "ESNext"], + "target": "ES2020", + "lib": ["ESNext"], "outDir": "./lib", "rootDir": "./src", "strict": true,