case class FilePath(name: String, parent: Option[FilePath]) extends Ordered[FilePath] with Product with Serializable

A representation of a FilePath, made of a series of path segments, ending with a name. A FilePath is represented in memory as a "name" (the final part of the path), and an optional reference to a parent. In this manner, it is comparable to a scala List, except that it is reversed.

The purpose of this class is to represent the same thing as a java.io.File or a java.nio.file.Path, but without the intention of actually interacting with any filesystem. FilePath is purely representational data.

Linear Supertypes
Serializable, Product, Equals, Ordered[FilePath], Comparable[FilePath], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. FilePath
  2. Serializable
  3. Product
  4. Equals
  5. Ordered
  6. Comparable
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new FilePath(name: String, parent: Option[FilePath])

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. def /(childPath: FilePath): FilePath

    Returns a new FilePath that represents the childPath relative to this path.

    Returns a new FilePath that represents the childPath relative to this path. For example:

    FilePath("a", "b") / FilePath("c", "d") == FilePath("a", "b", "c", "d")
  4. def /(childName: String): FilePath

    Returns a new FilePath whose name is childName and whose parent is this path.

  5. def <(that: FilePath): Boolean
    Definition Classes
    Ordered
  6. def <=(that: FilePath): Boolean
    Definition Classes
    Ordered
  7. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. def >(that: FilePath): Boolean
    Definition Classes
    Ordered
  9. def >=(that: FilePath): Boolean
    Definition Classes
    Ordered
  10. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  11. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  12. def compare(that: FilePath): Int
    Definition Classes
    FilePath → Ordered
  13. def compareTo(that: FilePath): Int
    Definition Classes
    Ordered → Comparable
  14. def endsWith(that: FilePath): Boolean

    Returns true if this path ends with the segments of that path.

    Returns true if this path ends with the segments of that path. For example: a path like "a/b/c/d/e/f" ends with "d/e/f".

  15. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  17. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  18. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  19. val name: String
  20. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  21. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  23. val parent: Option[FilePath]
  24. def productElementNames: Iterator[String]
    Definition Classes
    Product
  25. def reverseSegmentsIterator: Iterator[String]
  26. def segments: List[String]

    A collection of the segments in this path, ending with the name

  27. def startsWith(that: FilePath): Boolean

    Returns true if this path starts with the segments of that path.

    Returns true if this path starts with the segments of that path. For example: a path like "a/b/c/d/e/f" starts with "a/b/c".

  28. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  29. def toFile(parent: File): File

    Converts this path to a java-style File, relative to the given parent file.

    Converts this path to a java-style File, relative to the given parent file. For example:

    FilePath("a", "b", "c").toFile(File("/some/dir")) == File("/some/dir/a/b/c")
  30. def toFile: File

    Converts this path to a java-style relative File.

  31. def toString(): String
    Definition Classes
    FilePath → AnyRef → Any
  32. def toUnixPath: String

    Converts this path to a String that represents the path, with a forward slash ('/') as the separator.

    Converts this path to a String that represents the path, with a forward slash ('/') as the separator.

    FilePath("a", "b", "c") => "a/b/c"
  33. def toWindowsPath: String

    Converts this path to a String that represents the path, with back slashes ('\') as separators.

    Converts this path to a String that represents the path, with back slashes ('\') as separators.

    FilePath("a", "b", "c") => "a\b\c"
  34. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  35. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  36. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from Ordered[FilePath]

Inherited from Comparable[FilePath]

Inherited from AnyRef

Inherited from Any

Ungrouped