Package org.codehaus.groovy.runtime

## Class WritablePath

- java.lang.Object
- - org.codehaus.groovy.runtime.WritablePath

- All Implemented Interfaces:
    `Writable`, `Comparable<Path>`, `Iterable<Path>`, `Path`, `Watchable`

      @Deprecated
      public class WritablePath
      extends Object
      implements Path, Writable

  Deprecated.
  A Writable Path.

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `WritablePath​(Path delegate)` | Deprecated.
    `WritablePath​(Path delegate, String encoding)` | Deprecated.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `int` | `compareTo​(Path other)` | Deprecated.
    `boolean` | `endsWith​(String other)` | Deprecated.
    `boolean` | `endsWith​(Path other)` | Deprecated.
    `boolean` | `equals​(Object other)` | Deprecated.
    `Path` | `getFileName()` | Deprecated.
    `FileSystem` | `getFileSystem()` | Deprecated.
    `Path` | `getName​(int index)` | Deprecated.
    `int` | `getNameCount()` | Deprecated.
    `Path` | `getParent()` | Deprecated.
    `Path` | `getRoot()` | Deprecated.
    `int` | `hashCode()` | Deprecated.
    `boolean` | `isAbsolute()` | Deprecated.
    `Iterator<Path>` | `iterator()` | Deprecated.
    `Path` | `normalize()` | Deprecated.
    `WatchKey` | `register​(WatchService watcher, WatchEvent.Kind<?>... events)` | Deprecated.
    `WatchKey` | `register​(WatchService watcher, WatchEvent.Kind<?>[] events, WatchEvent.Modifier... modifiers)` | Deprecated.
    `Path` | `relativize​(Path other)` | Deprecated.
    `Path` | `resolve​(String other)` | Deprecated.
    `Path` | `resolve​(Path other)` | Deprecated.
    `Path` | `resolveSibling​(String other)` | Deprecated.
    `Path` | `resolveSibling​(Path other)` | Deprecated.
    `boolean` | `startsWith​(String other)` | Deprecated.
    `boolean` | `startsWith​(Path other)` | Deprecated.
    `Path` | `subpath​(int beginIndex, int endIndex)` | Deprecated.
    `Path` | `toAbsolutePath()` | Deprecated.
    `File` | `toFile()` | Deprecated.
    `Path` | `toRealPath​(LinkOption... options)` | Deprecated.
    `String` | `toString()` | Deprecated.
    `URI` | `toUri()` | Deprecated.
    `Writer` | `writeTo​(Writer out)` | Deprecated. Writes this object to the given writer.

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface java.lang.Iterable

      `forEach, spliterator`

- - ### Constructor Detail

    - #### WritablePath

          public WritablePath​(Path delegate)

      Deprecated.

    - #### WritablePath

          public WritablePath​(Path delegate,
                              String encoding)

      Deprecated.

  - ### Method Detail

    - #### writeTo

          public Writer writeTo​(Writer out)
                         throws IOException

      Deprecated.
      Description copied from interface: `Writable`
      Writes this object to the given writer.

      This is used to defer content creation until the point when it is streamed to the output destination. Oftentimes, content will be defined but not necessarily created (as is may be the case with a Closure definition.) In that case, the output is then 'deferred' to the point when it is serialized to the writer. This class may be used whenever an object should be responsible for creating its own textual representation, but creating the entire output as a single String would be inefficient (such as outputting a multi-gigabyte XML document.)

      Specified by:
        `writeTo` in interface `Writable`
      Parameters:
        `out` - the Writer to which this Writable should output its data.
      Returns:
        the Writer that was passed
      Throws:
        `IOException` - if an error occurred while outputting data to the writer

    - #### getFileSystem

          public FileSystem getFileSystem()

      Deprecated.
      Specified by:
        `getFileSystem` in interface `Path`

    - #### isAbsolute

          public boolean isAbsolute()

      Deprecated.
      Specified by:
        `isAbsolute` in interface `Path`

    - #### getRoot

          public Path getRoot()

      Deprecated.
      Specified by:
        `getRoot` in interface `Path`

    - #### getFileName

          public Path getFileName()

      Deprecated.
      Specified by:
        `getFileName` in interface `Path`

    - #### getParent

          public Path getParent()

      Deprecated.
      Specified by:
        `getParent` in interface `Path`

    - #### getNameCount

          public int getNameCount()

      Deprecated.
      Specified by:
        `getNameCount` in interface `Path`

    - #### getName

          public Path getName​(int index)

      Deprecated.
      Specified by:
        `getName` in interface `Path`

    - #### subpath

          public Path subpath​(int beginIndex,
                              int endIndex)

      Deprecated.
      Specified by:
        `subpath` in interface `Path`

    - #### startsWith

          public boolean startsWith​(Path other)

      Deprecated.
      Specified by:
        `startsWith` in interface `Path`

    - #### startsWith

          public boolean startsWith​(String other)

      Deprecated.
      Specified by:
        `startsWith` in interface `Path`

    - #### endsWith

          public boolean endsWith​(Path other)

      Deprecated.
      Specified by:
        `endsWith` in interface `Path`

    - #### endsWith

          public boolean endsWith​(String other)

      Deprecated.
      Specified by:
        `endsWith` in interface `Path`

    - #### normalize

          public Path normalize()

      Deprecated.
      Specified by:
        `normalize` in interface `Path`

    - #### resolve

          public Path resolve​(Path other)

      Deprecated.
      Specified by:
        `resolve` in interface `Path`

    - #### resolve

          public Path resolve​(String other)

      Deprecated.
      Specified by:
        `resolve` in interface `Path`

    - #### resolveSibling

          public Path resolveSibling​(Path other)

      Deprecated.
      Specified by:
        `resolveSibling` in interface `Path`

    - #### resolveSibling

          public Path resolveSibling​(String other)

      Deprecated.
      Specified by:
        `resolveSibling` in interface `Path`

    - #### relativize

          public Path relativize​(Path other)

      Deprecated.
      Specified by:
        `relativize` in interface `Path`

    - #### toUri

          public URI toUri()

      Deprecated.
      Specified by:
        `toUri` in interface `Path`

    - #### toAbsolutePath

          public Path toAbsolutePath()

      Deprecated.
      Specified by:
        `toAbsolutePath` in interface `Path`

    - #### toRealPath

          public Path toRealPath​(LinkOption... options)
                          throws IOException

      Deprecated.
      Specified by:
        `toRealPath` in interface `Path`
      Throws:
        `IOException`

    - #### toFile

          public File toFile()

      Deprecated.
      Specified by:
        `toFile` in interface `Path`

    - #### register

          public WatchKey register​(WatchService watcher,
                                   WatchEvent.Kind<?>[] events,
                                   WatchEvent.Modifier... modifiers)
                            throws IOException

      Deprecated.
      Specified by:
        `register` in interface `Path`
      Specified by:
        `register` in interface `Watchable`
      Throws:
        `IOException`

    - #### register

          public WatchKey register​(WatchService watcher,
                                   WatchEvent.Kind<?>... events)
                            throws IOException

      Deprecated.
      Specified by:
        `register` in interface `Path`
      Specified by:
        `register` in interface `Watchable`
      Throws:
        `IOException`

    - #### iterator

          public Iterator<Path> iterator()

      Deprecated.
      Specified by:
        `iterator` in interface `Iterable<Path>`
      Specified by:
        `iterator` in interface `Path`

    - #### compareTo

          public int compareTo​(Path other)

      Deprecated.
      Specified by:
        `compareTo` in interface `Comparable<Path>`
      Specified by:
        `compareTo` in interface `Path`

    - #### equals

          public boolean equals​(Object other)

      Deprecated.
      Specified by:
        `equals` in interface `Path`
      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Deprecated.
      Specified by:
        `hashCode` in interface `Path`
      Overrides:
        `hashCode` in class `Object`

    - #### toString

          public String toString()

      Deprecated.
      Specified by:
        `toString` in interface `Path`
      Overrides:
        `toString` in class `Object`