@flystorage/google-cloud-storage
Version:
<img src="https://raw.githubusercontent.com/duna-oss/flystorage/main/flystorage.svg" width="50px" height="50px" />
25 lines (24 loc) • 1.33 kB
TypeScript
import { File, PredefinedAcl } from '@google-cloud/storage';
export interface VisibilityHandlingForGoogleCloudStorage {
changeVisibility(file: File, visibility: string): Promise<void>;
determineVisibility(file: File): Promise<string>;
visibilityToPredefinedAcl(visibility: string): PredefinedAcl | undefined;
}
export declare class UniformBucketLevelAccessVisibilityHandling implements VisibilityHandlingForGoogleCloudStorage {
private readonly errorOnChange;
private readonly errorOnDetermine;
private readonly fakeVisibility;
constructor(errorOnChange?: boolean, errorOnDetermine?: boolean, fakeVisibility?: string);
changeVisibility(file: File, visibility: string): Promise<void>;
determineVisibility(file: File): Promise<string>;
visibilityToPredefinedAcl(visibility: string): PredefinedAcl | undefined;
}
export declare class LegacyVisibilityHandling implements VisibilityHandlingForGoogleCloudStorage {
private readonly entity;
private readonly publicAcl;
private readonly privateAcl;
constructor(entity?: string, publicAcl?: PredefinedAcl, privateAcl?: PredefinedAcl);
changeVisibility(file: File, visibility: string): Promise<void>;
determineVisibility(file: File): Promise<string>;
visibilityToPredefinedAcl(visibility: string): PredefinedAcl | undefined;
}