WPILib 2012
WPILibRoboticsLibraryforFRC
Public Member Functions
EnumCameraParameter Class Reference

#include <EnumCameraParameter.h>

Inheritance diagram for EnumCameraParameter:
IntCameraParameter

List of all members.

Public Member Functions

 EnumCameraParameter (const char *setString, const char *getString, bool requiresRestart, const char *const *choices, int numChoices)
virtual bool CheckChanged (bool &changed, char *param)
virtual void GetParamFromString (const char *string, int stringLength)

Detailed Description

Enumerated camera parameter. This class represents a camera parameter that takes an enumerated type for a value.


Constructor & Destructor Documentation

EnumCameraParameter::EnumCameraParameter ( const char *  setString,
const char *  getString,
bool  requiresRestart,
const char *const *  choices,
int  numChoices 
)

Constructor for an enumeration camera parameter. Enumeration camera parameters have lists of value choices and strings that go with them. There are also C++ enumerations to go along with them.

Parameters:
setStringThe string for an HTTP request to set the value.
getStringThe string for an HTTP request to get the value.
choicesAn array of strings of the parameter choices set in the http strings.
numChoicesThe number of choices in the enumeration set.

Member Function Documentation

bool EnumCameraParameter::CheckChanged ( bool &  changed,
char *  param 
) [virtual]

Check if a parameter has changed and update. Check if a parameter has changed and send the update string if it has changed. This is called from the loop in the parameter task loop.

Returns:
true if the camera needs to restart

Reimplemented from IntCameraParameter.

void EnumCameraParameter::GetParamFromString ( const char *  string,
int  stringLength 
) [virtual]

Extract the parameter value from a string. Extract the parameter value from the camera status message.

Parameters:
stringThe string returned from the camera.
lengthThe length of the string from the camera.

Reimplemented from IntCameraParameter.


The documentation for this class was generated from the following files:
 All Classes Functions Variables