import type { DatafileContent, EnvironmentKey, ExistingState, HistoryEntry, Commit, CommitHash, EntityType } from "@featurevisor/types"; import type { Scope } from "../config"; export interface DatafileOptions { environment: EnvironmentKey | false; tag?: string; scope?: Scope; datafilesDir?: string; } export type FeatureEnvironmentProperty = "rules" | "force" | "expose"; export interface FeatureSourcePaths { baseFilePath: string; environmentFilePaths: Record; } export declare abstract class Adapter { abstract listEntities(entityType: EntityType): Promise; abstract entityExists(entityType: EntityType, entityKey: string): Promise; abstract readEntity(entityType: EntityType, entityKey: string): Promise; abstract writeEntity(entityType: EntityType, entityKey: string, entity: T): Promise; abstract deleteEntity(entityType: EntityType, entityKey: string): Promise; abstract readState(environment: EnvironmentKey | false): Promise; abstract writeState(environment: EnvironmentKey | false, existingState: ExistingState): Promise; abstract readDatafile(options: DatafileOptions): Promise; abstract writeDatafile(datafileContent: DatafileContent, options: DatafileOptions): Promise; abstract readRevision(): Promise; abstract writeRevision(revision: string): Promise; abstract listHistoryEntries(entityType?: EntityType, entityKey?: string): Promise; abstract readCommit(commit: CommitHash, entityType?: EntityType, entityKey?: string): Promise; getFeatureSourcePaths(_featureKey: string): Promise; getFeaturePropertySourcePath(_featureKey: string, _property: FeatureEnvironmentProperty, _environment?: string): Promise; }