object promises

Source
promises.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. promises
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. val ^: Any
    Annotations
    @JSImport("fs", "promises") @native()
  5. def access(path: PathLike, mode: Double): Promise[Unit]
    Annotations
    @inline()
  6. def access(path: PathLike): Promise[Unit]

    Asynchronously tests a user's permissions for the file specified by path.

    Asynchronously tests a user's permissions for the file specified by path.

    path

    A path to a file or directory. If a URL is provided, it must use the file: protocol. URL support is _experimental_.

    Annotations
    @inline()
  7. def appendFile(path: FileHandle, data: Uint8Array, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  8. def appendFile(path: FileHandle, data: Uint8Array, options: BaseEncodingOptionsmodeMoEncoding): Promise[Unit]
    Annotations
    @inline()
  9. def appendFile(path: FileHandle, data: Uint8Array): Promise[Unit]
    Annotations
    @inline()
  10. def appendFile(path: FileHandle, data: scala.Predef.String, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  11. def appendFile(path: FileHandle, data: scala.Predef.String, options: BaseEncodingOptionsmodeMoEncoding): Promise[Unit]
    Annotations
    @inline()
  12. def appendFile(path: FileHandle, data: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  13. def appendFile(path: PathLike, data: Uint8Array, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  14. def appendFile(path: PathLike, data: Uint8Array, options: BaseEncodingOptionsmodeMoEncoding): Promise[Unit]
    Annotations
    @inline()
  15. def appendFile(path: PathLike, data: Uint8Array): Promise[Unit]
    Annotations
    @inline()
  16. def appendFile(path: PathLike, data: scala.Predef.String, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  17. def appendFile(path: PathLike, data: scala.Predef.String, options: BaseEncodingOptionsmodeMoEncoding): Promise[Unit]
    Annotations
    @inline()
  18. def appendFile(path: PathLike, data: scala.Predef.String): Promise[Unit]

    Asynchronously append data to a file, creating the file if it does not exist.

    Asynchronously append data to a file, creating the file if it does not exist.

    data

    The data to write. If something other than a Buffer or Uint8Array is provided, the value is coerced to a string.

    Annotations
    @inline()
  19. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  20. def chmod(path: PathLike, mode: Mode): Promise[Unit]

    Asynchronous chmod(2) - Change permissions of a file.

    Asynchronous chmod(2) - Change permissions of a file.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    mode

    A file mode. If a string is passed, it is parsed as an octal integer.

    Annotations
    @inline()
  21. def chown(path: PathLike, uid: Double, gid: Double): Promise[Unit]

    Asynchronous chown(2) - Change ownership of a file.

    Asynchronous chown(2) - Change ownership of a file.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  22. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
  23. def copyFile(src: PathLike, dest: PathLike, flags: Double): Promise[Unit]
    Annotations
    @inline()
  24. def copyFile(src: PathLike, dest: PathLike): Promise[Unit]

    Asynchronously copies src to dest.

    Asynchronously copies src to dest. By default, dest is overwritten if it already exists. Node.js makes no guarantees about the atomicity of the copy operation. If an error occurs after the destination file has been opened for writing, Node.js will attempt to remove the destination.

    src

    A path to the source file.

    dest

    A path to the destination file.

    Annotations
    @inline()
  25. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  26. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  27. def fchmod(handle: FileHandle, mode: Mode): Promise[Unit]

    Asynchronous fchmod(2) - Change permissions of a file.

    Asynchronous fchmod(2) - Change permissions of a file.

    handle

    A FileHandle.

    mode

    A file mode. If a string is passed, it is parsed as an octal integer.

    Annotations
    @inline()
  28. def fchown(handle: FileHandle, uid: Double, gid: Double): Promise[Unit]

    Asynchronous fchown(2) - Change ownership of a file.

    Asynchronous fchown(2) - Change ownership of a file.

    handle

    A FileHandle.

    Annotations
    @inline()
  29. def fdatasync(handle: FileHandle): Promise[Unit]

    Asynchronous fdatasync(2) - synchronize a file's in-core state with storage device.

    Asynchronous fdatasync(2) - synchronize a file's in-core state with storage device.

    handle

    A FileHandle.

    Annotations
    @inline()
  30. def fsync(handle: FileHandle): Promise[Unit]

    Asynchronous fsync(2) - synchronize a file's in-core state with the underlying storage device.

    Asynchronous fsync(2) - synchronize a file's in-core state with the underlying storage device.

    handle

    A FileHandle.

    Annotations
    @inline()
  31. def ftruncate(handle: FileHandle, len: Double): Promise[Unit]
    Annotations
    @inline()
  32. def ftruncate(handle: FileHandle): Promise[Unit]

    Asynchronous ftruncate(2) - Truncate a file to a specified length.

    Asynchronous ftruncate(2) - Truncate a file to a specified length.

    handle

    A FileHandle.

    Annotations
    @inline()
  33. def futimes(handle: FileHandle, atime: Double, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  34. def futimes(handle: FileHandle, atime: Double, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  35. def futimes(handle: FileHandle, atime: Double, mtime: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  36. def futimes(handle: FileHandle, atime: Date, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  37. def futimes(handle: FileHandle, atime: Date, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  38. def futimes(handle: FileHandle, atime: Date, mtime: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  39. def futimes(handle: FileHandle, atime: scala.Predef.String, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  40. def futimes(handle: FileHandle, atime: scala.Predef.String, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  41. def futimes(handle: FileHandle, atime: scala.Predef.String, mtime: scala.Predef.String): Promise[Unit]

    Asynchronously change file timestamps of the file referenced by the supplied FileHandle.

    Asynchronously change file timestamps of the file referenced by the supplied FileHandle.

    handle

    A FileHandle.

    atime

    The last access time. If a string is provided, it will be coerced to number.

    mtime

    The last modified time. If a string is provided, it will be coerced to number.

    Annotations
    @inline()
  42. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  43. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  44. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  45. def lchmod(path: PathLike, mode: Mode): Promise[Unit]

    Asynchronous lchmod(2) - Change permissions of a file.

    Asynchronous lchmod(2) - Change permissions of a file. Does not dereference symbolic links.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    mode

    A file mode. If a string is passed, it is parsed as an octal integer.

    Annotations
    @inline()
  46. def lchown(path: PathLike, uid: Double, gid: Double): Promise[Unit]

    Asynchronous lchown(2) - Change ownership of a file.

    Asynchronous lchown(2) - Change ownership of a file. Does not dereference symbolic links.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  47. def link(existingPath: PathLike, newPath: PathLike): Promise[Unit]

    Asynchronous link(2) - Create a new link (also known as a hard link) to an existing file.

    Asynchronous link(2) - Create a new link (also known as a hard link) to an existing file.

    existingPath

    A path to a file. If a URL is provided, it must use the file: protocol.

    newPath

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  48. def lstat(path: PathLike, opts: StatOptions): Promise[|[Stats, BigIntStats]]
    Annotations
    @inline()
  49. def lstat(path: PathLike, opts: StatOptionsbiginttrue): Promise[BigIntStats]
    Annotations
    @inline()
  50. def lstat(path: PathLike, opts: StatOptionsbigintfalseund): Promise[Stats]
    Annotations
    @inline()
  51. def lstat(path: PathLike): Promise[Stats]

    Asynchronous lstat(2) - Get file status.

    Asynchronous lstat(2) - Get file status. Does not dereference symbolic links.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  52. def lutimes(path: PathLike, atime: Double, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  53. def lutimes(path: PathLike, atime: Double, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  54. def lutimes(path: PathLike, atime: Double, mtime: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  55. def lutimes(path: PathLike, atime: Date, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  56. def lutimes(path: PathLike, atime: Date, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  57. def lutimes(path: PathLike, atime: Date, mtime: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  58. def lutimes(path: PathLike, atime: scala.Predef.String, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  59. def lutimes(path: PathLike, atime: scala.Predef.String, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  60. def lutimes(path: PathLike, atime: scala.Predef.String, mtime: scala.Predef.String): Promise[Unit]

    Changes the access and modification times of a file in the same way as fsPromises.utimes(), with the difference that if the path refers to a symbolic link, then the link is not dereferenced: instead, the timestamps of the symbolic link itself are changed.

    Changes the access and modification times of a file in the same way as fsPromises.utimes(), with the difference that if the path refers to a symbolic link, then the link is not dereferenced: instead, the timestamps of the symbolic link itself are changed.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    atime

    The last access time. If a string is provided, it will be coerced to number.

    mtime

    The last modified time. If a string is provided, it will be coerced to number.

    Annotations
    @inline()
  61. def mkdir(path: PathLike, options: Mode): Promise[Unit]
    Annotations
    @inline()
  62. def mkdir(path: PathLike, options: MakeDirectoryOptions): Promise[UndefOr[scala.Predef.String]]
    Annotations
    @inline()
  63. def mkdir(path: PathLike, options: MakeDirectoryOptionsrecurMode): Promise[Unit]
    Annotations
    @inline()
  64. def mkdir(path: PathLike, options: MakeDirectoryOptionsrecur): Promise[UndefOr[scala.Predef.String]]

    Asynchronous mkdir(2) - create a directory.

    Asynchronous mkdir(2) - create a directory.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    options

    Either the file mode, or an object optionally specifying the file mode and whether parent folders should be created. If a string is passed, it is parsed as an octal integer. If not specified, defaults to 0o777.

    Annotations
    @inline()
  65. def mkdir(path: PathLike): Promise[Unit]

    Asynchronous mkdir(2) - create a directory.

    Asynchronous mkdir(2) - create a directory.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  66. def mkdtemp(prefix: scala.Predef.String, options: BufferEncodingOption): Promise[Buffer]

    Asynchronously creates a unique temporary directory.

    Asynchronously creates a unique temporary directory. Generates six random characters to be appended behind a required prefix to create a unique temporary directory.

    options

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, 'utf8' is used.

    Annotations
    @inline()
  67. def mkdtemp(prefix: scala.Predef.String, options: BaseEncodingOptions): Promise[scala.Predef.String]
    Annotations
    @inline()
  68. def mkdtemp(prefix: scala.Predef.String, options: BufferEncoding): Promise[scala.Predef.String]
    Annotations
    @inline()
  69. def mkdtemp(prefix: scala.Predef.String): Promise[scala.Predef.String]

    Asynchronously creates a unique temporary directory.

    Asynchronously creates a unique temporary directory. Generates six random characters to be appended behind a required prefix to create a unique temporary directory.

    Annotations
    @inline()
  70. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  71. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  72. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  73. def open(path: PathLike, flags: Double, mode: Mode): Promise[FileHandle]
    Annotations
    @inline()
  74. def open(path: PathLike, flags: Double): Promise[FileHandle]
    Annotations
    @inline()
  75. def open(path: PathLike, flags: scala.Predef.String, mode: Mode): Promise[FileHandle]
    Annotations
    @inline()
  76. def open(path: PathLike, flags: scala.Predef.String): Promise[FileHandle]

    Asynchronous open(2) - open and possibly create a file.

    Asynchronous open(2) - open and possibly create a file.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  77. def opendir(path: scala.Predef.String, options: OpenDirOptions): Promise[Dir]
    Annotations
    @inline()
  78. def opendir(path: scala.Predef.String): Promise[Dir]
    Annotations
    @inline()
  79. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Unit, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  80. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Null, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  81. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Double, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  82. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  83. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Unit, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  84. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Null, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  85. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Double, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  86. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  87. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Unit, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  88. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Null, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  89. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Double, position: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  90. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  91. def read[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double): Promise[Buffer[TBuffer]]
    Annotations
    @inline()
  92. def read[TBuffer](handle: FileHandle, buffer: TBuffer): Promise[Buffer[TBuffer]]

    Asynchronously reads data from the file referenced by the supplied FileHandle.

    Asynchronously reads data from the file referenced by the supplied FileHandle.

    handle

    A FileHandle.

    buffer

    The buffer that the data will be written to.

    Annotations
    @inline()
  93. def readFile(path: FileHandle, options: BufferEncoding): Promise[scala.Predef.String]
    Annotations
    @inline()
  94. def readFile(path: FileHandle, options: encodingnullundefinedflag): Promise[Buffer]
    Annotations
    @inline()
  95. def readFile(path: FileHandle, options: encodingBufferEncodingfla): Promise[scala.Predef.String]
    Annotations
    @inline()
  96. def readFile(path: FileHandle, options: BaseEncodingOptionsAborta): Promise[|[scala.Predef.String, Buffer]]
    Annotations
    @inline()
  97. def readFile(path: FileHandle): Promise[Buffer]
    Annotations
    @inline()
  98. def readFile(path: PathLike, options: BufferEncoding): Promise[scala.Predef.String]
    Annotations
    @inline()
  99. def readFile(path: PathLike, options: encodingnullundefinedflag): Promise[Buffer]
    Annotations
    @inline()
  100. def readFile(path: PathLike, options: encodingBufferEncodingfla): Promise[scala.Predef.String]

    Asynchronously reads the entire contents of a file.

    Asynchronously reads the entire contents of a file.

    path

    A path to a file. If a URL is provided, it must use the file: protocol. If a FileHandle is provided, the underlying file will _not_ be closed automatically.

    options

    An object that may contain an optional flag. If a flag is not provided, it defaults to 'r'.

    Annotations
    @inline()
  101. def readFile(path: PathLike, options: BaseEncodingOptionsAborta): Promise[|[scala.Predef.String, Buffer]]
    Annotations
    @inline()
  102. def readFile(path: PathLike): Promise[Buffer]

    Asynchronously reads the entire contents of a file.

    Asynchronously reads the entire contents of a file.

    path

    A path to a file. If a URL is provided, it must use the file: protocol. If a FileHandle is provided, the underlying file will _not_ be closed automatically.

    Annotations
    @inline()
  103. def readdir(path: PathLike, options: BufferEncoding): Promise[Array[scala.Predef.String]]
    Annotations
    @inline()
  104. def readdir(path: PathLike, options: Encoding): Promise[Array[Buffer]]

    Asynchronous readdir(3) - read a directory.

    Asynchronous readdir(3) - read a directory.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    options

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, 'utf8' is used.

    Annotations
    @inline()
  105. def readdir(path: PathLike, options: BaseEncodingOptionswithFiEncoding): Promise[Array[Dirent]]

    Asynchronous readdir(3) - read a directory.

    Asynchronous readdir(3) - read a directory.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    options

    If called with withFileTypes: true the result data will be an array of Dirent.

    Annotations
    @inline()
  106. def readdir(path: PathLike, options: BaseEncodingOptionswithFi): Promise[Array[scala.Predef.String]]
    Annotations
    @inline()
  107. def readdir(path: PathLike): Promise[Array[scala.Predef.String]]

    Asynchronous readdir(3) - read a directory.

    Asynchronous readdir(3) - read a directory.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  108. def readdir_buffer(path: PathLike, options: buffer_): Promise[Array[Buffer]]
    Annotations
    @inline()
  109. def readlink(path: PathLike, options: scala.Predef.String): Promise[|[scala.Predef.String, Buffer]]
    Annotations
    @inline()
  110. def readlink(path: PathLike, options: BufferEncodingOption): Promise[Buffer]

    Asynchronous readlink(2) - read value of a symbolic link.

    Asynchronous readlink(2) - read value of a symbolic link.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    options

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, 'utf8' is used.

    Annotations
    @inline()
  111. def readlink(path: PathLike, options: BaseEncodingOptions): Promise[scala.Predef.String]
    Annotations
    @inline()
  112. def readlink(path: PathLike, options: BufferEncoding): Promise[scala.Predef.String]
    Annotations
    @inline()
  113. def readlink(path: PathLike): Promise[scala.Predef.String]

    Asynchronous readlink(2) - read value of a symbolic link.

    Asynchronous readlink(2) - read value of a symbolic link.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  114. def realpath(path: PathLike, options: BufferEncodingOption): Promise[Buffer]

    Asynchronous realpath(3) - return the canonicalized absolute pathname.

    Asynchronous realpath(3) - return the canonicalized absolute pathname.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    options

    The encoding (or an object specifying the encoding), used as the encoding of the result. If not provided, 'utf8' is used.

    Annotations
    @inline()
  115. def realpath(path: PathLike, options: BaseEncodingOptions): Promise[scala.Predef.String]
    Annotations
    @inline()
  116. def realpath(path: PathLike, options: BufferEncoding): Promise[scala.Predef.String]
    Annotations
    @inline()
  117. def realpath(path: PathLike): Promise[scala.Predef.String]

    Asynchronous realpath(3) - return the canonicalized absolute pathname.

    Asynchronous realpath(3) - return the canonicalized absolute pathname.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  118. def rename(oldPath: PathLike, newPath: PathLike): Promise[Unit]

    Asynchronous rename(2) - Change the name or location of a file or directory.

    Asynchronous rename(2) - Change the name or location of a file or directory.

    oldPath

    A path to a file. If a URL is provided, it must use the file: protocol. URL support is _experimental_.

    newPath

    A path to a file. If a URL is provided, it must use the file: protocol. URL support is _experimental_.

    Annotations
    @inline()
  119. def rm(path: PathLike, options: RmOptions): Promise[Unit]
    Annotations
    @inline()
  120. def rm(path: PathLike): Promise[Unit]

    Asynchronously removes files and directories (modeled on the standard POSIX rm utility).

    Asynchronously removes files and directories (modeled on the standard POSIX rm utility).

    Annotations
    @inline()
  121. def rmdir(path: PathLike, options: RmDirOptions): Promise[Unit]
    Annotations
    @inline()
  122. def rmdir(path: PathLike): Promise[Unit]

    Asynchronous rmdir(2) - delete a directory.

    Asynchronous rmdir(2) - delete a directory.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  123. def stat(path: PathLike, opts: StatOptions): Promise[|[Stats, BigIntStats]]
    Annotations
    @inline()
  124. def stat(path: PathLike, opts: StatOptionsbiginttrue): Promise[BigIntStats]
    Annotations
    @inline()
  125. def stat(path: PathLike, opts: StatOptionsbigintfalseund): Promise[Stats]
    Annotations
    @inline()
  126. def stat(path: PathLike): Promise[Stats]

    Asynchronous stat(2) - Get file status.

    Asynchronous stat(2) - Get file status.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  127. def symlink(target: PathLike, path: PathLike, type: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  128. def symlink(target: PathLike, path: PathLike): Promise[Unit]

    Asynchronous symlink(2) - Create a new symbolic link to an existing file.

    Asynchronous symlink(2) - Create a new symbolic link to an existing file.

    target

    A path to an existing file. If a URL is provided, it must use the file: protocol.

    path

    A path to the new symlink. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  129. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  130. def toString(): java.lang.String
    Definition Classes
    AnyRef → Any
  131. def truncate(path: PathLike, len: Double): Promise[Unit]
    Annotations
    @inline()
  132. def truncate(path: PathLike): Promise[Unit]

    Asynchronous truncate(2) - Truncate a file to a specified length.

    Asynchronous truncate(2) - Truncate a file to a specified length.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  133. def unlink(path: PathLike): Promise[Unit]

    Asynchronous unlink(2) - delete a name and possibly the file it refers to.

    Asynchronous unlink(2) - delete a name and possibly the file it refers to.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  134. def utimes(path: PathLike, atime: Double, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  135. def utimes(path: PathLike, atime: Double, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  136. def utimes(path: PathLike, atime: Double, mtime: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  137. def utimes(path: PathLike, atime: Date, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  138. def utimes(path: PathLike, atime: Date, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  139. def utimes(path: PathLike, atime: Date, mtime: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  140. def utimes(path: PathLike, atime: scala.Predef.String, mtime: Double): Promise[Unit]
    Annotations
    @inline()
  141. def utimes(path: PathLike, atime: scala.Predef.String, mtime: Date): Promise[Unit]
    Annotations
    @inline()
  142. def utimes(path: PathLike, atime: scala.Predef.String, mtime: scala.Predef.String): Promise[Unit]

    Asynchronously change file timestamps of the file referenced by the supplied path.

    Asynchronously change file timestamps of the file referenced by the supplied path.

    path

    A path to a file. If a URL is provided, it must use the file: protocol.

    atime

    The last access time. If a string is provided, it will be coerced to number.

    mtime

    The last modified time. If a string is provided, it will be coerced to number.

    Annotations
    @inline()
  143. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  144. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  145. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  146. def watch(filename: PathLike, options: scala.Predef.String): AsyncIterable[|[Buffer, scala.Predef.String]]
    Annotations
    @inline()
  147. def watch(filename: PathLike, options: WatchOptions): AsyncIterable[scala.Predef.String]

    Watch for changes on filename, where filename is either a file or a directory, returning an FSWatcher.

    Watch for changes on filename, where filename is either a file or a directory, returning an FSWatcher.

    filename

    A path to a file or directory. If a URL is provided, it must use the file: protocol.

    options

    Either the encoding for the filename provided to the listener, or an object optionally specifying encoding, persistent, and recursive options. If encoding is not supplied, the default of 'utf8' is used. If persistent is not supplied, the default of true is used. If recursive is not supplied, the default of false is used.

    Annotations
    @inline()
  148. def watch(filename: PathLike, options: BufferEncoding): AsyncIterable[scala.Predef.String]
    Annotations
    @inline()
  149. def watch(filename: PathLike, options: WatchOptionsencodingbuffe): AsyncIterable[Buffer]

    Watch for changes on filename, where filename is either a file or a directory, returning an FSWatcher.

    Watch for changes on filename, where filename is either a file or a directory, returning an FSWatcher.

    filename

    A path to a file or directory. If a URL is provided, it must use the file: protocol.

    options

    Either the encoding for the filename provided to the listener, or an object optionally specifying encoding, persistent, and recursive options. If encoding is not supplied, the default of 'utf8' is used. If persistent is not supplied, the default of true is used. If recursive is not supplied, the default of false is used.

    Annotations
    @inline()
  150. def watch(filename: PathLike): AsyncIterable[scala.Predef.String]

    Watch for changes on filename, where filename is either a file or a directory, returning an FSWatcher.

    Watch for changes on filename, where filename is either a file or a directory, returning an FSWatcher.

    filename

    A path to a file or directory. If a URL is provided, it must use the file: protocol.

    Annotations
    @inline()
  151. def watch_buffer(filename: PathLike, options: buffer_): AsyncIterable[Buffer]
    Annotations
    @inline()
  152. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Unit, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  153. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Null, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  154. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Double, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  155. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Unit, length: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  156. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Unit, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  157. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Null, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  158. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Double, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  159. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Null, length: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  160. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Unit, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  161. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Null, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  162. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Double, position: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  163. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double, length: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  164. def write[TBuffer](handle: FileHandle, buffer: TBuffer, offset: Double): Promise[BytesWritten[TBuffer]]
    Annotations
    @inline()
  165. def write[TBuffer](handle: FileHandle, buffer: TBuffer): Promise[BytesWritten[TBuffer]]

    Asynchronously writes buffer to the file referenced by the supplied FileHandle.

    Asynchronously writes buffer to the file referenced by the supplied FileHandle. It is unsafe to call fsPromises.write() multiple times on the same file without waiting for the Promise to be resolved (or rejected). For this scenario, fs.createWriteStream is strongly recommended.

    handle

    A FileHandle.

    buffer

    The buffer that the data will be written to.

    Annotations
    @inline()
  166. def write(handle: FileHandle, string: scala.Predef.String, position: Unit, encoding: BufferEncoding): Promise[BufferBytesWritten]
    Annotations
    @inline()
  167. def write(handle: FileHandle, string: scala.Predef.String, position: Null, encoding: BufferEncoding): Promise[BufferBytesWritten]
    Annotations
    @inline()
  168. def write(handle: FileHandle, string: scala.Predef.String, position: Double, encoding: BufferEncoding): Promise[BufferBytesWritten]
    Annotations
    @inline()
  169. def write(handle: FileHandle, string: scala.Predef.String, position: Double): Promise[BufferBytesWritten]
    Annotations
    @inline()
  170. def write(handle: FileHandle, string: scala.Predef.String): Promise[BufferBytesWritten]

    Asynchronously writes string to the file referenced by the supplied FileHandle.

    Asynchronously writes string to the file referenced by the supplied FileHandle. It is unsafe to call fsPromises.write() multiple times on the same file without waiting for the Promise to be resolved (or rejected). For this scenario, fs.createWriteStream is strongly recommended.

    handle

    A FileHandle.

    string

    A string to write.

    Annotations
    @inline()
  171. def writeFile(path: FileHandle, data: Iterable[|[scala.Predef.String, ArrayBufferView]], options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  172. def writeFile(path: FileHandle, data: Iterable[|[scala.Predef.String, ArrayBufferView]], options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  173. def writeFile(path: FileHandle, data: Iterable[|[ArrayBufferView, scala.Predef.String]]): Promise[Unit]
    Annotations
    @inline()
  174. def writeFile(path: FileHandle, data: scala.Predef.String, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  175. def writeFile(path: FileHandle, data: scala.Predef.String, options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  176. def writeFile(path: FileHandle, data: scala.Predef.String): Promise[Unit]
    Annotations
    @inline()
  177. def writeFile(path: FileHandle, data: AsyncIterable[|[scala.Predef.String, ArrayBufferView]], options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  178. def writeFile(path: FileHandle, data: AsyncIterable[|[scala.Predef.String, ArrayBufferView]], options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  179. def writeFile(path: FileHandle, data: AsyncIterable[|[ArrayBufferView, scala.Predef.String]]): Promise[Unit]
    Annotations
    @inline()
  180. def writeFile(path: FileHandle, data: streamMod.Stream, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  181. def writeFile(path: FileHandle, data: streamMod.Stream, options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  182. def writeFile(path: FileHandle, data: streamMod.Stream): Promise[Unit]
    Annotations
    @inline()
  183. def writeFile(path: FileHandle, data: ArrayBufferView, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  184. def writeFile(path: FileHandle, data: ArrayBufferView, options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  185. def writeFile(path: FileHandle, data: ArrayBufferView): Promise[Unit]
    Annotations
    @inline()
  186. def writeFile(path: PathLike, data: Iterable[|[scala.Predef.String, ArrayBufferView]], options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  187. def writeFile(path: PathLike, data: Iterable[|[scala.Predef.String, ArrayBufferView]], options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  188. def writeFile(path: PathLike, data: Iterable[|[ArrayBufferView, scala.Predef.String]]): Promise[Unit]
    Annotations
    @inline()
  189. def writeFile(path: PathLike, data: scala.Predef.String, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  190. def writeFile(path: PathLike, data: scala.Predef.String, options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  191. def writeFile(path: PathLike, data: scala.Predef.String): Promise[Unit]

    Asynchronously writes data to a file, replacing the file if it already exists.

    Asynchronously writes data to a file, replacing the file if it already exists. It is unsafe to call fsPromises.writeFile() multiple times on the same file without waiting for the Promise to be resolved (or rejected).

    path

    A path to a file. If a URL is provided, it must use the file: protocol. URL support is _experimental_. If a FileHandle is provided, the underlying file will _not_ be closed automatically.

    data

    The data to write. If something other than a Buffer or Uint8Array is provided, the value is coerced to a string.

    Annotations
    @inline()
  192. def writeFile(path: PathLike, data: AsyncIterable[|[scala.Predef.String, ArrayBufferView]], options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  193. def writeFile(path: PathLike, data: AsyncIterable[|[scala.Predef.String, ArrayBufferView]], options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  194. def writeFile(path: PathLike, data: AsyncIterable[|[ArrayBufferView, scala.Predef.String]]): Promise[Unit]
    Annotations
    @inline()
  195. def writeFile(path: PathLike, data: streamMod.Stream, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  196. def writeFile(path: PathLike, data: streamMod.Stream, options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  197. def writeFile(path: PathLike, data: streamMod.Stream): Promise[Unit]
    Annotations
    @inline()
  198. def writeFile(path: PathLike, data: ArrayBufferView, options: BufferEncoding): Promise[Unit]
    Annotations
    @inline()
  199. def writeFile(path: PathLike, data: ArrayBufferView, options: BaseEncodingOptionsmodeMo): Promise[Unit]
    Annotations
    @inline()
  200. def writeFile(path: PathLike, data: ArrayBufferView): Promise[Unit]
    Annotations
    @inline()

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from AnyRef

Inherited from Any

Ungrouped