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.common.text
Class CharBuffer

    java.lang.Object
      org.jboss.portal.common.text.CharBuffer

All Implemented Interfaces:
  CharWriter

    public class CharBuffer

extends java.lang.Object
implements CharWriter

A simple char buffer that implements the `CharWriter` interface

Version:
  $Revision: 7228 $
Author:
  Julien Viet

Field Summary
`protected char[]` | `buffer` .
`protected int` | `length` .

Constructor Summary
`CharBuffer()`
`CharBuffer(int size)`

Method Summary
`CharWriter` | `append(char c)`
`CharWriter` | `append(char[] chars)`
`CharWriter` | `append(char[] chars, int off, int len)`
`CharWriter` | `append(java.lang.CharSequence s)`
`CharBuffer` | `append(java.lang.String s, CharEncoder encoder)`
`protected void` | `appendNoCheck(char[] chars, int off, int len)`
`protected void` | `appendNoCheck(java.lang.CharSequence s)`
`java.lang.String` | `asString()`
`java.lang.String` | `asString(boolean reset)`
`protected void` | `ensureCapacity(int minimumCapacity)`
`int` | `getCapacity()`
`int` | `getLength()`
`void` | `reset()`
`void` | `setLength(int length)`

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

Field Detail

### buffer

    protected char[] buffer

  .

### length

    protected int length

  .

Constructor Detail

### CharBuffer

    public CharBuffer(int size)
               throws java.lang.IllegalArgumentException

Parameters:
  `size` - the initial size
Throws:
  `java.lang.IllegalArgumentException` - if the initial size is not a positive value.

### CharBuffer

    public CharBuffer()

Method Detail

### append

    public CharBuffer append(java.lang.String s,
                             CharEncoder encoder)

### append

    public CharWriter append(java.lang.CharSequence s)

  Specified by:
    `append` in interface `CharWriter`

### append

    public CharWriter append(char[] chars,
                             int off,
                             int len)

  Specified by:
    `append` in interface `CharWriter`

### append

    public CharWriter append(char c)

  Specified by:
    `append` in interface `CharWriter`

### append

    public CharWriter append(char[] chars)

  Specified by:
    `append` in interface `CharWriter`

### asString

    public java.lang.String asString()

### asString

    public java.lang.String asString(boolean reset)

### getCapacity

    public int getCapacity()

### getLength

    public int getLength()

### setLength

    public void setLength(int length)

### reset

    public void reset()

### appendNoCheck

    protected final void appendNoCheck(char[] chars,
                                       int off,
                                       int len)

### appendNoCheck

    protected final void appendNoCheck(java.lang.CharSequence s)

### ensureCapacity

    protected final void ensureCapacity(int minimumCapacity)

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.