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

## info.bioinfweb.treegraph.document
Class Legends

    java.lang.Object
      info.bioinfweb.treegraph.document.Legends

    public class Legends

extends Object

Field Summary
`private static int` | `CAPACITY`
`private static int` | `CAPACITY_INCREMENT`
`private Vector<Legend>` | `list`
`private Tree` | `tree`

Constructor Summary
`Legends(Tree tree)`

Method Summary
`void` | `clear()`
`boolean` | `contains(Legend l)`
`Legend` | `get(int index)`
`Tree` | `getTree()`
`int` | `indexOf(Legend l)`
`int` | `insert(Legend l)` Inserts the specified legend to the list and calls `l.setLegends(this)`.
`boolean` | `isEmpty()`
`int` | `reinsert(Legend l)` Reinserts a legend to ensure the correct order of the stored legends.
`boolean` | `remove(Legend l)`
`int` | `size()`
`
`<T> T[]`
` | `toArray(T[] arr)`

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

Field Detail

### CAPACITY

    private static final int CAPACITY

See Also:
  Constant Field Values

### CAPACITY_INCREMENT

    private static final int CAPACITY_INCREMENT

See Also:
  Constant Field Values

### tree

    private Tree tree

### list

    private Vector<Legend> list

Constructor Detail

### Legends

    public Legends(Tree tree)

Method Detail

### getTree

    public Tree getTree()

### insert

    public int insert(Legend l)

  Inserts the specified legend to the list and calls `l.setLegends(this)`.

  Parameters:
    `l` - the legend to be inserted
  Returns:
    the postion where the legend was inserted

### reinsert

    public int reinsert(Legend l)

  Reinserts a legend to ensure the correct order of the stored legends. This method should be called if the position of a legend changes.

  Parameters:
    `l` - the legend to reinsert
  Returns:
    the new position of the legend or -1 if the legend was not present in the first case.

### clear

    public void clear()

### contains

    public boolean contains(Legend l)

### get

    public Legend get(int index)

### indexOf

    public int indexOf(Legend l)

### isEmpty

    public boolean isEmpty()

### remove

    public boolean remove(Legend l)

### size

    public int size()

### toArray

    public <T> T[] toArray(T[] arr)

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