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.apache.batik.apps.svgbrowser
Class LocalHistory

    java.lang.Object
      org.apache.batik.apps.svgbrowser.LocalHistory

    public class LocalHistory

extends Object

This class represents an history of the files visited by a single browser frame.

Nested Class Summary
`protected class` | `LocalHistory.RadioListener` To listen to the radio buttons.

Field Summary
`protected ActionListener` | `actionListener` The action listener.
`protected static int` | `BACK_PENDING_STATE`
`protected int` | `currentURI` The index of the current URI.
`protected static int` | `FORWARD_PENDING_STATE`
`protected ButtonGroup` | `group` The button group for the menu items.
`protected int` | `index` The index of the first history item in this menu.
`protected JMenu` | `menu` The menu which contains the history.
`protected static int` | `RELOAD_PENDING_STATE`
`protected static int` | `STABLE_STATE`
`protected int` | `state` The current state.
`protected JSVGViewerFrame` | `svgFrame` The frame to manage.
`protected List` | `visitedURIs` The visited URIs.

Constructor Summary
`LocalHistory(JMenuBar mb, JSVGViewerFrame svgFrame)` Creates a new local history.

Method Summary
`void` | `back()` Goes back of one position in the history.
`boolean` | `canGoBack()` Whether it is possible to go back.
`boolean` | `canGoForward()` Whether it is possible to go forward.
`void` | `forward()` Goes forward of one position in the history.
`void` | `reload()` Reloads the current document.
`protected void` | `update()` Updates the state of this history.
`void` | `update(String uri)` Updates the history.

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

Field Detail

### svgFrame

    protected JSVGViewerFrame svgFrame

  The frame to manage.

### menu

    protected JMenu menu

  The menu which contains the history.

### index

    protected int index

  The index of the first history item in this menu.

### visitedURIs

    protected List visitedURIs

  The visited URIs.

### currentURI

    protected int currentURI

  The index of the current URI.

### group

    protected ButtonGroup group

  The button group for the menu items.

### actionListener

    protected ActionListener actionListener

  The action listener.

### state

    protected int state

  The current state.

### STABLE_STATE

    protected static final int STABLE_STATE

See Also:
  Constant Field Values

### BACK_PENDING_STATE

    protected static final int BACK_PENDING_STATE

See Also:
  Constant Field Values

### FORWARD_PENDING_STATE

    protected static final int FORWARD_PENDING_STATE

See Also:
  Constant Field Values

### RELOAD_PENDING_STATE

    protected static final int RELOAD_PENDING_STATE

See Also:
  Constant Field Values

Constructor Detail

### LocalHistory

    public LocalHistory(JMenuBar mb,
                        JSVGViewerFrame svgFrame)

  Creates a new local history.

  Parameters:
    `mb` - The menubar used to display the history. It must contain one '@@@' item used as marker to place the history items.
    `svgFrame` - The frame to manage.

Method Detail

### back

    public void back()

  Goes back of one position in the history. Assumes that `canGoBack()` is true.

### canGoBack

    public boolean canGoBack()

  Whether it is possible to go back.

### forward

    public void forward()

  Goes forward of one position in the history. Assumes that `canGoForward()` is true.

### canGoForward

    public boolean canGoForward()

  Whether it is possible to go forward.

### reload

    public void reload()

  Reloads the current document.

### update

    public void update(String uri)

  Updates the history.

  Parameters:
    `uri` - The URI of the document just loaded.

### update

    protected void update()

  Updates the state of this history.

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 Apache Software Foundation. All Rights Reserved.