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.mortbay.io
Class BufferCache

    java.lang.Object
      org.mortbay.io.BufferCache

Direct Known Subclasses:
  Ajp13RequestHeaders, Ajp13ResponseHeaders, HttpHeaders, HttpHeaderValues

    public class BufferCache

extends java.lang.Object

Stores a collection of `BufferCache.CachedBuffer` objects. Buffers are stored in an ordered collection and can retreived by index or value

Author:
  gregw

Nested Class Summary
`static class` | `BufferCache.CachedBuffer`

Constructor Summary
`BufferCache()`

Method Summary
`BufferCache.CachedBuffer` | `add(java.lang.String value, int ordinal)` Add a buffer to the cache at the specified index.
`BufferCache.CachedBuffer` | `get(Buffer buffer)`
`BufferCache.CachedBuffer` | `get(int ordinal)`
`BufferCache.CachedBuffer` | `get(java.lang.String value)`
`BufferCache.CachedBuffer` | `getBest(byte[] value, int offset, int maxLength)`
`int` | `getOrdinal(Buffer buffer)`
`Buffer` | `lookup(Buffer buffer)`
`Buffer` | `lookup(java.lang.String value)`
`java.lang.String` | `toString()`
`java.lang.String` | `toString(Buffer buffer)`

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

Constructor Detail

### BufferCache

    public BufferCache()

Method Detail

### add

    public BufferCache.CachedBuffer add(java.lang.String value,
                                        int ordinal)

  Add a buffer to the cache at the specified index.

  Parameters:
    `value` - The content of the buffer.

### get

    public BufferCache.CachedBuffer get(int ordinal)

### get

    public BufferCache.CachedBuffer get(Buffer buffer)

### get

    public BufferCache.CachedBuffer get(java.lang.String value)

### lookup

    public Buffer lookup(Buffer buffer)

### getBest

    public BufferCache.CachedBuffer getBest(byte[] value,
                                            int offset,
                                            int maxLength)

### lookup

    public Buffer lookup(java.lang.String value)

### toString

    public java.lang.String toString(Buffer buffer)

### getOrdinal

    public int getOrdinal(Buffer buffer)

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

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 © 1995-2010 Mort Bay Consulting. All Rights Reserved.