org.jfree.report
Class Anchor

java.lang.Object
  |
  +--org.jfree.report.Anchor

public class Anchor
extends java.lang.Object
implements java.io.Serializable

An anchor is a possible target for external hyperlinks.

In HTML anchors would be produced by using <a name="anchorname">. This class is immutable.

Author:
Thomas Morgner
See Also:
AnchorElement, Serialized Form

Constructor Summary
Anchor(java.lang.String name)
          Creates a new anchor with the given name.
 
Method Summary
 boolean equals(java.lang.Object o)
          Checks, whether the given object is an anchor with the same name as this one.
 java.lang.String getName()
          Returns the name of the anchor.
 int hashCode()
          Computes a hashcode for this anchor.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Anchor

public Anchor(java.lang.String name)
Creates a new anchor with the given name.
Parameters:
name - the name of the anchor.
Throws:
java.lang.NullPointerException - if the given name is null.
Method Detail

getName

public java.lang.String getName()
Returns the name of the anchor.
Returns:
the name

equals

public boolean equals(java.lang.Object o)
Checks, whether the given object is an anchor with the same name as this one.
Overrides:
equals in class java.lang.Object
Parameters:
o - the other object.
Returns:
true, if the object is equal to this one, false otherwise.

hashCode

public int hashCode()
Computes a hashcode for this anchor.
Overrides:
hashCode in class java.lang.Object
Returns:
the hashcode.