com.hp.hpl.jena.rdf.model
Class AnonId

java.lang.Object
  extended by com.hp.hpl.jena.rdf.model.AnonId

public class AnonId
extends Object

Create a new id for an anonymous node.

This id is guaranteed to be unique on this machine.

Version:
$Name: $ $Revision: 1.5 $ $Date: 2004/03/19 07:40:07 $
Author:
bwm

Constructor Summary
AnonId()
          Creates new AnonId.
AnonId(String id)
          Create a new AnonId from the string argument supplied
 
Method Summary
 boolean equals(Object o)
          Test whether two id's are the same
 int hashCode()
          return a hashcode for this id
 String toString()
          return a string representation of the id
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AnonId

public AnonId()
Creates new AnonId. Normally this id is guaranteed to be unique on this machine: it is time-dependant. However, sometimes [incorrect] code is sensitive to bnode ordering and produces bizarre bugs (both Dave and Chris have been bitten by this, as have some users, I think). Hence the disableBNodeUIDGeneration flag, which allows bnode IDs to be predictable.


AnonId

public AnonId(String id)
Create a new AnonId from the string argument supplied

Parameters:
id - A string representation of the id to be created.
Method Detail

equals

public boolean equals(Object o)
Test whether two id's are the same

Overrides:
equals in class Object
Parameters:
o - the object to be compared
Returns:
true if and only if the two id's are the same

toString

public String toString()
return a string representation of the id

Overrides:
toString in class Object
Returns:
a string representation of the id

hashCode

public int hashCode()
return a hashcode for this id

Overrides:
hashCode in class Object
Returns:
the hash code


Copyright © 2000, 2001, 2002, 2003, 2004 Hewlett-Packard Development Company, LP