MCPcopy
hub / github.com/jvilk/BrowserFS / stat

Method stat

src/generic/key_value_filesystem.ts:869–876  ·  view source on GitHub ↗
(p: string, isLstat: boolean, cb: BFSCallback<Stats>)

Source from the content-addressed store, hash-verified

867 }
868
869 public stat(p: string, isLstat: boolean, cb: BFSCallback<Stats>): void {
870 const tx = this.store.beginTransaction('readonly');
871 this.findINode(tx, p, (e: ApiError, inode?: Inode): void => {
872 if (noError(e, cb)) {
873 cb(null, inode!.toStats());
874 }
875 });
876 }
877
878 public createFile(p: string, flag: FileFlag, mode: number, cb: BFSCallback<File>): void {
879 const tx = this.store.beginTransaction('readwrite'),

Callers

nothing calls this directly

Calls 5

findINodeMethod · 0.95
noErrorFunction · 0.85
cbFunction · 0.85
toStatsMethod · 0.80
beginTransactionMethod · 0.65

Tested by

no test coverage detected