|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.qi4j.api.io.Inputs
public class Inputs
Common inputs
Constructor Summary | |
---|---|
Inputs()
|
Method Summary | ||
---|---|---|
static Input<ByteBuffer,IOException> |
byteBuffer(File source,
int bufferSize)
Read a file using ByteBuffer of a given size. |
|
static Input<ByteBuffer,IOException> |
byteBuffer(InputStream source,
int bufferSize)
Read an inputstream using ByteBuffer of a given size. |
|
static
|
combine(Iterable<Input<T,SenderThrowableType>> inputs)
Combine many Input into one single Input. |
|
static
|
iterable(Iterable<T> iterable)
|
|
static Input<String,IOException> |
text(File source)
Read lines from a UTF-8 encoded textfile. |
|
static Input<String,IOException> |
text(File source,
String encoding)
Read lines from a textfile with the given encoding. |
|
static Input<String,IOException> |
text(URL source)
Read lines from a textfile at a given URL. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Inputs()
Method Detail |
---|
public static Input<String,IOException> text(File source)
source
- textfile with lines separated by \n character
public static Input<String,IOException> text(File source, String encoding)
source
- textfile with lines separated by \n characterencoding
- encoding of file, e.g. "UTF-8"
public static Input<String,IOException> text(URL source)
source
- textfile with lines separated by \n character
public static Input<ByteBuffer,IOException> byteBuffer(File source, int bufferSize)
source
- bufferSize
-
public static Input<ByteBuffer,IOException> byteBuffer(InputStream source, int bufferSize)
source
- bufferSize
-
public static <T,SenderThrowableType extends Throwable> Input<T,SenderThrowableType> combine(Iterable<Input<T,SenderThrowableType>> inputs)
T
- SenderThrowableType
- inputs
-
public static <T> Input<T,RuntimeException> iterable(Iterable<T> iterable)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |