@itwin/core-frontend
Version:
iTwin.js frontend components
22 lines • 1.34 kB
TypeScript
/** @packageDocumentation
* @module QuantityFormatting
*/
import { UnitSystemKey } from "@itwin/core-quantity";
import { OverrideFormatEntry, QuantityFormatter, QuantityTypeKey } from "./QuantityFormatter";
import { BaseUnitFormattingSettingsProvider } from "./BaseUnitFormattingSettingsProvider";
/** Implementation of BaseUnitFormattingSettingsProvider that stores and retrieves data in local storage.
* @beta
*/
export declare class LocalUnitFormatProvider extends BaseUnitFormattingSettingsProvider {
/** If `maintainOverridesPerIModel` is true, the base class will set up listeners to monitor active iModel
* changes so the overrides for the QuantityFormatter properly match the overrides set up by the user. */
constructor(quantityFormatter: QuantityFormatter, maintainOverridesPerIModel?: boolean);
private buildUnitSystemKey;
retrieveUnitSystem(defaultKey: UnitSystemKey): Promise<UnitSystemKey>;
storeUnitSystemKey(unitSystemKey: UnitSystemKey): Promise<boolean>;
private buildOverridesKey;
store(quantityTypeKey: QuantityTypeKey, overrideProps: OverrideFormatEntry): Promise<boolean>;
retrieve(quantityTypeKey: QuantityTypeKey): Promise<OverrideFormatEntry | undefined>;
remove(quantityTypeKey: QuantityTypeKey): Promise<boolean>;
}
//# sourceMappingURL=LocalUnitFormatProvider.d.ts.map