當前位置: 首頁>>代碼示例>>TypeScript>>正文


TypeScript webpack.InputFileSystem類代碼示例

本文整理匯總了TypeScript中webpack.InputFileSystem的典型用法代碼示例。如果您正苦於以下問題:TypeScript InputFileSystem類的具體用法?TypeScript InputFileSystem怎麽用?TypeScript InputFileSystem使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了InputFileSystem類的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。

示例1: readFile

 readFile(path: string, callback: (err: Error, contents: Buffer) => void): void {
   const result = this._readFileSync(path);
   if (result) {
     // tslint:disable-next-line:no-any
     callback(null as any, result);
   } else {
     this._inputFileSystem.readFile(path, callback);
   }
 }
開發者ID:baconwaffles,項目名稱:angular-cli,代碼行數:9,代碼來源:virtual_file_system_decorator.ts

示例2: stat

 stat(path: string, callback: (err: Error, stats: Stats) => void): void {
   const result = this._statSync(path);
   if (result) {
     // tslint:disable-next-line:no-any
     callback(null as any, result);
   } else {
     this._inputFileSystem.stat(path, callback);
   }
 }
開發者ID:baconwaffles,項目名稱:angular-cli,代碼行數:9,代碼來源:virtual_file_system_decorator.ts

示例3: Observable

 return new Observable(obs => {
   // TODO: remove this try+catch when issue https://github.com/ReactiveX/rxjs/issues/3740 is
   // fixed.
   try {
     const data = this.inputFileSystem.readFileSync(getSystemPath(path));
     obs.next(new Uint8Array(data).buffer as ArrayBuffer);
     obs.complete();
   } catch (e) {
     obs.error(e);
   }
 });
開發者ID:DevIntent,項目名稱:angular-cli,代碼行數:11,代碼來源:webpack-input-host.ts

示例4: readlinkSync

 readlinkSync(path: string): string {
   return this._inputFileSystem.readlinkSync(path);
 }
開發者ID:baconwaffles,項目名稱:angular-cli,代碼行數:3,代碼來源:virtual_file_system_decorator.ts

示例5: readFileSync

  readFileSync(path: string): Buffer {
    const result = this._readFileSync(path);

    return result || this._inputFileSystem.readFileSync(path);
  }
開發者ID:baconwaffles,項目名稱:angular-cli,代碼行數:5,代碼來源:virtual_file_system_decorator.ts

示例6: statSync

  statSync(path: string): Stats {
    const result = this._statSync(path);

    return result || this._inputFileSystem.statSync(path);
  }
開發者ID:baconwaffles,項目名稱:angular-cli,代碼行數:5,代碼來源:virtual_file_system_decorator.ts

示例7: readlink

 readlink(path: string, callback: (err: Error, linkString: string) => void): void {
   this._inputFileSystem.readlink(path, callback);
 }
開發者ID:baconwaffles,項目名稱:angular-cli,代碼行數:3,代碼來源:virtual_file_system_decorator.ts


注:本文中的webpack.InputFileSystem類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。