Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface FileNonBlocking

Hierarchy

Index

Properties

Readonly cache

cache: Record<string, object>

Use to cache arbitrary content associated with this instance. Use for smallish objects that are expensive to compute.

dirty

dirty: boolean

Are there pending changes that need to be flushed?

Readonly name

name: string

Return file name, excluding path

property

{string} name

Readonly path

path: string

Return file path, with forward slashes

property

{string} path

Methods

flush

  • flush(): Promise<this>

getContent

  • getContent(encoding?: string): Promise<string>

getContentBuffer

  • getContentBuffer(): Promise<Buffer>

isBinary

  • isBinary(): Promise<boolean>

isExecutable

  • isExecutable(): Promise<boolean>

isReadable

  • isReadable(): Promise<boolean>

recordAction

rename

  • rename(name: string): Promise<this>

replace

  • replace(re: RegExp, replacement: string): Promise<this>

replaceAll

  • replaceAll(oldLiteral: string, newLiteral: string): Promise<this>

setContent

  • setContent(content: string): Promise<this>

setPath

  • setPath(path: string): Promise<this>

Generated using TypeDoc