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 ScribeImpl.TopicManager

    java.lang.Object
      rice.p2p.scribe.ScribeImpl.TopicManager

All Implemented Interfaces:
  Destructable, java.util.Observer

Enclosing class:
  ScribeImpl

public class ScribeImpl.TopicManager
extends java.lang.Object
implements java.util.Observer, Destructable

Class which keeps track of a given topic

Version:
  $Id: ScribeImpl.java 2885 2006-01-05 12:20:54Z jeffh $
Author:
  amislove

Field Summary
`protected java.util.Vector` | `children` DESCRIBE THE FIELD
`protected java.util.Vector` | `clients` DESCRIBE THE FIELD
`protected NodeHandle` | `parent` DESCRIBE THE FIELD
`protected Id[]` | `pathToRoot` The current path to the root for this node
`protected Topic` | `topic` DESCRIBE THE FIELD

Constructor Summary
`protected` | `ScribeImpl.TopicManager(Topic topic)` Constructor for TopicManager.
`` | `ScribeImpl.TopicManager(Topic topic, NodeHandle child)` Constructor for TopicManager.
`` | `ScribeImpl.TopicManager(Topic topic, ScribeClient client)` Constructor for TopicManager.

Method Summary
`void` | `addChild(NodeHandle child)` Adds a feature to the Child attribute of the TopicManager object
`void` | `addClient(ScribeClient client)` Adds a feature to the Client attribute of the TopicManager object
`boolean` | `containsClient(ScribeClient client)` Returns whether or not this topic manager contains the given client.
`void` | `destroy()` DESCRIBE THE METHOD
`NodeHandle[]` | `getChildren()` Gets the Children attribute of the TopicManager object
`ScribeClient[]` | `getClients()` Gets the Clients attribute of the TopicManager object
`NodeHandle` | `getParent()` Gets the Parent attribute of the TopicManager object
`Id[]` | `getPathToRoot()` Gets the PathToRoot attribute of the TopicManager object
`Topic` | `getTopic()` Gets the topic of the TopicManager object
`boolean` | `removeChild(NodeHandle child)` DESCRIBE THE METHOD
`boolean` | `removeClient(ScribeClient client)` DESCRIBE THE METHOD
`void` | `setParent(NodeHandle handle)` Sets the Parent attribute of the TopicManager object
`void` | `setPathToRoot(Id[] pathToRoot)` Sets the PathToRoot attribute of the TopicManager object
`void` | `update(java.util.Observable o, java.lang.Object arg)` DESCRIBE THE METHOD

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

Field Detail

### topic

    protected Topic topic

  DESCRIBE THE FIELD

### pathToRoot

    protected Id[] pathToRoot

  The current path to the root for this node

### clients

    protected java.util.Vector clients

  DESCRIBE THE FIELD

### children

    protected java.util.Vector children

  DESCRIBE THE FIELD

### parent

    protected NodeHandle parent

  DESCRIBE THE FIELD

Constructor Detail

### ScribeImpl.TopicManager

    public ScribeImpl.TopicManager(Topic topic,
                                   ScribeClient client)

  Constructor for TopicManager.

Parameters:
  `topic` - DESCRIBE THE PARAMETER
  `client` - DESCRIBE THE PARAMETER

### ScribeImpl.TopicManager

    public ScribeImpl.TopicManager(Topic topic,
                                   NodeHandle child)

  Constructor for TopicManager.

Parameters:
  `topic` - DESCRIBE THE PARAMETER
  `child` - DESCRIBE THE PARAMETER

### ScribeImpl.TopicManager

    protected ScribeImpl.TopicManager(Topic topic)

  Constructor for TopicManager.

Parameters:
  `topic` - DESCRIBE THE PARAMETER

Method Detail

### getTopic

    public Topic getTopic()

  Gets the topic of the TopicManager object

  Returns:
    The Parent value

### getParent

    public NodeHandle getParent()

  Gets the Parent attribute of the TopicManager object

  Returns:
    The Parent value

### getClients

    public ScribeClient[] getClients()

  Gets the Clients attribute of the TopicManager object

  Returns:
    The Clients value

### getChildren

    public NodeHandle[] getChildren()

  Gets the Children attribute of the TopicManager object

  Returns:
    The Children value

### getPathToRoot

    public Id[] getPathToRoot()

  Gets the PathToRoot attribute of the TopicManager object

  Returns:
    The PathToRoot value

### setPathToRoot

    public void setPathToRoot(Id[] pathToRoot)

  Sets the PathToRoot attribute of the TopicManager object

  Parameters:
    `pathToRoot` - The new PathToRoot value

### setParent

    public void setParent(NodeHandle handle)

  Sets the Parent attribute of the TopicManager object

  Parameters:
    `handle` - The new Parent value

### containsClient

    public boolean containsClient(ScribeClient client)

  Returns whether or not this topic manager contains the given client.

  Parameters:
    `client` - The client in question
  Returns:
    Whether or not this manager contains the client

### update

    public void update(java.util.Observable o,
                       java.lang.Object arg)

  DESCRIBE THE METHOD

  Specified by:
    `update` in interface `java.util.Observer`
  Parameters:
    `o` - DESCRIBE THE PARAMETER
    `arg` - DESCRIBE THE PARAMETER

### addClient

    public void addClient(ScribeClient client)

  Adds a feature to the Client attribute of the TopicManager object

  Parameters:
    `client` - The feature to be added to the Client attribute

### removeClient

    public boolean removeClient(ScribeClient client)

  DESCRIBE THE METHOD

  Parameters:
    `client` - DESCRIBE THE PARAMETER
  Returns:
    DESCRIBE THE RETURN VALUE

### addChild

    public void addChild(NodeHandle child)

  Adds a feature to the Child attribute of the TopicManager object

  Parameters:
    `child` - The feature to be added to the Child attribute

### removeChild

    public boolean removeChild(NodeHandle child)

  DESCRIBE THE METHOD

  Parameters:
    `child` - DESCRIBE THE PARAMETER
  Returns:
    DESCRIBE THE RETURN VALUE

### destroy

    public void destroy()

  DESCRIBE THE METHOD

  Specified by:
    `destroy` in interface `Destructable`

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.