Class PathScurryWin32

Windows implementation of PathScurryBase

Defaults to case insensitve, uses '\\' to generate path strings. Uses PathWin32 for Path objects.

Hierarchy

Constructors

Properties

#children: ChildrenCache
#fs: FSValue
#resolveCache: ResolveCache
#resolvePosixCache: ResolveCache

The Path entry corresponding to this PathScurry's current working directory.

nocase: boolean

Perform path comparisons case-insensitively.

Defaults true on Darwin and Windows systems, false elsewhere.

root: PathBase

The root Path entry for the current working directory of this Scurry

rootPath: string

The string path for the root of this Scurry's current working directory

roots: {
    [k: string]: PathBase;
}

A collection of all roots encountered, referenced by rootPath

Type declaration

sep: "\\" = '\\'

separator for generating path strings

Methods

  • Call lstat() on the string or Path object, and update all known information that can be determined.

    Note that unlike fs.lstat(), the returned value does not contain some information, such as mode, dev, nlink, and ino. If that information is required, you will need to call fs.lstat yourself.

    If the Path refers to a nonexistent file, or if the lstat call fails for any reason, undefined is returned. Otherwise the updated Path object is returned.

    Results are cached, and thus may be out of date if the filesystem is mutated.

    Parameters

    Returns Promise<undefined | PathBase>

  • Return the Path object or string path corresponding to the target of a symbolic link.

    If the path is not a symbolic link, or if the readlink call fails for any reason, undefined is returned.

    Result is cached, and thus may be outdated if the filesystem is mutated.

    {withFileTypes} option defaults to false.

    On success, returns a Path object if withFileTypes option is true, otherwise a string.

    Returns Promise<undefined | string>

  • Parameters

    • opt: {
          withFileTypes: false;
      }
      • withFileTypes: false

    Returns Promise<undefined | string>

  • Parameters

    • opt: {
          withFileTypes: true;
      }
      • withFileTypes: true

    Returns Promise<undefined | PathBase>

  • Parameters

    • opt: {
          withFileTypes: boolean;
      }
      • withFileTypes: boolean

    Returns Promise<undefined | string | PathBase>

  • Parameters

    • entry: string | PathBase
    • Optional opt: {
          withFileTypes: false;
      }
      • withFileTypes: false

    Returns Promise<undefined | string>

  • Parameters

    • entry: string | PathBase
    • opt: {
          withFileTypes: true;
      }
      • withFileTypes: true

    Returns Promise<undefined | PathBase>

  • Parameters

    • entry: string | PathBase
    • opt: {
          withFileTypes: boolean;
      }
      • withFileTypes: boolean

    Returns Promise<undefined | string | PathBase>

  • Return the Path object or string path corresponding to path as resolved by realpath(3).

    If the realpath call fails for any reason, undefined is returned.

    Result is cached, and thus may be outdated if the filesystem is mutated.

    {withFileTypes} option defaults to false.

    On success, returns a Path object if withFileTypes option is true, otherwise a string.

    Returns Promise<undefined | string>

  • Parameters

    • opt: {
          withFileTypes: false;
      }
      • withFileTypes: false

    Returns Promise<undefined | string>

  • Parameters

    • opt: {
          withFileTypes: true;
      }
      • withFileTypes: true

    Returns Promise<undefined | PathBase>

  • Parameters

    • opt: {
          withFileTypes: boolean;
      }
      • withFileTypes: boolean

    Returns Promise<undefined | string | PathBase>

  • Parameters

    • entry: string | PathBase
    • Optional opt: {
          withFileTypes: false;
      }
      • withFileTypes: false

    Returns Promise<undefined | string>

  • Parameters

    • entry: string | PathBase
    • opt: {
          withFileTypes: true;
      }
      • withFileTypes: true

    Returns Promise<undefined | PathBase>

  • Parameters

    • entry: string | PathBase
    • opt: {
          withFileTypes: boolean;
      }
      • withFileTypes: boolean

    Returns Promise<undefined | string | PathBase>

  • find the relative path from the cwd to the supplied path string or entry, using / as the path delimiter, even on Windows.

    Parameters

    Returns string

  • Resolve one or more path strings to a resolved string

    Same interface as require('path').resolve.

    Much faster than path.resolve() when called multiple times for the same path, because the resolved Path objects are cached. Much slower otherwise.

    Parameters

    • Rest ...paths: string[]

    Returns string

  • Resolve one or more path strings to a resolved string, returning the posix path. Identical to .resolve() on posix systems, but on windows will return a forward-slash separated UNC path.

    Same interface as require('path').resolve.

    Much faster than path.resolve() when called multiple times for the same path, because the resolved Path objects are cached. Much slower otherwise.

    Parameters

    • Rest ...paths: string[]

    Returns string

Generated using TypeDoc