DefinitelyTyped/types/nodegit/tree-entry.d.ts
2017-06-09 02:11:59 +01:00

31 lines
623 B
TypeScript

import { Tree } from './tree';
import { Oid } from './oid';
import { Blob } from './blob';
export namespace TreeEntry {
const enum FILEMODE {
UNREADABLE = 0,
TREE = 16384,
BLOB = 33188,
EXECUTABLE = 33261,
LINK = 40960,
COMMIT = 57344
}
}
export class TreeEntry {
isFile(): boolean;
isTree(): boolean;
isDirectory(): boolean;
isBlob(): boolean;
sha(): string;
getTree(): Promise<Tree>;
getBlob(): Promise<Blob>;
path(): string;
toString(): string;
attr: number;
oid: Oid;
filenameLen: number;
filename: string;
}