Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.infohazard.maverick.util
Interface Buffer  view Buffer download Buffer.java

All Known Implementing Classes:
PrintWriterBuffer, ServletOutputStreamBuffer

public interface Buffer

Simple interface to abstract out both ServletOutputStreams and PrintWriters.


Method Summary
 java.io.Reader getAsReader()
          Produces a reader of the buffered data.
 java.lang.String getAsString()
          Produces the buffered data in string form.
 boolean prefersReader()
          True if it is more efficient to call toReader() than toString().
 int size()
           
 

Method Detail

prefersReader

public boolean prefersReader()
True if it is more efficient to call toReader() than toString().


getAsReader

public java.io.Reader getAsReader()
                           throws java.io.UnsupportedEncodingException
Produces a reader of the buffered data.


getAsString

public java.lang.String getAsString()
                             throws java.io.UnsupportedEncodingException
Produces the buffered data in string form.


size

public int size()