For more information about this bug, visit
A comment was added:
------- Comment #1 from peter [dot] soetens [..] ... 2007-03-23 11:44
Created an attachment (id=93)
--> (http://www.fmtc.be/orocos-bugzilla/attachment.cgi?id=93&action=view)
Improved TaskObject implementation
This patch solves what is primarily described in the bug report:
* relocate some TaskContext functions to the OperationInterface base class.
* Load programs scripts and state machine scripts as TaskObjects instead of
TaskContexts
* Update the Corba IDL: also move some functions from 'ControlTask' to
'ControlObject' base class.
This patch is backwards compatible except that a loaded script is now a
TaskObject instead of a TaskContext, meaning you need to use getObject()
instead of getPeer(), and that the 'states' and 'programs' intermediate
TaskContexts have been removed. The scripting has been adapted such that the
old syntax, e.g. 'Atask.states.myStateMachine.start()', issues a warning and is
interpreted as 'Atask.myStateMachine.start()'.
Although the patch is quite big, it does not require common 1.0 applications to
be adapted. I yet have to see the user that wanted to start his state machine
in this way:
Method
start =
ATask.getPeer("states")->getPeer("MyStateMachine")->methods()->getMethod("start");
start();
In case you did, I guess you're smart enough anyway to fix it. Others, just
keep using:
// CORBA portable:
ATask.execution()->startStateMachine("MyStateMachine");
or:
// only works on local TaskContexts:
ATask.engine()->states()->getStateMachine("MyStateMachine")->start();
Thank you.
[Bug 328] [Project]Refactor TaskObject vs TaskContext
For more information about this bug, visit
peter [dot] soetens [..] ... changed:
What |Removed |Added
---------------------------------------------------------------------------
Target Milestone|--- |1.2.0
Resolution| |FIXED
Status|NEW |RESOLVED
------- Comment #2 from peter [dot] soetens [..] ... 2007-04-25 15:42
This code was merged on trunk.