import type { ServerResponse, IncomingHttpHeaders, IncomingMessage } from "http"; import type { ILambda } from "../../../defineConfig"; import { XMLBuilder } from "fast-xml-parser"; export interface BucketConfig { deletionPolicy: "Delete" | "Retain" | "RetainExceptOnCreate"; versioning?: "Enabled" | "Suspended"; tags?: Record; } declare const StorageClass: readonly ["STANDARD", "REDUCED_REDUNDANCY", "STANDARD_IA", "ONEZONE_IA", "INTELLIGENT_TIERING", "GLACIER", "DEEP_ARCHIVE", "OUTPOSTS", "GLACIER_IR", "SNOW"]; export type LocalS3Object = { currentKey: string; type?: string; cacheControl?: string; contentDisposition?: string; contentEncoding?: string; contentLanguage?: string; expires?: number; websiteRedirectLocation?: string; StorageClass: (typeof StorageClass)[number]; ETag: string; LastModified: number; size: number; metadata: Record; versions: Record; tags?: Record; }; interface LocalS3PersistenceV2 { version: number; buckets: { [name: string]: { date: number; objects: { [key: string]: LocalS3Object; }; } & BucketConfig; }; } export declare abstract class S3LocalService { #private; abstract exec(res: ServerResponse, ...rest: any): Promise | void; static localStoragePath: string; static persist: boolean; static persistence: LocalS3PersistenceV2; static XMLBuilder: XMLBuilder; static genLocalKey(bucket: string, key: string, version?: string): string; static bootstrap(): Promise; static createBucketDir(bucketName: string, config: BucketConfig): Promise; static saveState(): void; static isValidBucketName(bucket: string): boolean; isValidStorageClass(storage: any, res: ServerResponse): boolean; static callableLambdas: ILambda[]; requestId: string; metadata: Record; constructor(headers: IncomingHttpHeaders); hasNot(bucket: string, res: ServerResponse): true | undefined; static removeObject(bucket: string, key: string, sourceIPAddress: string, requestId: string): Promise; static getTagsFromRequest(req: IncomingMessage, RequestId: string, type: "Bucket" | "Object"): Promise | undefined>; } export {};