Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.portal.portlet.impl.jsr168
Class ContentBuffer

    java.lang.Object
      org.jboss.portal.portlet.impl.jsr168.ContentBuffer

    public class ContentBuffer

extends java.lang.Object

Data produced.

Version:
  $Revision: 5602 $
Author:
  Julien Viet

Constructor Summary
`ContentBuffer()`

Method Summary
`void` | `commit()` Simulate a response commit.
`byte[]` | `getBytes()` Return the bytes of the content held by the fragment or null.
`java.lang.String` | `getChars()` Return the chars of the content held by the fragment or null.
`java.lang.String` | `getContentType()` Return the content type of the generated fragment.
`java.io.OutputStream` | `getOutputStream()`
`java.io.PrintWriter` | `getWriter()` Returns the writer.
`boolean` | `isCommited()`
`void` | `reset()`
`void` | `setContentType(java.lang.String contentType)` Set the fragment of the content type.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ContentBuffer

    public ContentBuffer()

Method Detail

### getBytes

    public byte[] getBytes()

  Return the bytes of the content held by the fragment or null.

  Returns:
    the bytes

### getChars

    public java.lang.String getChars()

  Return the chars of the content held by the fragment or null.

  Returns:
    the chars

### getContentType

    public java.lang.String getContentType()

  Return the content type of the generated fragment.

  Returns:
    the content type

### setContentType

    public void setContentType(java.lang.String contentType)

  Set the fragment of the content type.

  Parameters:
    `contentType` - the content type

### getWriter

    public java.io.PrintWriter getWriter()
                                  throws java.lang.IllegalStateException

  Returns the writer.

  Returns:
    the writer
  Throws:
    `java.lang.IllegalStateException` - if the output stream is already used or if no content type is defined

### getOutputStream

    public java.io.OutputStream getOutputStream()
                                         throws java.lang.IllegalStateException

  Returns:
    the output stream
  Throws:
    `java.lang.IllegalStateException` - if the window writer is already used or if no content type is defined

### reset

    public void reset()

### commit

    public void commit()
                throws java.lang.IllegalStateException

  Simulate a response commit.

  Throws:
    `java.lang.IllegalStateException` - if no content type is defined

### isCommited

    public boolean isCommited()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008. All Rights Reserved.