unitsnet-js
Version:
A better way to hold unit variables and easily convert to the destination unit
147 lines (146 loc) • 7.21 kB
TypeScript
import { BaseUnit, ToStringOptions } from "../base-unit";
/** API DTO represents a ThermalConductivity */
export interface ThermalConductivityDto {
/** The value of the ThermalConductivity */
value: number;
/** The specific unit that the ThermalConductivity value is representing */
unit: ThermalConductivityUnits;
}
/** ThermalConductivityUnits enumeration */
export declare enum ThermalConductivityUnits {
/** */
WattsPerMeterKelvin = "WattPerMeterKelvin",
/** */
BtusPerHourFootFahrenheit = "BtuPerHourFootFahrenheit"
}
/** Thermal conductivity is the property of a material to conduct heat. */
export declare class ThermalConductivity extends BaseUnit {
protected value: number;
private wattspermeterkelvinLazy;
private btusperhourfootfahrenheitLazy;
/**
* Create a new ThermalConductivity.
* @param value The value.
* @param fromUnit The ‘ThermalConductivity’ unit to create from.
* The default unit is WattsPerMeterKelvin
*/
constructor(value: number, fromUnit?: ThermalConductivityUnits);
/**
* The base value of ThermalConductivity is WattsPerMeterKelvin.
* 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(): ThermalConductivityUnits.WattsPerMeterKelvin;
/** */
get WattsPerMeterKelvin(): number;
/** */
get BtusPerHourFootFahrenheit(): number;
/**
* Create a new ThermalConductivity instance from a WattsPerMeterKelvin
*
* @param value The unit as WattsPerMeterKelvin to create a new ThermalConductivity from.
* @returns The new ThermalConductivity instance.
*/
static FromWattsPerMeterKelvin(value: number): ThermalConductivity;
/**
* Create a new ThermalConductivity instance from a BtusPerHourFootFahrenheit
*
* @param value The unit as BtusPerHourFootFahrenheit to create a new ThermalConductivity from.
* @returns The new ThermalConductivity instance.
*/
static FromBtusPerHourFootFahrenheit(value: number): ThermalConductivity;
/**
* Gets the base unit enumeration associated with ThermalConductivity
* @returns The unit enumeration that can be used to interact with this type
*/
protected static getUnitEnum(): typeof ThermalConductivityUnits;
/**
* 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(): ThermalConductivityUnits.WattsPerMeterKelvin;
/**
* Create API DTO represent a ThermalConductivity unit.
* @param holdInUnit The specific ThermalConductivity unit to be used in the unit representation at the DTO
*/
toDto(holdInUnit?: ThermalConductivityUnits): ThermalConductivityDto;
/**
* Create a ThermalConductivity unit from an API DTO representation.
* @param dtoThermalConductivity The ThermalConductivity API DTO representation
*/
static FromDto(dtoThermalConductivity: ThermalConductivityDto): ThermalConductivity;
/**
* Convert ThermalConductivity to a specific unit value.
* @param toUnit The specific unit to convert to
* @returns The value of the specific unit provided.
*/
convert(toUnit: ThermalConductivityUnits): number;
private convertFromBase;
private convertToBase;
/**
* Format the ThermalConductivity to string.
* Note! the default format for ThermalConductivity is WattsPerMeterKelvin.
* To specify the unit format set the 'unit' parameter.
* @param unit The unit to format the ThermalConductivity.
* @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 ThermalConductivity.
*/
toString(unit?: ThermalConductivityUnits, options?: number | ToStringOptions): string;
/**
* Get ThermalConductivity unit abbreviation.
* Note! the default abbreviation for ThermalConductivity is WattsPerMeterKelvin.
* To specify the unit abbreviation set the 'unitAbbreviation' parameter.
* @param unitAbbreviation The unit abbreviation of the ThermalConductivity.
* @returns The abbreviation string of ThermalConductivity.
*/
getUnitAbbreviation(unitAbbreviation?: ThermalConductivityUnits): string;
/**
* Check if the given ThermalConductivity are equals to the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns True if the given ThermalConductivity are equal to the current ThermalConductivity.
*/
equals(thermalConductivity: ThermalConductivity): boolean;
/**
* Compare the given ThermalConductivity against the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns 0 if they are equal, -1 if the current ThermalConductivity is less then other, 1 if the current ThermalConductivity is greater then other.
*/
compareTo(thermalConductivity: ThermalConductivity): number;
/**
* Add the given ThermalConductivity with the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns A new ThermalConductivity instance with the results.
*/
add(thermalConductivity: ThermalConductivity): ThermalConductivity;
/**
* Subtract the given ThermalConductivity with the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns A new ThermalConductivity instance with the results.
*/
subtract(thermalConductivity: ThermalConductivity): ThermalConductivity;
/**
* Multiply the given ThermalConductivity with the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns A new ThermalConductivity instance with the results.
*/
multiply(thermalConductivity: ThermalConductivity): ThermalConductivity;
/**
* Divide the given ThermalConductivity with the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns A new ThermalConductivity instance with the results.
*/
divide(thermalConductivity: ThermalConductivity): ThermalConductivity;
/**
* Modulo the given ThermalConductivity with the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns A new ThermalConductivity instance with the results.
*/
modulo(thermalConductivity: ThermalConductivity): ThermalConductivity;
/**
* Pow the given ThermalConductivity with the current ThermalConductivity.
* @param thermalConductivity The other ThermalConductivity.
* @returns A new ThermalConductivity instance with the results.
*/
pow(thermalConductivity: ThermalConductivity): ThermalConductivity;
}