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.p2p.scribe
Class Topic

    java.lang.Object
      rice.p2p.scribe.Topic

All Implemented Interfaces:
  java.io.Serializable

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

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

Field Summary
`protected Id` | `id` The Id to which this topic is mapped

Constructor Summary
`Topic(Id id)` Constructor which takes an Id for this topic
`Topic(IdFactory factory, java.lang.String name)` Constructor which takes a name for this topic

Method Summary
`boolean` | `equals(java.lang.Object o)` Returns whether this is equal to o or not
`Id` | `getId()` Returns the Id to which this topic is mapped
`static Id` | `getId(IdFactory factory, java.lang.String name)` Returns the Id to which the string is mapped
`int` | `hashCode()` Returns the hashCode for this topic
`java.lang.String` | `toString()` Returns a String representation of this topic

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

Field Detail

### id

    protected Id id

  The Id to which this topic is mapped

Constructor Detail

### Topic

    public Topic(Id id)

  Constructor which takes an Id for this topic

Parameters:
  `id` - The Id for this topic

### Topic

    public Topic(IdFactory factory,
                 java.lang.String name)

  Constructor which takes a name for this topic

Parameters:
  `factory` - The factory to use when creating the id
  `name` - The name for this topic

Method Detail

### getId

    public Id getId()

  Returns the Id to which this topic is mapped

  Returns:
    The id to which this topic is mapped

### equals

    public boolean equals(java.lang.Object o)

  Returns whether this is equal to o or not

  Parameters:
    `o` - The object to compare to
  Returns:
    Whether or not they are equal

### hashCode

    public int hashCode()

  Returns the hashCode for this topic

  Returns:
    The hashcode for this topic

### toString

    public java.lang.String toString()

  Returns a String representation of this topic

  Returns:
    A String representation of this topic

### getId

    public static Id getId(IdFactory factory,
                           java.lang.String name)

  Returns the Id to which the string is mapped

  Parameters:
    `factory` - The factory to use when creating the id
    `name` - The string to map
  Returns:
    The id to which this string is mapped

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.