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.crosswire.bibledesktop.display.proxy
Class ProxyBookDataDisplay

    java.lang.Object
      org.crosswire.bibledesktop.display.proxy.ProxyBookDataDisplay

All Implemented Interfaces:
  BookDataDisplay

Direct Known Subclasses:
  ScrolledBookDataDisplay

    public class ProxyBookDataDisplay

extends Object
implements BookDataDisplay

An implementation of BookDataDisplay that simply proxies all requests to an underlying BookDataDisplay.

Useful for chaining a few BookDataDisplays together to add functionallity component by component.

Author:
  Joe Walker [joe at eireneh dot com]
See Also:
  `for license details. The copyright to this program is held by it's authors.`

Field Summary
`private BookDataDisplay` | `proxy` The component to which we proxy

Constructor Summary
`ProxyBookDataDisplay(BookDataDisplay proxy)` Setup the proxy

Method Summary
`void` | `addURLEventListener(URLEventListener listener)` Add a listener for when someone clicks on a browser 'link'
`void` | `copy()` Copy the selection to the clipboard
`Book` | `getBook()` Accessor for the Book used in the current display, or null if we are not displaying anything.
`Component` | `getComponent()` Accessor for the Swing component
`Key` | `getKey()` The Book Key that we are displaying, or null if we are not displaying anything
`protected BookDataDisplay` | `getProxy()` Accessor for the proxy
`void` | `refresh()` Cause the BookData to be re-displayed.
`void` | `removeURLEventListener(URLEventListener listener)` Remove a listener for when someone clicks on a browser 'link'
`void` | `setBookData(Book book, Key key)` Set the BookData to be displayed.
`String` | `toString()`

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

Field Detail

### proxy

    private BookDataDisplay proxy

  The component to which we proxy

Constructor Detail

### ProxyBookDataDisplay

    public ProxyBookDataDisplay(BookDataDisplay proxy)

  Setup the proxy

Method Detail

### getProxy

    protected BookDataDisplay getProxy()

  Accessor for the proxy

  Returns:
    Returns the proxy.

### addURLEventListener

    public void addURLEventListener(URLEventListener listener)

  Description copied from interface: `BookDataDisplay`
  Add a listener for when someone clicks on a browser 'link'

  Specified by:
    `addURLEventListener` in interface `BookDataDisplay`
  Parameters:
    `listener` - The listener to add

### removeURLEventListener

    public void removeURLEventListener(URLEventListener listener)

  Description copied from interface: `BookDataDisplay`
  Remove a listener for when someone clicks on a browser 'link'

  Specified by:
    `removeURLEventListener` in interface `BookDataDisplay`
  Parameters:
    `listener` - The listener to remove

### copy

    public void copy()

  Description copied from interface: `BookDataDisplay`
  Copy the selection to the clipboard

  Specified by:
    `copy` in interface `BookDataDisplay`

### getComponent

    public Component getComponent()

  Description copied from interface: `BookDataDisplay`
  Accessor for the Swing component

  Specified by:
    `getComponent` in interface `BookDataDisplay`

### setBookData

    public void setBookData(Book book,
                            Key key)

  Description copied from interface: `BookDataDisplay`
  Set the BookData to be displayed. The data to be displayed is specified as a book and key rather than the more obvious BookData (the result of reading a book using a key) since some displays may wish so split up the display and only look up smaller sections at a time.

  Specified by:
    `setBookData` in interface `BookDataDisplay`
  Parameters:
    `book` - The Book to read data from
    `key` - The key to read from the given book

### refresh

    public void refresh()

  Description copied from interface: `BookDataDisplay`
  Cause the BookData to be re-displayed.

  Specified by:
    `refresh` in interface `BookDataDisplay`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

### getKey

    public Key getKey()

  Description copied from interface: `BookDataDisplay`
  The Book Key that we are displaying, or null if we are not displaying anything

  Specified by:
    `getKey` in interface `BookDataDisplay`
  Returns:
    The current key

### getBook

    public Book getBook()

  Description copied from interface: `BookDataDisplay`
  Accessor for the Book used in the current display, or null if we are not displaying anything.

  Specified by:
    `getBook` in interface `BookDataDisplay`
  Returns:
    The current book

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