public abstract static class Input.SingleInput extends Input
| Modifier and Type | Class and Description |
|---|---|
static class |
Input.SingleInput.FromPath |
static class |
Input.SingleInput.FromStream |
static class |
Input.SingleInput.FromString |
Input.ArchiveMultiInput, Input.FolderMultiInput, Input.MultiInput, Input.PathArchiveMultiInput, Input.PipeArchiveMultiInput, Input.SingleInput| Constructor and Description |
|---|
SingleInput() |
| Modifier and Type | Method and Description |
|---|---|
abstract java.lang.String |
name() |
abstract java.io.InputStream |
open() |
static Input.SingleInput |
path(java.nio.file.Path path,
java.nio.file.OpenOption... opts)
A single file input.
|
static Input.SingleInput |
pipe(java.io.InputStream is)
Single file input for an existing
InputStream, such as stdin. |
static Input.SingleInput |
pipe(java.io.InputStream is,
java.lang.String name)
Single file input for an existing
InputStream, such as stdin. |
java.util.List<java.lang.String> |
readLines() |
static Input.SingleInput |
string(java.lang.String str)
Single file input for an existing
String. |
static Input.SingleInput |
string(java.lang.String str,
java.lang.String name)
Single file input for an existing
InputStream, such as stdin. |
public static Input.SingleInput string(java.lang.String str)
String.
This stream will have the name of 'pipe', diffing against this will produce this name in the +/- header lines.
str - The string.public static Input.SingleInput string(java.lang.String str, java.lang.String name)
InputStream, such as stdin.str - The string.name - The name of the stream. Used in +/- header lines of diffs.public static Input.SingleInput pipe(java.io.InputStream is)
InputStream, such as stdin.
This stream will have the name of 'pipe', diffing against this will produce this name in the +/- header lines.
is - The stream.public static Input.SingleInput pipe(java.io.InputStream is, java.lang.String name)
InputStream, such as stdin.is - The stream.name - The name of the stream. Used in +/- header lines of diffs.public static Input.SingleInput path(java.nio.file.Path path, java.nio.file.OpenOption... opts)
Path.path - The path.opts - Any open options for the path.public abstract java.io.InputStream open()
throws java.io.IOException
java.io.IOExceptionpublic java.util.List<java.lang.String> readLines()
throws java.io.IOException
java.io.IOExceptionpublic abstract java.lang.String name()