/// import BitObject from './object'; import BitRawObject from './raw-object'; import Ref from './ref'; import ComponentsIndex from './components-index'; import { ScopeJson } from '../scope-json'; import { ContentTransformer } from './repository-hooks'; export default class Repository { objects: { [key: string]: BitObject; }; objectsToRemove: Ref[]; scopeJson: ScopeJson; onRead: ContentTransformer; onPersist: ContentTransformer; scopePath: string; types: { [key: string]: Function; }; componentsIndex: ComponentsIndex; _cache: { [key: string]: BitObject; }; constructor(scopePath: string, scopeJson: ScopeJson, types?: { [key: string]: Function; }); static load({ scopePath, scopeJson }: { scopePath: string; scopeJson: ScopeJson; }): Promise; static create({ scopePath, scopeJson }: { scopePath: string; scopeJson: ScopeJson; }): Repository; static reset(scopePath: string): Promise; static getPathByScopePath(scopePath: string): string; ensureDir(): Promise; getPath(): string; getBackupPath(dirName?: string): string; getLicense(): Promise; getScopeMetaObject(): Promise; objectPath(ref: Ref): string; load(ref: Ref, throws?: boolean): Promise; list(): Promise; listRefs(): Promise>; listRawObjects(): Promise; listComponentsIncludeSymlinks(): Promise; listComponents(): Promise; _getBitObjectsByHashes(hashes: string[]): Promise; loadOptionallyCreateComponentsIndex(): Promise; loadRaw(ref: Ref): Promise; loadRawObject(ref: Ref): Promise; loadSync(ref: Ref, throws?: boolean): BitObject; setCache(object: BitObject): this; getCache(ref: Ref): BitObject; removeFromCache(ref: Ref): void; backup(dirName?: string): void; add(object: BitObject | null | undefined): Repository; addMany(objects: BitObject[]): Repository; removeObject(ref: Ref): void; removeManyObjects(refs: Ref[]): void; findMany(refs: Ref[]): Promise; persist(validate?: boolean): Promise; _validateObjects(validate: boolean): void; _deleteMany(): Promise; _writeMany(): Promise; _deleteOne(ref: Ref): Promise; _writeOne(object: BitObject): Promise; }