@enonic/mock-xp
Version:
Mock Enonic XP API JavaScript Library
30 lines (29 loc) • 822 B
TypeScript
import type { Repository, RepositorySettings } from '@enonic-types/lib-repo';
import type { Log } from '../types';
import type { Server } from './Server';
import { Branch } from './Branch';
interface Branches {
[key: string]: Branch;
}
export interface Repos {
[key: string]: Repo;
}
export declare class Repo {
private _highest_id;
readonly branches: Branches;
readonly id: string;
readonly server: Server;
readonly settings: RepositorySettings;
readonly log: Log;
constructor({ id, server, settings }: {
id: string;
server: Server;
settings?: RepositorySettings;
});
createBranch(branchId: string): Branch;
deleteBranch(branchId: string): true;
generateId(): string;
get(): Repository;
getBranch(branchId: string): Branch;
}
export {};