com.gigaspaces.grid.master
Class Identity

java.lang.Object
  extended by com.gigaspaces.grid.master.Identity
All Implemented Interfaces:
java.io.Serializable

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

The Identity shall provide a universally unique identifier for jobs and tasks within a grid.

See Also:
Serialized Form

Field Summary
protected  int _hashCode
           
protected  net.jini.id.Uuid _id
           
 
Constructor Summary
Identity()
          Creates a new Identity with the 128-bit value.
Identity(java.lang.String id)
          Creates a new Identity with the 128-bit value represented by the specified string.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Compares the specified object with this Identity for equality.
 net.jini.id.Uuid getUuid()
          Get the unique identifier
 int hashCode()
          Returns the hash code value for this Identity.
static Identity newInstance()
           
 java.lang.String toString()
          Return a String representation of the Identity object
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

_id

protected net.jini.id.Uuid _id

_hashCode

protected int _hashCode
Constructor Detail

Identity

public Identity()
Creates a new Identity with the 128-bit value.


Identity

public Identity(java.lang.String id)
Creates a new Identity with the 128-bit value represented by the specified string.

Method Detail

newInstance

public static Identity newInstance()

getUuid

public net.jini.id.Uuid getUuid()
Get the unique identifier

Returns:
The Uuid

equals

public boolean equals(java.lang.Object obj)
Compares the specified object with this Identity for equality.

Overrides:
equals in class java.lang.Object
Parameters:
obj - - The object to compare this Identity
Returns:
true if the given object is equivalent to this one, and false otherwise

hashCode

public int hashCode()
Returns the hash code value for this Identity.

Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Return a String representation of the Identity object

Overrides:
toString in class java.lang.Object


Copyright (c) 2007 GigaSpaces Technologies, Inc.
All Rights Reserved.