scalax.file

FileSystem

class FileSystem extends AnyRef

Provides an interface to a file system and is a factory for other objects for accessing files and directories. Also is used for obtaining metadata about the filesystem.

Attributes
abstract
Since

1.0

Linear Supertypes
AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. FileSystem
  2. AnyRef
  3. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new FileSystem ()

Abstract Value Members

  1. def createTempDirectory (prefix: String = randomPrefix, suffix: String = null, dir: String = null, deleteOnExit: Boolean = true): Path

    Creates an empty directory in the provided directory with the provided prefix and suffixes, if the filesystem supports it.

    Creates an empty directory in the provided directory with the provided prefix and suffixes, if the filesystem supports it. If not then a UnsupportedOperationException is thrown. The directory will not replace an existing file/directory and it is guaranteed to be unique and not previously used by another process at time of creation.

    prefix

    the starting characters of the directory name. Default is a randomly generated prefix

    suffix

    the last characters of the directory name Default is null (no suffix)

    dir

    the directory to create the directory in. If null or not declared the directory will be created in the system temporary folder Default is null (system/user temp folder)

    deleteOnExit

    If true then the directory and all contained folders will be deleted when the JVM is shutdown. Default is true

    Attributes
    abstract
  2. def createTempFile (prefix: String = randomPrefix, suffix: String = null, dir: String = null, deleteOnExit: Boolean = true): Path

    Creates an empty file in the provided directory with the provided prefix and suffixes, if the filesystem supports it.

    Creates an empty file in the provided directory with the provided prefix and suffixes, if the filesystem supports it. If not then a UnsupportedOperationException is thrown.

    The file will not replace an existing file and it is guaranteed to be unique and not previously used by another process at time of creation.

    prefix

    the starting characters of the file name. Default is a randomly generated prefix

    suffix

    the last characters of the file name Default is null (no suffix)

    dir

    the directory to create the file in. If null or not declared the file will be created in the system temporary folder Default is null (system/user temp folder)

    deleteOnExit

    If true then the file will be deleted when the JVM is shutdown Default is true

    Attributes
    abstract
  3. def fromString (path: String): Path

    Create a path object for the filesystem

    Create a path object for the filesystem

    Attributes
    abstract
  4. def name : String

    A name identifying the filesystem

    A name identifying the filesystem

    Attributes
    abstract
  5. def roots : List[Path]

    Returns the list of roots for this filesystem

    Returns the list of roots for this filesystem

    Attributes
    abstract
  6. def separator : String

    The path segment separator string for the filesystem

    The path segment separator string for the filesystem

    Attributes
    abstract

Concrete Value Members

  1. def != (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  2. def != (arg0: Any): Boolean

    Attributes
    final
    Definition Classes
    Any
  3. def ## (): Int

    Attributes
    final
    Definition Classes
    AnyRef → Any
  4. def == (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  5. def == (arg0: Any): Boolean

    Attributes
    final
    Definition Classes
    Any
  6. def apply (segments: String*): Path

  7. def asInstanceOf [T0] : T0

    Attributes
    final
    Definition Classes
    Any
  8. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  9. def eq (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  10. def equals (arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  11. def finalize (): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  12. def fromSeq (segments: Seq[String]): Path

    Create a path object for the filesystem from the path segments

  13. def getClass (): java.lang.Class[_]

    Attributes
    final
    Definition Classes
    AnyRef → Any
  14. def hashCode (): Int

    Definition Classes
    AnyRef → Any
  15. def isInstanceOf [T0] : Boolean

    Attributes
    final
    Definition Classes
    Any
  16. val legalChars : List[Char]

    Attributes
    protected
  17. def matcher (pattern: String, syntax: String = PathMatcher.StandardSyntax.GLOB): PathMatcher

    Creates a function that returns true if parameter matches the pattern used to create the function.

    Creates a function that returns true if parameter matches the pattern used to create the function.

    If the syntax is glob then the following patterns are accepted:

    • The * character matches zero or more characters of a name component without crossing directory boundaries.
    • <The ** characters matches zero or more characters crossing directory boundaries.
    • The ? character matches exactly one character of a name component.
    • The backslash character (\) is used to escape characters that would otherwise be interpreted as special characters. The expression \\ matches a single backslash and "\{" matches a left brace for example.

    Currently unsupported slated to be supported shortly are:

    • The [ ] characters are a bracket expression that match a single character of a name component out of a set of characters. For example, [abc] matches "a", "b", or "c". The hyphen (-) may be used to specify a range so [a-z] specifies a range that matches from "a" to "z" (inclusive). These forms can be mixed so [abce-g] matches "a", "b", "c", "e", "f" or "g". If the character after the [ is a ! then it is used for negation so [!a-c] matches any character except "a", "b", or "c".
    • Within a bracket expression the *, ? and \ characters match themselves. The (-) character matches itself if it is the first character within the brackets, or the first character after the ! if negating.
    • The { } characters are a group of subpatterns, where the group matches if any subpattern in the group matches. The "," character is used to separate the subpatterns. Groups cannot be nested.
    • All other characters match themselves in an implementation dependent manner. This includes characters representing any name-separators.

    The matching of root components is highly implementation-dependent and is not specified.

    If the syntax is regex then the pattern component is a pattern as defined by the java.util.regex.Pattern class

    In both cases the matching is case sensitive

    pattern

    the pattern of the match

    syntax

    the identifier of the syntax that will be used to interpret the pattern Default is glob

    @return a function that matches paths agains the matching specification in syntax and Pattern

    See also

    Path#contents

  18. def ne (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  19. def notify (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  20. def notifyAll (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  21. def randomPrefix : String

  22. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  23. def toString (): String

    Definition Classes
    AnyRef → Any
  24. def urlStreamHandler : Option[URLStreamHandler]

    Returns a URLStreamHandler if the protocol in the URI is not supported by default JAVA.

    Returns a URLStreamHandler if the protocol in the URI is not supported by default JAVA. This handler is used to construct URLs for the Paths as well as by scalax.file.PathURLStreamHandlerFactory The default behavoir is to return None this assumes that the default protocol handlers can handle the protocol

  25. def wait (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  26. def wait (arg0: Long, arg1: Int): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  27. def wait (arg0: Long): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from AnyRef

Inherited from Any