import * as plugins from './classes.plugins.js'; import { InterestMap, type IInterestComparisonFunc } from './classes.interestmap.js'; export interface IInterestOptions { markLostAfterDefault: number; defaultFullfillment?: DTInterestFullfillment; } export declare class Interest { options: IInterestOptions; private interestMapRef; originalInterest: DTInterestId; comparisonFunc: IInterestComparisonFunc; destructionTimer: plugins.smarttime.Timer; isFullfilled: boolean; private isDestroyed; /** * a generic store to store objects in that are needed for fullfillment; */ fullfillmentStore: any[]; /** * a cancellable timeout for the markLostAfterDefault feature */ private markLostTimeout; /** * quick access to a string that makes the interest comparable for checking for similar interests */ get comparisonString(): string; private interestDeferred; interestFullfilled: Promise; /** * fullfill the interest */ fullfillInterest(objectArg: DTInterestFullfillment): void; constructor(interestMapArg: InterestMap, interestArg: DTInterestId, comparisonFuncArg: IInterestComparisonFunc, optionsArg?: IInterestOptions); /** * self destructs the interest */ destroy(): void; /** * notifies the interest that the interest in it has been lost */ markLost(): void; /** * notifies the interest that the interest in it has been restored */ renew(): void; }