unitsnet-js
Version:
A better way to hold unit variables and easily convert to the destination unit
147 lines (146 loc) • 7.28 kB
TypeScript
import { BaseUnit, ToStringOptions } from "../base-unit";
/** API DTO represents a VolumeFlowPerArea */
export interface VolumeFlowPerAreaDto {
/** The value of the VolumeFlowPerArea */
value: number;
/** The specific unit that the VolumeFlowPerArea value is representing */
unit: VolumeFlowPerAreaUnits;
}
/** VolumeFlowPerAreaUnits enumeration */
export declare enum VolumeFlowPerAreaUnits {
/** */
CubicMetersPerSecondPerSquareMeter = "CubicMeterPerSecondPerSquareMeter",
/** */
CubicFeetPerMinutePerSquareFoot = "CubicFootPerMinutePerSquareFoot"
}
/** The volumetric flow rate per area is the volume of fluid which passes through a given unit surface area per unit time. */
export declare class VolumeFlowPerArea extends BaseUnit {
protected value: number;
private cubicmeterspersecondpersquaremeterLazy;
private cubicfeetperminutepersquarefootLazy;
/**
* Create a new VolumeFlowPerArea.
* @param value The value.
* @param fromUnit The ‘VolumeFlowPerArea’ unit to create from.
* The default unit is CubicMetersPerSecondPerSquareMeter
*/
constructor(value: number, fromUnit?: VolumeFlowPerAreaUnits);
/**
* The base value of VolumeFlowPerArea is CubicMetersPerSecondPerSquareMeter.
* 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(): VolumeFlowPerAreaUnits.CubicMetersPerSecondPerSquareMeter;
/** */
get CubicMetersPerSecondPerSquareMeter(): number;
/** */
get CubicFeetPerMinutePerSquareFoot(): number;
/**
* Create a new VolumeFlowPerArea instance from a CubicMetersPerSecondPerSquareMeter
*
* @param value The unit as CubicMetersPerSecondPerSquareMeter to create a new VolumeFlowPerArea from.
* @returns The new VolumeFlowPerArea instance.
*/
static FromCubicMetersPerSecondPerSquareMeter(value: number): VolumeFlowPerArea;
/**
* Create a new VolumeFlowPerArea instance from a CubicFeetPerMinutePerSquareFoot
*
* @param value The unit as CubicFeetPerMinutePerSquareFoot to create a new VolumeFlowPerArea from.
* @returns The new VolumeFlowPerArea instance.
*/
static FromCubicFeetPerMinutePerSquareFoot(value: number): VolumeFlowPerArea;
/**
* Gets the base unit enumeration associated with VolumeFlowPerArea
* @returns The unit enumeration that can be used to interact with this type
*/
protected static getUnitEnum(): typeof VolumeFlowPerAreaUnits;
/**
* 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(): VolumeFlowPerAreaUnits.CubicMetersPerSecondPerSquareMeter;
/**
* Create API DTO represent a VolumeFlowPerArea unit.
* @param holdInUnit The specific VolumeFlowPerArea unit to be used in the unit representation at the DTO
*/
toDto(holdInUnit?: VolumeFlowPerAreaUnits): VolumeFlowPerAreaDto;
/**
* Create a VolumeFlowPerArea unit from an API DTO representation.
* @param dtoVolumeFlowPerArea The VolumeFlowPerArea API DTO representation
*/
static FromDto(dtoVolumeFlowPerArea: VolumeFlowPerAreaDto): VolumeFlowPerArea;
/**
* Convert VolumeFlowPerArea to a specific unit value.
* @param toUnit The specific unit to convert to
* @returns The value of the specific unit provided.
*/
convert(toUnit: VolumeFlowPerAreaUnits): number;
private convertFromBase;
private convertToBase;
/**
* Format the VolumeFlowPerArea to string.
* Note! the default format for VolumeFlowPerArea is CubicMetersPerSecondPerSquareMeter.
* To specify the unit format set the 'unit' parameter.
* @param unit The unit to format the VolumeFlowPerArea.
* @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 VolumeFlowPerArea.
*/
toString(unit?: VolumeFlowPerAreaUnits, options?: number | ToStringOptions): string;
/**
* Get VolumeFlowPerArea unit abbreviation.
* Note! the default abbreviation for VolumeFlowPerArea is CubicMetersPerSecondPerSquareMeter.
* To specify the unit abbreviation set the 'unitAbbreviation' parameter.
* @param unitAbbreviation The unit abbreviation of the VolumeFlowPerArea.
* @returns The abbreviation string of VolumeFlowPerArea.
*/
getUnitAbbreviation(unitAbbreviation?: VolumeFlowPerAreaUnits): string;
/**
* Check if the given VolumeFlowPerArea are equals to the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns True if the given VolumeFlowPerArea are equal to the current VolumeFlowPerArea.
*/
equals(volumeFlowPerArea: VolumeFlowPerArea): boolean;
/**
* Compare the given VolumeFlowPerArea against the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns 0 if they are equal, -1 if the current VolumeFlowPerArea is less then other, 1 if the current VolumeFlowPerArea is greater then other.
*/
compareTo(volumeFlowPerArea: VolumeFlowPerArea): number;
/**
* Add the given VolumeFlowPerArea with the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns A new VolumeFlowPerArea instance with the results.
*/
add(volumeFlowPerArea: VolumeFlowPerArea): VolumeFlowPerArea;
/**
* Subtract the given VolumeFlowPerArea with the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns A new VolumeFlowPerArea instance with the results.
*/
subtract(volumeFlowPerArea: VolumeFlowPerArea): VolumeFlowPerArea;
/**
* Multiply the given VolumeFlowPerArea with the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns A new VolumeFlowPerArea instance with the results.
*/
multiply(volumeFlowPerArea: VolumeFlowPerArea): VolumeFlowPerArea;
/**
* Divide the given VolumeFlowPerArea with the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns A new VolumeFlowPerArea instance with the results.
*/
divide(volumeFlowPerArea: VolumeFlowPerArea): VolumeFlowPerArea;
/**
* Modulo the given VolumeFlowPerArea with the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns A new VolumeFlowPerArea instance with the results.
*/
modulo(volumeFlowPerArea: VolumeFlowPerArea): VolumeFlowPerArea;
/**
* Pow the given VolumeFlowPerArea with the current VolumeFlowPerArea.
* @param volumeFlowPerArea The other VolumeFlowPerArea.
* @returns A new VolumeFlowPerArea instance with the results.
*/
pow(volumeFlowPerArea: VolumeFlowPerArea): VolumeFlowPerArea;
}