UNPKG

unitsnet-js

Version:

A better way to hold unit variables and easily convert to the destination unit

339 lines (338 loc) 15.2 kB
import { BaseUnit, ToStringOptions } from "../base-unit"; /** API DTO represents a PressureChangeRate */ export interface PressureChangeRateDto { /** The value of the PressureChangeRate */ value: number; /** The specific unit that the PressureChangeRate value is representing */ unit: PressureChangeRateUnits; } /** PressureChangeRateUnits enumeration */ export declare enum PressureChangeRateUnits { /** */ PascalsPerSecond = "PascalPerSecond", /** */ PascalsPerMinute = "PascalPerMinute", /** */ MillimetersOfMercuryPerSecond = "MillimeterOfMercuryPerSecond", /** */ AtmospheresPerSecond = "AtmospherePerSecond", /** */ PoundsForcePerSquareInchPerSecond = "PoundForcePerSquareInchPerSecond", /** */ PoundsForcePerSquareInchPerMinute = "PoundForcePerSquareInchPerMinute", /** */ BarsPerSecond = "BarPerSecond", /** */ BarsPerMinute = "BarPerMinute", /** */ KilopascalsPerSecond = "KilopascalPerSecond", /** */ MegapascalsPerSecond = "MegapascalPerSecond", /** */ KilopascalsPerMinute = "KilopascalPerMinute", /** */ MegapascalsPerMinute = "MegapascalPerMinute", /** */ KilopoundsForcePerSquareInchPerSecond = "KilopoundForcePerSquareInchPerSecond", /** */ MegapoundsForcePerSquareInchPerSecond = "MegapoundForcePerSquareInchPerSecond", /** */ KilopoundsForcePerSquareInchPerMinute = "KilopoundForcePerSquareInchPerMinute", /** */ MegapoundsForcePerSquareInchPerMinute = "MegapoundForcePerSquareInchPerMinute", /** */ MillibarsPerSecond = "MillibarPerSecond", /** */ MillibarsPerMinute = "MillibarPerMinute" } /** Pressure change rate is the ratio of the pressure change to the time during which the change occurred (value of pressure changes per unit time). */ export declare class PressureChangeRate extends BaseUnit { protected value: number; private pascalspersecondLazy; private pascalsperminuteLazy; private millimetersofmercurypersecondLazy; private atmospherespersecondLazy; private poundsforcepersquareinchpersecondLazy; private poundsforcepersquareinchperminuteLazy; private barspersecondLazy; private barsperminuteLazy; private kilopascalspersecondLazy; private megapascalspersecondLazy; private kilopascalsperminuteLazy; private megapascalsperminuteLazy; private kilopoundsforcepersquareinchpersecondLazy; private megapoundsforcepersquareinchpersecondLazy; private kilopoundsforcepersquareinchperminuteLazy; private megapoundsforcepersquareinchperminuteLazy; private millibarspersecondLazy; private millibarsperminuteLazy; /** * Create a new PressureChangeRate. * @param value The value. * @param fromUnit The ‘PressureChangeRate’ unit to create from. * The default unit is PascalsPerSecond */ constructor(value: number, fromUnit?: PressureChangeRateUnits); /** * The base value of PressureChangeRate is PascalsPerSecond. * This accessor used when needs a value for calculations and it's better to use directly the base value */ get BaseValue(): number; /** Gets the default unit used when creating instances of the unit or its DTO */ protected get baseUnit(): PressureChangeRateUnits.PascalsPerSecond; /** */ get PascalsPerSecond(): number; /** */ get PascalsPerMinute(): number; /** */ get MillimetersOfMercuryPerSecond(): number; /** */ get AtmospheresPerSecond(): number; /** */ get PoundsForcePerSquareInchPerSecond(): number; /** */ get PoundsForcePerSquareInchPerMinute(): number; /** */ get BarsPerSecond(): number; /** */ get BarsPerMinute(): number; /** */ get KilopascalsPerSecond(): number; /** */ get MegapascalsPerSecond(): number; /** */ get KilopascalsPerMinute(): number; /** */ get MegapascalsPerMinute(): number; /** */ get KilopoundsForcePerSquareInchPerSecond(): number; /** */ get MegapoundsForcePerSquareInchPerSecond(): number; /** */ get KilopoundsForcePerSquareInchPerMinute(): number; /** */ get MegapoundsForcePerSquareInchPerMinute(): number; /** */ get MillibarsPerSecond(): number; /** */ get MillibarsPerMinute(): number; /** * Create a new PressureChangeRate instance from a PascalsPerSecond * * @param value The unit as PascalsPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromPascalsPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a PascalsPerMinute * * @param value The unit as PascalsPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromPascalsPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MillimetersOfMercuryPerSecond * * @param value The unit as MillimetersOfMercuryPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMillimetersOfMercuryPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a AtmospheresPerSecond * * @param value The unit as AtmospheresPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromAtmospheresPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a PoundsForcePerSquareInchPerSecond * * @param value The unit as PoundsForcePerSquareInchPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromPoundsForcePerSquareInchPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a PoundsForcePerSquareInchPerMinute * * @param value The unit as PoundsForcePerSquareInchPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromPoundsForcePerSquareInchPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a BarsPerSecond * * @param value The unit as BarsPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromBarsPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a BarsPerMinute * * @param value The unit as BarsPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromBarsPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a KilopascalsPerSecond * * @param value The unit as KilopascalsPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromKilopascalsPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MegapascalsPerSecond * * @param value The unit as MegapascalsPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMegapascalsPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a KilopascalsPerMinute * * @param value The unit as KilopascalsPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromKilopascalsPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MegapascalsPerMinute * * @param value The unit as MegapascalsPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMegapascalsPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a KilopoundsForcePerSquareInchPerSecond * * @param value The unit as KilopoundsForcePerSquareInchPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromKilopoundsForcePerSquareInchPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MegapoundsForcePerSquareInchPerSecond * * @param value The unit as MegapoundsForcePerSquareInchPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMegapoundsForcePerSquareInchPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a KilopoundsForcePerSquareInchPerMinute * * @param value The unit as KilopoundsForcePerSquareInchPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromKilopoundsForcePerSquareInchPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MegapoundsForcePerSquareInchPerMinute * * @param value The unit as MegapoundsForcePerSquareInchPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMegapoundsForcePerSquareInchPerMinute(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MillibarsPerSecond * * @param value The unit as MillibarsPerSecond to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMillibarsPerSecond(value: number): PressureChangeRate; /** * Create a new PressureChangeRate instance from a MillibarsPerMinute * * @param value The unit as MillibarsPerMinute to create a new PressureChangeRate from. * @returns The new PressureChangeRate instance. */ static FromMillibarsPerMinute(value: number): PressureChangeRate; /** * Gets the base unit enumeration associated with PressureChangeRate * @returns The unit enumeration that can be used to interact with this type */ protected static getUnitEnum(): typeof PressureChangeRateUnits; /** * Gets the default unit used when creating instances of the unit or its DTO * @returns The unit enumeration value used as a default parameter in constructor and DTO methods */ protected static getBaseUnit(): PressureChangeRateUnits.PascalsPerSecond; /** * Create API DTO represent a PressureChangeRate unit. * @param holdInUnit The specific PressureChangeRate unit to be used in the unit representation at the DTO */ toDto(holdInUnit?: PressureChangeRateUnits): PressureChangeRateDto; /** * Create a PressureChangeRate unit from an API DTO representation. * @param dtoPressureChangeRate The PressureChangeRate API DTO representation */ static FromDto(dtoPressureChangeRate: PressureChangeRateDto): PressureChangeRate; /** * Convert PressureChangeRate to a specific unit value. * @param toUnit The specific unit to convert to * @returns The value of the specific unit provided. */ convert(toUnit: PressureChangeRateUnits): number; private convertFromBase; private convertToBase; /** * Format the PressureChangeRate to string. * Note! the default format for PressureChangeRate is PascalsPerSecond. * To specify the unit format set the 'unit' parameter. * @param unit The unit to format the PressureChangeRate. * @param options The ToString options, it also can be the number of fractional digits to keep that deprecated and moved to the options object. support in number will be dropped in the upcoming versions. * @returns The string format of the PressureChangeRate. */ toString(unit?: PressureChangeRateUnits, options?: number | ToStringOptions): string; /** * Get PressureChangeRate unit abbreviation. * Note! the default abbreviation for PressureChangeRate is PascalsPerSecond. * To specify the unit abbreviation set the 'unitAbbreviation' parameter. * @param unitAbbreviation The unit abbreviation of the PressureChangeRate. * @returns The abbreviation string of PressureChangeRate. */ getUnitAbbreviation(unitAbbreviation?: PressureChangeRateUnits): string; /** * Check if the given PressureChangeRate are equals to the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns True if the given PressureChangeRate are equal to the current PressureChangeRate. */ equals(pressureChangeRate: PressureChangeRate): boolean; /** * Compare the given PressureChangeRate against the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns 0 if they are equal, -1 if the current PressureChangeRate is less then other, 1 if the current PressureChangeRate is greater then other. */ compareTo(pressureChangeRate: PressureChangeRate): number; /** * Add the given PressureChangeRate with the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns A new PressureChangeRate instance with the results. */ add(pressureChangeRate: PressureChangeRate): PressureChangeRate; /** * Subtract the given PressureChangeRate with the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns A new PressureChangeRate instance with the results. */ subtract(pressureChangeRate: PressureChangeRate): PressureChangeRate; /** * Multiply the given PressureChangeRate with the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns A new PressureChangeRate instance with the results. */ multiply(pressureChangeRate: PressureChangeRate): PressureChangeRate; /** * Divide the given PressureChangeRate with the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns A new PressureChangeRate instance with the results. */ divide(pressureChangeRate: PressureChangeRate): PressureChangeRate; /** * Modulo the given PressureChangeRate with the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns A new PressureChangeRate instance with the results. */ modulo(pressureChangeRate: PressureChangeRate): PressureChangeRate; /** * Pow the given PressureChangeRate with the current PressureChangeRate. * @param pressureChangeRate The other PressureChangeRate. * @returns A new PressureChangeRate instance with the results. */ pow(pressureChangeRate: PressureChangeRate): PressureChangeRate; }