FileDocCategorySizeDatePackage
ReadOnlyCharArrayBuffer.javaAPI DocAndroid 1.5 API3103Wed May 06 22:41:04 BST 2009java.nio

ReadOnlyCharArrayBuffer

public final class ReadOnlyCharArrayBuffer extends CharArrayBuffer
CharArrayBuffer, ReadWriteCharArrayBuffer and ReadOnlyCharArrayBuffer compose the implementation of array based char buffers.

ReadOnlyCharArrayBuffer extends CharArrayBuffer with all the write methods throwing read only exception.

This class is marked final for runtime performance.

Fields Summary
Constructors Summary
ReadOnlyCharArrayBuffer(int capacity, char[] backingArray, int arrayOffset)

        super(capacity, backingArray, arrayOffset);
    
Methods Summary
public java.nio.CharBufferasReadOnlyBuffer()

        return duplicate();
    
public java.nio.CharBuffercompact()

        throw new ReadOnlyBufferException();
    
static java.nio.ReadOnlyCharArrayBuffercopy(CharArrayBuffer other, int markOfOther)

        ReadOnlyCharArrayBuffer buf = new ReadOnlyCharArrayBuffer(other
                .capacity(), other.backingArray, other.offset);
        buf.limit = other.limit();
        buf.position = other.position();
        buf.mark = markOfOther;
        return buf;
    
public java.nio.CharBufferduplicate()

        return copy(this, mark);
    
public booleanisReadOnly()

        return true;
    
protected char[]protectedArray()

        throw new ReadOnlyBufferException();
    
protected intprotectedArrayOffset()

        throw new ReadOnlyBufferException();
    
protected booleanprotectedHasArray()

        return false;
    
public java.nio.CharBufferput(char c)

        throw new ReadOnlyBufferException();
    
public java.nio.CharBufferput(int index, char c)

        throw new ReadOnlyBufferException();
    
public final java.nio.CharBufferput(char[] src, int off, int len)

        throw new ReadOnlyBufferException();
    
public final java.nio.CharBufferput(java.nio.CharBuffer src)

        throw new ReadOnlyBufferException();
    
public java.nio.CharBufferput(java.lang.String src, int start, int end)

        if ((start < 0 ) || (end < 0) || (long)start + (long)end > src.length()) {
            throw new IndexOutOfBoundsException();
        }
        throw new ReadOnlyBufferException();
    
public java.nio.CharBufferslice()

        return new ReadOnlyCharArrayBuffer(remaining(), backingArray, offset
                + position);