org.ccnx.ccn.test.profiles.versioning.VersioningHelper.SinkHandle Class Reference

Track interests. More...

Inheritance diagram for org.ccnx.ccn.test.profiles.versioning.VersioningHelper.SinkHandle:

org.ccnx.ccn.CCNHandle org.ccnx.ccn.CCNBase

List of all members.

Public Member Functions

synchronized void expressInterest (Interest interest, CCNContentHandler handler) throws IOException
 Query, or express an interest in particular content.
synchronized void cancelInterest (Interest interest, CCNContentHandler handler)
 Cancel this interest.

Static Public Member Functions

static SinkHandle open (KeyManager keyManager) throws IOException
 Create a new CCNHandle, opening a new connection to the CCN network, and specifying the KeyManager it should use.
static SinkHandle open (CCNHandle handle) throws IOException

Public Attributes

final ArrayList< Interestinterests = new ArrayList<Interest>()
final ConditionLong count = new ConditionLong(0)
final ConditionLong total_count = new ConditionLong(0)

Protected Member Functions

 SinkHandle (KeyManager keyManager) throws IOException


Detailed Description

Track interests.

Member Function Documentation

static SinkHandle org.ccnx.ccn.test.profiles.versioning.VersioningHelper.SinkHandle.open ( KeyManager  keyManager  )  throws IOException [static]

Create a new CCNHandle, opening a new connection to the CCN network, and specifying the KeyManager it should use.

Particularly useful in testing, to run as if you were a different "user", with a different collection of keys.

Parameters:
keyManager the KeyManager to use
Returns:
the CCNHandle
Exceptions:
IOException 

Reimplemented from org.ccnx.ccn.CCNHandle.

synchronized void org.ccnx.ccn.test.profiles.versioning.VersioningHelper.SinkHandle.expressInterest ( Interest  interest,
CCNContentHandler  handler 
) throws IOException

Query, or express an interest in particular content.

This request is sent out over the CCN to other nodes. On any results, the callbackHandler if given, is notified. Results may also be cached in a local repository for later retrieval by get(). Get and expressInterest could be implemented as a single function that might return some content immediately and others by callback; we separate the two for now to simplify the interface.

Pass it on to the CCNInterestManager to forward to the network. Also express it to the repositories we manage, particularly the primary. Each might generate their own CCNQueryDescriptor, so we need to group them together.

Implements org.ccnx.ccn.CCNBase.

synchronized void org.ccnx.ccn.test.profiles.versioning.VersioningHelper.SinkHandle.cancelInterest ( Interest  interest,
CCNContentHandler  handler 
)

Cancel this interest.

Parameters:
interest 
handler Used to distinguish the same interest requested by more than one listener.

Reimplemented from org.ccnx.ccn.CCNHandle.


The documentation for this class was generated from the following file:

Generated on Thu Feb 16 00:45:09 2012 for Content-Centric Networking in Java by  doxygen 1.5.6