ifc-expressions
Version:
Parsing and evaluation of IFC expressions
54 lines (53 loc) • 1.79 kB
TypeScript
import { Value } from "./Value.js";
import { Comparable } from "./Comparable.js";
import { ExprType } from "../type/ExprType.js";
import Decimal from "decimal.js";
export declare class IfcDurationValue implements Value<IfcDurationValue>, Comparable<IfcDurationValue> {
private readonly stringRepresentation;
private static readonly MINUTE;
private static readonly HOUR;
private static readonly DAY;
private static readonly WEEK;
private static readonly YEAR;
private static readonly MONTH;
private readonly years;
private readonly months;
private readonly weeks;
private readonly days;
private readonly hours;
private readonly minutes;
private readonly seconds;
private readonly fractionAsSeconds;
private readonly totalSeconds;
private static readonly regex;
constructor(value: string);
static parseIfcDuration(value: string): {
years: Decimal;
months: Decimal;
weeks: Decimal;
days: Decimal;
hours: Decimal;
minutes: Decimal;
seconds: Decimal;
fractionAsSeconds: Decimal;
totalSeconds: Decimal;
};
private static getFractionAsSeconds;
static of(value: string): IfcDurationValue;
getValue(): IfcDurationValue;
getType(): ExprType;
static isIfcDurationValueType(arg: any): arg is IfcDurationValue;
static isValidStringRepresentation(str: string): boolean;
equals(other: Value<any>): boolean;
toString(): string;
compareTo(other: IfcDurationValue): number;
getYears(): Decimal;
getMonths(): Decimal;
getWeeks(): Decimal;
getDays(): Decimal;
getHours(): Decimal;
getMinutes(): Decimal;
getSeconds(): Decimal;
getTotalSeconds(): Decimal;
getFractionAsSeconds(): Decimal;
}