Main Page | Class Hierarchy | Class List | File List | Class Members | Related Pages

glite::rgma::ConsumerImpl Class Reference

#include <ConsumerImpl.h>

Inheritance diagram for glite::rgma::ConsumerImpl:

glite::rgma::Consumer glite::rgma::ResourceImpl glite::rgma::Resource List of all members.

Public Member Functions

 ConsumerImpl (TimeInterval terminationInterval, std::string selectStatement, QueryProperties queryProperties) throw (RemoteException, RGMAException)
 ConsumerImpl (ResourceEndpoint &resourceEndpoint) throw (RemoteException, RGMAException)
bool isExecuting () throw (UnknownResourceException, RemoteException, RGMAException)
void abort () throw (UnknownResourceException, RemoteException)
int count () throw (UnknownResourceException, RemoteException)
bool hasAborted () throw (UnknownResourceException, RemoteException)
void pop (ResultSet &results, int maxCount) throw (UnknownResourceException, RemoteException, RGMAException)
void popAll (ResultSet &results) throw (UnknownResourceException, RemoteException, RGMAException)
void start (TimeInterval timeout) throw (UnknownResourceException, RemoteException, RGMAException)
void start (TimeInterval timeout, ResourceEndpointList producers) throw (UnknownResourceException, RemoteException, RGMAException)

Detailed Description

Implementation of a consumer


Member Function Documentation

void glite::rgma::ConsumerImpl::abort  )  throw (UnknownResourceException, RemoteException) [virtual]
 

Aborts the current query.

Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.

Implements glite::rgma::Consumer.

int glite::rgma::ConsumerImpl::count  )  throw (UnknownResourceException, RemoteException) [virtual]
 

Returns the number of tuples that are available to pop.

Deprecated:
Returns:
The number of tuples that are available to pop.
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.

Implements glite::rgma::Consumer.

bool glite::rgma::ConsumerImpl::hasAborted  )  throw (UnknownResourceException, RemoteException) [virtual]
 

Determines if the last query has aborted.

Returns:
True if the query was aborted and didn't stop of its own accord.
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.

Implements glite::rgma::Consumer.

bool glite::rgma::ConsumerImpl::isExecuting  )  throw (UnknownResourceException, RemoteException, RGMAException) [virtual]
 

Determines whether the last query is still executing.

Deprecated:
Use ResultSet::endOfResults
Returns:
True if the query is still executing.
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.

Implements glite::rgma::Consumer.

void glite::rgma::ConsumerImpl::pop ResultSet results,
int  maxCount
throw (UnknownResourceException, RemoteException, RGMAException) [virtual]
 

Retrieves at most maxCount tuples from the consumer that it has received from producers.

Parameters:
maxCount The maximum number of tuples to retrieve.
results a resultSet object to be populated with the results of the pop action
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.
RGMAException If the query hasn't been started.

Implements glite::rgma::Consumer.

void glite::rgma::ConsumerImpl::popAll ResultSet results  )  throw (UnknownResourceException, RemoteException, RGMAException) [virtual]
 

Retrieves all data from the consumer that it has received from producers.

Deprecated:
Parameters:
results a resultSet object to be populated with the results of the popAll action
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.
RGMAException If the query hasn't been started.

Implements glite::rgma::Consumer.

void glite::rgma::ConsumerImpl::start TimeInterval  timeout,
ResourceEndpointList  producers
throw (UnknownResourceException, RemoteException, RGMAException) [virtual]
 

Starts this consumer's query, contacting the specified producers, terminating after the specified time interval. There is no infinite interval; just set the timeout to be very large if this is the effect you want (e.g. 1000 days).

Parameters:
timeout Time interval after which the query will automatically be aborted.
producers List of producers to contact.
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.
RGMAException If the query is currently executing.

Implements glite::rgma::Consumer.

void glite::rgma::ConsumerImpl::start TimeInterval  timeout  )  throw (UnknownResourceException, RemoteException, RGMAException) [virtual]
 

Starts this consumer's query, using the mediator to locate producers, terminating after the specified time interval. There is no infinite interval; just set the timeout to be very large if this is the effect you want (e.g. 1000 days).

Parameters:
timeout Time interval after which the query will automatically be aborted.
Exceptions:
UnknownResourceException If the consumer resource is not found.
RemoteException If the service could not be contacted.
RGMAException If the query is currently executing.

Implements glite::rgma::Consumer.


The documentation for this class was generated from the following files:
Generated on Wed May 17 17:48:18 2006 for glite-rgma-api-cpp by doxygen 1.3.5