Trait

com.fulcrumgenomics.commons.io

IoUtil

Related Doc: package io

Permalink

trait IoUtil extends AnyRef

Trait that can be mixed in to make an Io utility object, and can be re-used elsewhere.

Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. IoUtil
  2. AnyRef
  3. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. def +(other: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to any2stringadd[IoUtil] performed by method any2stringadd in scala.Predef.
    Definition Classes
    any2stringadd
  4. def ->[B](y: B): (IoUtil, B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to ArrowAssoc[IoUtil] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  6. val DevNull: Path

    Permalink
  7. val StdIn: Path

    Permalink
  8. val StdOut: Path

    Permalink
  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. def assertCanWriteFile(path: Path, parentMustExist: Boolean = true): Unit

    Permalink

    Asserts that it will be possible to write to a file at Path, possibly after creating parent directories.

    Asserts that it will be possible to write to a file at Path, possibly after creating parent directories.

    path

    the path to check

    parentMustExist

    if true (default) the file or its direct parent must exist, if false then only require that the first parent that actually exists is writable

  11. def assertCanWriteFiles(paths: TraversableOnce[_ <: Path], parentMustExist: Boolean = true): Unit

    Permalink

    Asserts that it will be possible to write to a file at Path, possibly after creating parent directories.

    Asserts that it will be possible to write to a file at Path, possibly after creating parent directories.

    paths

    one or more paths to check

    parentMustExist

    if true (default) the file or its direct parent must exist, if false then only require that the first parent that actually exists is writable

  12. def assertListable(path: Path): Unit

    Permalink

    Asserts that the Path represents a directory that can be listed.

  13. def assertListable(paths: TraversableOnce[_ <: Path]): Unit

    Permalink

    Asserts that the Paths represent directories that can be listed.

  14. def assertReadable(path: Path): Unit

    Permalink

    Asserts that the Paths represents files that can be opened and read.

  15. def assertReadable(paths: TraversableOnce[_ <: Path]): Unit

    Permalink

    Asserts that the Path represents a file that can be opened and read.

  16. def assertWritableDirectory(path: Path): Unit

    Permalink

    Asserts that a path represents an existing directory and that new files can be created within the directory.

  17. def assertWritableDirectory(paths: TraversableOnce[_ <: Path]): Unit

    Permalink

    Asserts that a path represents an existing directory and that new files can be created within the directory.

  18. def bufferSize: Int

    Permalink

    How large a buffer should be used when buffering operations.

  19. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  20. def ensuring(cond: (IoUtil) ⇒ Boolean, msg: ⇒ Any): IoUtil

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to Ensuring[IoUtil] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  21. def ensuring(cond: (IoUtil) ⇒ Boolean): IoUtil

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to Ensuring[IoUtil] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  22. def ensuring(cond: Boolean, msg: ⇒ Any): IoUtil

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to Ensuring[IoUtil] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  23. def ensuring(cond: Boolean): IoUtil

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to Ensuring[IoUtil] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  24. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  25. def equals(arg0: Any): Boolean

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

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  27. def formatted(fmtstr: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to StringFormat[IoUtil] performed by method StringFormat in scala.Predef.
    Definition Classes
    StringFormat
    Annotations
    @inline()
  28. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  29. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  30. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  31. def makeTempDir(name: String): Path

    Permalink

    Makes a new temporary directory.

  32. def makeTempFile(prefix: String, suffix: String, dir: Option[Path] = None): Path

    Permalink

    Makes a new temporary file.

  33. def mkdirs(path: Path): Boolean

    Permalink

    Method that attempts to create a directory and all it's parents.

    Method that attempts to create a directory and all it's parents.

    returns

    true if the directory exists after the call, false otherwise

  34. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  35. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  36. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  37. def pipeStream(stream: InputStream, sink: (String) ⇒ Unit): AsyncStreamSink

    Permalink

    Creates an object that will asynchronously read character data from a stream and pipe it into a sink function.

  38. def readBytesFromResource(name: String): Array[Byte]

    Permalink

    Finds a resource with a given name on the classpath and produces an array of the bytes from the resource.

    Finds a resource with a given name on the classpath and produces an array of the bytes from the resource.

    The way resources are traditionally loaded from the class path via Class.getResource() and ClassLoader.getResource() have confusing behaviour. Notably:

    * Class.getResource() interprets paths as relative, and requires a leading / to make them absolute * ClassLoader.getResource() interprets all paths a absolute and fails on leading /s

    The implementation here first tries Class.getResource and then ClassLoader.getResource to enable it to find relative paths and also absolute paths with and without leading /s.

  39. def readLines(path: Path): Iterator[String]

    Permalink

    Reads the path provides and produces an iterator of lines of text from the file.

    Reads the path provides and produces an iterator of lines of text from the file. The underlying file handle will not be closed until the end of the iterator is reached.

  40. def readLinesFromResource(name: String): Iterator[String]

    Permalink

    Finds a resource with a given name on the classpath and produces an iterator of lines of text from the resource.

    Finds a resource with a given name on the classpath and produces an iterator of lines of text from the resource.

    The way resources are traditionally loaded from the class path via Class.getResource() and ClassLoader.getResource() have confusing behaviour. Notably:

    * Class.getResource() interprets paths as relative, and requires a leading / to make them absolute * ClassLoader.getResource() interprets all paths a absolute and fails on leading /s

    The implementation here first tries Class.getResource and then ClassLoader.getResource to enable it to find relative paths and also absolute paths with and without leading /s.

  41. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  42. def toInputStream(path: Path): InputStream

    Permalink

    Creates a new InputStream to read from the supplied path.

  43. def toOutputStream(path: Path): OutputStream

    Permalink

    Creates a new BufferedReader to read from the supplied path.

  44. def toReader(path: Path): BufferedReader

    Permalink

    Creates a new BufferedReader to read from the supplied path.

  45. def toSource(path: Path): Source

    Permalink

    Constructs a scala Source object from the path, in a way that will correctly close the source on close().

  46. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  47. def toWriter(path: Path): BufferedWriter

    Permalink

    Creates a new BufferedWriter to write to the supplied path.

  48. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  51. def writeLines(path: Path, lines: TraversableOnce[String]): Unit

    Permalink

    Writes one or more lines to a file represented by a path.

  52. def [B](y: B): (IoUtil, B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from IoUtil to ArrowAssoc[IoUtil] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc

Inherited from AnyRef

Inherited from Any

Inherited by implicit conversion any2stringadd from IoUtil to any2stringadd[IoUtil]

Inherited by implicit conversion StringFormat from IoUtil to StringFormat[IoUtil]

Inherited by implicit conversion Ensuring from IoUtil to Ensuring[IoUtil]

Inherited by implicit conversion ArrowAssoc from IoUtil to ArrowAssoc[IoUtil]

Ungrouped