///
export const PREFERRED_TRIM_SIZE: 500;
export function writeUint32BigEndian(encoder: encoding.Encoder, num: number): void;
export function readUint32BigEndian(decoder: decoding.Decoder): number;
export const keyEncoding: {
buffer: boolean;
type: string;
encode: (arr: Array) => Buffer;
decode: (buf: Uint8Array) => (string | number)[];
};
export function getLevelBulkData(db: any, opts: object): Promise>;
export function getLevelUpdates(db: any, docName: string, opts?: any): Promise>;
export function getAllDocs(db: any, values: boolean, keys: boolean): Promise>;
export function getCurrentUpdateClock(db: any, docName: string): Promise;
export class LeveldbPersistence {
/**
* @param {string} location
* @param {object} [opts]
* @param {any} [opts.level] Level-compatible adapter. E.g. leveldown, level-rem, level-indexeddb. Defaults to `level`
* @param {object} [opts.levelOptions] Options that are passed down to the level instance
*/
constructor(location: string, { level, levelOptions }?: {
level?: any;
levelOptions?: object;
} | undefined);
tr: Promise;
/**
* Execute an transaction on a database. This will ensure that other processes are currently not writing.
*
* This is a private method and might change in the future.
*
* @todo only transact on the same room-name. Allow for concurrency of different rooms.
*
* @template T
*
* @param {function(any):Promise} f A transaction that receives the db object
* @return {Promise}
*/
_transact: (f: (arg0: any) => Promise) => Promise;
/**
* @param {string} docName
*/
flushDocument(docName: string): Promise;
/**
* @param {string} docName
* @return {Promise}
*/
getYDoc(docName: string): Promise;
/**
* @param {string} docName
* @return {Promise}
*/
getStateVector(docName: string): Promise;
/**
* @param {string} docName
* @param {Uint8Array} update
* @return {Promise} Returns the clock of the stored update
*/
storeUpdate(docName: string, update: Uint8Array): Promise;
/**
* @param {string} docName
* @param {Uint8Array} stateVector
*/
getDiff(docName: string, stateVector: Uint8Array): Promise;
/**
* @param {string} docName
* @return {Promise}
*/
clearDocument(docName: string): Promise;
/**
* @param {string} docName
* @param {string} metaKey
* @param {any} value
* @return {Promise}
*/
setMeta(docName: string, metaKey: string, value: any): Promise;
/**
* @param {string} docName
* @param {string} metaKey
* @return {Promise}
*/
delMeta(docName: string, metaKey: string): Promise;
/**
* @param {string} docName
* @param {string} metaKey
* @return {Promise}
*/
getMeta(docName: string, metaKey: string): Promise;
/**
* @return {Promise>}
*/
getAllDocNames(): Promise>;
/**
* @return {Promise>}
*/
getAllDocStateVectors(): Promise>;
/**
* @param {string} docName
* @return {Promise