Project: engagement_recognition

License: BSD

Dependencies:

Used by: None

All Packages

ServiceResponse Class Reference

#include <service_response.h>

Inheritance diagram for ServiceResponse:

List of all members.

Public Member Functions

virtual bool isCycle ()
virtual bool isFailed ()
virtual bool isSucceeded ()
 ServiceResponse ()
virtual void set (ServiceResponse resp)
virtual void setCycle ()
virtual void setFailed ()
virtual void setSucceeded ()

Static Public Member Functions

static ServiceResponse cycle ()
static ServiceResponse failed ()
static ServiceResponse succeeded ()

Protected Member Functions

 ServiceResponse (int status)

Protected Attributes

int status_

Static Protected Attributes

static const int CYCLE = 0
static const int FAILED = 2
static const int SUCCEEDED = 1

Detailed Description

The ServiceResponse class is responsible for keeping track of the status of a service response. It can have a status of: cylce, succeeded, or failed.

Author:
Brett Ponsler (brett (at) wpi (dot) edu)

Definition at line 44 of file service_response.h.


Constructor & Destructor Documentation

ServiceResponse::ServiceResponse ( int  status  )  [protected]

Create a service response with the given status.

Parameters:
status The status

Definition at line 42 of file service_response.cpp.

ServiceResponse::ServiceResponse (  ) 

Default constructor for the ServiceResponse class.

Definition at line 37 of file service_response.cpp.


Member Function Documentation

ServiceResponse ServiceResponse::cycle (  )  [static]

Create a ServiceResponse that is the cycle status.

Returns:
The ServiceResponse

Reimplemented in APServiceResponse.

Definition at line 47 of file service_response.cpp.

ServiceResponse ServiceResponse::failed (  )  [static]

Create a ServiceResponse that is the failed status.

Returns:
The ServiceResponse

Reimplemented in APServiceResponse.

Definition at line 57 of file service_response.cpp.

bool ServiceResponse::isCycle (  )  [virtual]

Determine if this ServiceResponse has the cycle status.

Returns:
True if cycle, false otherwise

Definition at line 82 of file service_response.cpp.

bool ServiceResponse::isFailed (  )  [virtual]

Determine if this ServiceResponse has the failed status.

Returns:
True if failed, false otherwise

Definition at line 92 of file service_response.cpp.

bool ServiceResponse::isSucceeded (  )  [virtual]

Determine if this ServiceResponse has the succeeded status.

Returns:
True if succeeded, false otherwise

Definition at line 87 of file service_response.cpp.

void ServiceResponse::set ( ServiceResponse  resp  )  [virtual]

Set this ServiceResponse to have the same status as the given ServiceResponse.

Parameters:
resp The given ServiceResponse

Definition at line 62 of file service_response.cpp.

void ServiceResponse::setCycle (  )  [virtual]

Set this ServiceResponse to have a cycle status.

Reimplemented in APServiceResponse.

Definition at line 67 of file service_response.cpp.

void ServiceResponse::setFailed (  )  [virtual]

Set this ServiceResponse to have a failed status.

Reimplemented in APServiceResponse.

Definition at line 77 of file service_response.cpp.

void ServiceResponse::setSucceeded (  )  [virtual]

Set this ServiceResponse to have a succeeded status.

Definition at line 72 of file service_response.cpp.

ServiceResponse ServiceResponse::succeeded (  )  [static]

Create a ServiceResponse that is the succeeded status.

Returns:
The ServiceResponse

Definition at line 52 of file service_response.cpp.


Member Data Documentation

const int ServiceResponse::CYCLE = 0 [static, protected]

The service call is cycling.

Definition at line 48 of file service_response.h.

const int ServiceResponse::FAILED = 2 [static, protected]

The service call failed.

Definition at line 52 of file service_response.h.

int ServiceResponse::status_ [protected]

The status of this service response.

Definition at line 55 of file service_response.h.

const int ServiceResponse::SUCCEEDED = 1 [static, protected]

The service call succeeded.

Definition at line 50 of file service_response.h.


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

engagement_recognition
Author(s): Brett Ponsler (bponsler (at) wpi (dot) edu)
autogenerated on Fri Sep 9 10:35:49 2011