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

## rice.pastry
Class NodeId

    java.lang.Object
      rice.pastry.Id
          rice.pastry.NodeId

All Implemented Interfaces:
  java.lang.Comparable, Id, java.io.Serializable

public class NodeId
extends Id

Represents a Pastry identifier for a node.

Version:
  $Id: NodeId.java 2302 2005-03-11 00:58:26Z jeffh $
Author:
  Peter Druschel, Alan Mislove
See Also:
  Serialized Form

Nested Class Summary

Nested classes inherited from class rice.pastry.Id
`Id.Distance`

Field Summary
`static int` | `nodeIdBitLength` This is the bit length of the node ids.

Fields inherited from class rice.pastry.Id
`Half, IdBitLength, NegOne, nlen, Null, One`

Method Summary
`static NodeId` | `buildNodeId()` Constructor.
`static NodeId` | `buildNodeId(byte[] material)` Constructor.
`static NodeId` | `buildNodeId(int[] material)` Constructor.

Methods inherited from class rice.pastry.Id
`add, addToId, blit, blit, build, build, build, build, build, checkBit, clockwise, clockwise, compareTo, copy, distance, distanceFromId, equals, equals, getAlternateId, getByteArrayLength, getCCW, getCW, getDigit, getDomainPrefix, hashCode, indexOfMSDB, indexOfMSDD, isBetween, isBetween, longDistance, longDistanceFromId, makeRandomId, makeRandomId, numDigits, resolve, toByteArray, toByteArray, toString, toStringBare, toStringFull, trans, trans, trans`

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

Field Detail

### nodeIdBitLength

    public static final int nodeIdBitLength

  This is the bit length of the node ids. If it is n, then there are 2^n different Pastry nodes. We currently assume that it is divisible by 32.

  See Also:
    Constant Field Values

Method Detail

### buildNodeId

    public static NodeId buildNodeId(int[] material)

  Constructor.

  Parameters:
    `material` - an array of length at least IdBitLength/32 containing raw Id material.
  Returns:
    DESCRIBE THE RETURN VALUE

### buildNodeId

    public static NodeId buildNodeId(byte[] material)

  Constructor.

  Parameters:
    `material` - an array of length at least IdBitLength/8 containing raw Id material.
  Returns:
    DESCRIBE THE RETURN VALUE

### buildNodeId

    public static NodeId buildNodeId()

  Constructor. It constructs a new Id with a value of 0 for all bits.

  Returns:
    DESCRIBE THE RETURN VALUE

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

Copyright © 2001-2005 - Rice Pastry.