import { CanBeState } from "../PubTypes"; import { KeyType, ValueType } from "../Types"; type MapInputValue = [In, OutKey] extends [Array, number] ? Array : In extends Map ? Map : In extends Set ? Set : OutKey extends string | number | symbol ? Record> : Map>; export declare interface ForKeys { type: "State"; kind: "ForKeys"; /** * Returns the current value of this ForKeys object. * The object will be registered as a dependency unless `asDependency` is false. */ get(asDependency?: boolean): T; } /** * Constructs a new ForKeys state object which maps keys of an array using * a `processor` function. * * Optionally, a `destructor` function can be specified for cleaning up * calculated keys. If omitted, the default cleanup function will be used instead. * * Optionally, a `meta` value can be returned in the processor function as the * second value to pass data from the processor to the destructor. */ export declare function ForKeys( input: CanBeState, processor: (key: KeyType) => Out | LuaTuple<[Out, Meta]>, destructor?: (key: Out, meta: Meta) => void, ): ForKeys>;