ITT Rule IDL Version 7.0 User Manual Page 152

  • Download
  • Add to my manuals
  • Print
  • Page
    / 430
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 151
152 Chapter 7: Creating an Operation
Creating a New Data-Centric Operation iTool Developer’s Guide
Creating a New Data-Centric Operation
iTool operations that act primarily on data are based on the IDLitDataOperation class.
The class definition file for an IDLitDataOperation object must (at the least) provide
methods to initialize the operation class, get and set property values, execute the
operation, and define the operation class structure. Complex operations will likely
provide additional methods.
How an IDLitDataOperation Works
When an IDLitDataOperation is requested by a user, the following things occur:
1. As with any operation, execution commences when the DoAction method is
called. When called, the IDLitDataOperation retrieves the currently-selected
items. If nothing is selected, the operation returns.
2. For each selected item, the data objects of the parameters registered as
“operation targets” are retrieved.
3. The data objects are queried for iTool data types that match the types
supported by the IDLitDataOperation.
For each data object that includes data of an iTool data type supported by the
IDLitDataOperation, the following things occur:
1. The data from the data object is retrieved.
2. If the IDLitDataOperation does not have the REVERSIBLE_OPERATION
property set, a copy of the data is created and placed into the undo-redo
command set.
3. The Execute method is called, with the retrieved data as its argument.
4. If the Execute method succeeds and the IDLitDataOperation has the
EXPENSIVE_COMPUTATION property set, a copy of the results is placed
into the undo-redo command set.
5. The result of the IDLitDataOperation is placed in the data object. This action
will cause all visualization items that use the data object to update when the
operation is completed.
Once all selected data items have been processed, the undo-redo command set is
placed into the system undo-redo buffer for later use.
Page view 151
1 2 ... 147 148 149 150 151 152 153 154 155 156 157 ... 429 430

Comments to this Manuals

No comments