cisst-saw
Loading...
Searching...
No Matches
prmMotionBase.h
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/* ex: set filetype=cpp softtabstop=4 shiftwidth=4 tabstop=4 cindent expandtab: */
3
4/*
5 Author(s): Rajesh Kumar, Anton Deguet
6 Created on: 2008-03-12
7
8 (C) Copyright 2008 Johns Hopkins University (JHU), All Rights
9 Reserved.
10
11--- begin cisst license - do not edit ---
12
13This software is provided "as is" under an open source license, with
14no warranty. The complete license can be found in license.txt and
15http://www.cisst.org/cisst/license.txt.
16
17--- end cisst license ---
18*/
19
20
21#ifndef _prmMotionBase_h
22#define _prmMotionBase_h
23
24// basic includes
26
28
29
30// Always include last
32
37{
38 public:
39
41
42 /* default constructor*/
43 inline prmMotionBase():
44 BlockingFlagMember(NO_WAIT),
45 BlendingFactorMember(false),
46 IsPreemptableMember(true),
47 IsCoordinatedMember(true),
48 IsGoalOnlyMember(false)
49 {}
50
54 inline prmMotionBase(const prmBlocking & blockingFlag,
55 const bool & blendingFactor,
56 const double & timeLimit,
57 const bool & isPreemptable,
58 const bool & isCoordinated,
59 const bool & isGoalOnly
60 ):
61 BlockingFlagMember(blockingFlag),
62 BlendingFactorMember(blendingFactor),
63 TimeLimitMember(timeLimit),
64 IsPreemptableMember(isPreemptable),
65 IsCoordinatedMember(isCoordinated),
66 IsGoalOnlyMember(isGoalOnly)
67 {}
68
71 virtual ~prmMotionBase();
72
76 inline void SetBaseParameter(const prmBlocking & blockingFlag,
77 const bool & blendingFactor,
78 const double & timeLimit,
79 const bool & isPreemptable,
80 const bool & isCoordinated,
81 const bool & isGoalOnly)
82 {
83 this->BlockingFlagMember = blockingFlag;
84 this->BlendingFactorMember = blendingFactor;
85 this->TimeLimitMember = timeLimit;
86 this->IsPreemptableMember = isPreemptable;
87 this->IsCoordinatedMember = isCoordinated;
88 this->IsGoalOnlyMember = isGoalOnly;
89 }
90
91
92
94 void SerializeRaw(std::ostream & outputStream) const;
95
97 void DeSerializeRaw(std::istream & inputStream);
98
99
104
109 CMN_DECLARE_MEMBER_AND_ACCESSORS(bool, BlendingFactor);
111
118
124
131
141
142
143};
144
145
146#endif // _prmMotionBase_h
mtsGenericObject(void)
Definition mtsGenericObject.h:77
CMN_DECLARE_MEMBER_AND_ACCESSORS(bool, IsGoalOnly)
CMN_DECLARE_MEMBER_AND_ACCESSORS(prmBlocking, BlockingFlag)
prmMotionBase(const prmBlocking &blockingFlag, const bool &blendingFactor, const double &timeLimit, const bool &isPreemptable, const bool &isCoordinated, const bool &isGoalOnly)
Definition prmMotionBase.h:54
virtual ~prmMotionBase()
CMN_DECLARE_MEMBER_AND_ACCESSORS(bool, IsCoordinated)
void SerializeRaw(std::ostream &outputStream) const
CMN_DECLARE_MEMBER_AND_ACCESSORS(double, TimeLimit)
void SetBaseParameter(const prmBlocking &blockingFlag, const bool &blendingFactor, const double &timeLimit, const bool &isPreemptable, const bool &isCoordinated, const bool &isGoalOnly)
Definition prmMotionBase.h:76
CMN_DECLARE_MEMBER_AND_ACCESSORS(bool, IsPreemptable)
prmMotionBase()
Definition prmMotionBase.h:43
CMN_DECLARE_MEMBER_AND_ACCESSORS(bool, BlendingFactor)
void DeSerializeRaw(std::istream &inputStream)
mtsGenericObject BaseType
Definition prmMotionBase.h:40
#define CISST_EXPORT
Definition cmnExportMacros.h:50
Defines mtsGenericObject.
Forward declarations for cisstParameterTypes.
enum Blocking prmBlocking
@ NO_WAIT
Definition prmForwardDeclarations.h:31