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
Interface ScribeMultiClient

All Superinterfaces:
  ScribeClient

All Known Implementing Classes:
  ScribeImpl.ScribeClientConverter

    public interface ScribeMultiClient

extends ScribeClient

The new interface for scribe as of FreePastry 2.1. Handles multiple concurrent Joins/Failures.

Author:
  Jeff Hoye

Method Summary
`boolean` | `anycast(Topic topic, ScribeContent content)` This method is invoked when an anycast is received for a topic which this client is interested in.
`void` | `childAdded(Topic topic, NodeHandle child)` Informs this client that a child was added to a topic in which it was interested in.
`void` | `childRemoved(Topic topic, NodeHandle child)` Informs this client that a child was removed from a topic in which it was interested in.
`void` | `deliver(Topic topic, ScribeContent content)` This method is invoked when a message is delivered for a topic this client is interested in.
`void` | `subscribeFailed(java.util.Collection<Topic> topics)` Informs the client that a subscribe on the given topic failed - the client should retry the subscribe or take appropriate action.
`void` | `subscribeFailed(Topic topic)` Deprecated. use subscribeFailed(Collection topics)
`void` | `subscribeSuccess(java.util.Collection<Topic> topics)` Informs the client that a subscribe on the given topic failed - the client should retry the subscribe or take appropriate action.

Method Detail

### anycast

    boolean anycast(Topic topic,
                    ScribeContent content)

  This method is invoked when an anycast is received for a topic which this client is interested in. The client should return whether or not the anycast should continue.

  Specified by:
    `anycast` in interface `ScribeClient`
  Parameters:
    `topic` - The topic the message was anycasted to
    `content` - The content which was anycasted
  Returns:
    Whether or not the anycast should continue, true if we will accept the anycast

### deliver

    void deliver(Topic topic,
                 ScribeContent content)

  This method is invoked when a message is delivered for a topic this client is interested in.

  Specified by:
    `deliver` in interface `ScribeClient`
  Parameters:
    `topic` - The topic the message was published to
    `content` - The content which was published

### childAdded

    void childAdded(Topic topic,
                    NodeHandle child)

  Informs this client that a child was added to a topic in which it was interested in.

  Specified by:
    `childAdded` in interface `ScribeClient`
  Parameters:
    `topic` - The topic to unsubscribe from
    `child` - The child that was added

### childRemoved

    void childRemoved(Topic topic,
                      NodeHandle child)

  Informs this client that a child was removed from a topic in which it was interested in.

  Specified by:
    `childRemoved` in interface `ScribeClient`
  Parameters:
    `topic` - The topic to unsubscribe from
    `child` - The child that was removed

### subscribeFailed

    void subscribeFailed(Topic topic)

  Deprecated. use subscribeFailed(Collection topics)

  Informs the client that a subscribe on the given topic failed - the client should retry the subscribe or take appropriate action.

  Specified by:
    `subscribeFailed` in interface `ScribeClient`
  Parameters:
    `topic` - The topic which the subscribe failed on

### subscribeFailed

    void subscribeFailed(java.util.Collection<Topic> topics)

  Informs the client that a subscribe on the given topic failed - the client should retry the subscribe or take appropriate action.

  Parameters:
    `topic` - The topic which the subscribe failed on

### subscribeSuccess

    void subscribeSuccess(java.util.Collection<Topic> topics)

  Informs the client that a subscribe on the given topic failed - the client should retry the subscribe or take appropriate action.

  Parameters:
    `topic` - The topic which the subscribe failed on

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.