$search

industrial::joint_traj::JointTraj Class Reference

Class encapsulated joint trajectory For simplicity and cross platform compliance, this is implemented as a fixed size array. The size of the trajectory cannot exceed the max size of the array. More...

#include <joint_traj.h>

Inheritance diagram for industrial::joint_traj::JointTraj:
Inheritance graph
[legend]

List of all members.

Public Member Functions

bool addPoint (industrial::joint_traj_pt::JointTrajPt &point)
 Adds a point value to the end of the buffer.
unsigned int byteLength ()
 Virtual method returns the object size when packed into a ByteArray.
void copyFrom (JointTraj &src)
 Copies the passed in value.
int getMaxNumPoints () const
 returns the maximum number of points the message holds
bool getPoint (industrial::shared_types::shared_int index, industrial::joint_traj_pt::JointTrajPt &point)
 Gets a point value within the buffer.
void init ()
 Initializes a empty joint data.
bool isFull ()
 returns True if buffer is full
 JointTraj (void)
 Default constructor.
bool load (industrial::byte_array::ByteArray *buffer)
 Virtual method for loading an object into a ByteArray.
bool operator== (JointTraj &rhs)
 == operator implementation
industrial::shared_types::shared_int size ()
 Gets a size of trajectory.
bool unload (industrial::byte_array::ByteArray *buffer)
 Virtual method for unloading an object from a ByteArray.
 ~JointTraj (void)
 Destructor.

Private Attributes

industrial::joint_traj_pt::JointTrajPt points_ [MAX_NUM_POINTS]
 internal data buffer
industrial::shared_types::shared_int size_
 size of trajectory

Static Private Attributes

static const
industrial::shared_types::shared_int 
MAX_NUM_POINTS = 200
 maximum number of joints positions that can be held in the message.

Detailed Description

Class encapsulated joint trajectory For simplicity and cross platform compliance, this is implemented as a fixed size array. The size of the trajectory cannot exceed the max size of the array.

THIS CLASS IS NOT THREAD-SAFE

Definition at line 69 of file joint_traj.h.


Constructor & Destructor Documentation

industrial::joint_traj::JointTraj::JointTraj ( void   ) 

Default constructor.

This method creates empty data.

Definition at line 51 of file joint_traj.cpp.

industrial::joint_traj::JointTraj::~JointTraj ( void   ) 

Destructor.

Definition at line 55 of file joint_traj.cpp.


Member Function Documentation

bool industrial::joint_traj::JointTraj::addPoint ( industrial::joint_traj_pt::JointTrajPt point  ) 

Adds a point value to the end of the buffer.

Parameters:
point value
Returns:
true if value set, otherwise false (buffer is full)

Definition at line 71 of file joint_traj.cpp.

unsigned int industrial::joint_traj::JointTraj::byteLength (  )  [inline, virtual]

Virtual method returns the object size when packed into a ByteArray.

Returns:
object size (in bytes)

Implements industrial::simple_serialize::SimpleSerialize.

Definition at line 157 of file joint_traj.h.

void industrial::joint_traj::JointTraj::copyFrom ( JointTraj src  ) 

Copies the passed in value.

Parameters:
src (value to copy)

Definition at line 107 of file joint_traj.cpp.

int industrial::joint_traj::JointTraj::getMaxNumPoints (  )  const [inline]

returns the maximum number of points the message holds

Returns:
max number of points

Definition at line 135 of file joint_traj.h.

bool industrial::joint_traj::JointTraj::getPoint ( industrial::shared_types::shared_int  index,
industrial::joint_traj_pt::JointTrajPt point 
)

Gets a point value within the buffer.

Parameters:
point index
point value
Returns:
true if value set, otherwise false (index greater than size)
void industrial::joint_traj::JointTraj::init (  ) 

Initializes a empty joint data.

Definition at line 60 of file joint_traj.cpp.

bool industrial::joint_traj::JointTraj::isFull (  )  [inline]

returns True if buffer is full

Returns:
true if buffer is full

Definition at line 125 of file joint_traj.h.

bool industrial::joint_traj::JointTraj::load ( industrial::byte_array::ByteArray buffer  )  [virtual]

Virtual method for loading an object into a ByteArray.

This method should load all the required data to reconstruct the class object into the buffer

Parameters:
buffer pointer to ByteArray
Returns:
true on success, false otherwise (buffer not large enough)

Implements industrial::simple_serialize::SimpleSerialize.

Definition at line 151 of file joint_traj.cpp.

bool industrial::joint_traj::JointTraj::operator== ( JointTraj rhs  ) 

== operator implementation

Returns:
true if equal

Definition at line 119 of file joint_traj.cpp.

industrial::shared_types::shared_int industrial::joint_traj::JointTraj::size (  )  [inline]

Gets a size of trajectory.

Returns:
trajectory size

Definition at line 115 of file joint_traj.h.

bool industrial::joint_traj::JointTraj::unload ( industrial::byte_array::ByteArray buffer  )  [virtual]

Virtual method for unloading an object from a ByteArray.

This method should unload all the required data to reconstruct the class object (in place)

Parameters:
buffer pointer to ByteArray
Returns:
true on success, false otherwise (buffer not large enough)

Implements industrial::simple_serialize::SimpleSerialize.

Definition at line 177 of file joint_traj.cpp.


Member Data Documentation

const industrial::shared_types::shared_int industrial::joint_traj::JointTraj::MAX_NUM_POINTS = 200 [static, private]

maximum number of joints positions that can be held in the message.

Definition at line 168 of file joint_traj.h.

internal data buffer

Definition at line 172 of file joint_traj.h.

industrial::shared_types::shared_int industrial::joint_traj::JointTraj::size_ [private]

size of trajectory

Definition at line 176 of file joint_traj.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends


simple_message
Author(s): Shaun Edwards
autogenerated on Mon Mar 4 11:36:29 2013