TrueUpdate Core 0.1.4

net.java.trueupdate.core.io
Class Sinks

java.lang.Object
  extended by net.java.trueupdate.core.io.Sinks

@Immutable
public class Sinks
extends Object

Provides functions for Sinks.

Author:
Christian Schlichtherle (copied and edited from TrueLicense Core 2.3.1)

Nested Class Summary
static interface Sinks.BindStatement<V,X extends Exception>
           
static interface Sinks.ExecuteStatement<V,X extends Exception>
           
 
Method Summary
static
<V,X extends Exception>
Sinks.BindStatement<V,X>
bind(OutputTask<V,X> task)
           
static Sink error()
          Returns a sink which writes to standard error without ever closing it.
static
<V,X extends Exception>
Sinks.ExecuteStatement<V,X>
execute(OutputTask<V,X> task)
           
static Sink output()
          Returns a sink which writes to standard output without ever closing it.
static Sink uncloseable(OutputStream out)
          Returns a sink which writes to the given output stream and just flushes the output stream instead of closing it.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

bind

public static <V,X extends Exception> Sinks.BindStatement<V,X> bind(OutputTask<V,X> task)

error

public static Sink error()
Returns a sink which writes to standard error without ever closing it.


execute

public static <V,X extends Exception> Sinks.ExecuteStatement<V,X> execute(OutputTask<V,X> task)

output

public static Sink output()
Returns a sink which writes to standard output without ever closing it.


uncloseable

public static Sink uncloseable(OutputStream out)
Returns a sink which writes to the given output stream and just flushes the output stream instead of closing it.

Parameters:
out - the output stream to use.

TrueUpdate Core 0.1.4

Copyright © 2013 Stimulus Software. All rights reserved.