import '../../globals.js';
import Constructor from './types/Constructor.js';
import IntentionalAny from './types/IntentionalAny.js';
type PoolableOptions<Type extends Constructor> = {
    defaultArguments?: ConstructorParameters<Type>;
    initialize?: PoolableInitializer<Type>;
    maxSize?: number;
    initialSize?: number;
    useDefaultConstruction?: boolean;
};
type PoolableInstance = {
    freeToPool(): void;
};
type PoolableVersion<Type extends Constructor> = InstanceType<Type> & PoolableInstance;
type PoolableInitializer<Type extends Constructor> = (...args: ConstructorParameters<Type>) => IntentionalAny;
type PoolableClass<Type extends Constructor> = (new (...args: ConstructorParameters<Type>) => (PoolableVersion<Type>)) & PoolableType<Type>;
type PoolableExistingStatics<Type extends Constructor> = {
    [Property in keyof Type]: Type[Property];
};
type PoolableType<Type extends Constructor> = {
    pool: PoolableVersion<Type>[];
    dirtyFromPool(): PoolableVersion<Type>;
    createFromPool(...args: ConstructorParameters<Type>): PoolableVersion<Type>;
    get poolSize(): number;
    set maxPoolSize(value: number);
    get maxPoolSize(): number;
} & PoolableExistingStatics<Type>;
/**
 * @deprecated - Please use Pool.ts instead as the new pooling pattern.
 */
declare const Poolable: {
    /**
     * Changes the given type (and its prototype) to support object pooling.
     */
    mixInto<Type extends Constructor>(type: Type, providedOptions?: PoolableOptions<Type>): PoolableClass<Type>;
};
export default Poolable;
export type { PoolableOptions, PoolableInstance, PoolableVersion, PoolableInitializer, PoolableClass, PoolableType };
//# sourceMappingURL=Poolable.d.ts.map