All Frameworks  Class Hierarchy  This Framework  Previous  Next  Indexes

OptimizationInterfaces Interface CATIOptAlgorithmUIFactory

System.IUnknown
  |
  +---System.IDispatch
    |
    +---System.CATBaseUnknown
      |
      +---CATIOptAlgorithmUIFactory
 

Usage: you can reimplement this interface by deriving the supplied CATOptAlgorithmUIFactoryAdapter adapter class.


interface CATIOptAlgorithmUIFactory

Interface to give a way to edit the settings of an optimization algorithm.
Implement this interface to add an algorithm to the optimization dialog.

BOA information: this interface CAN be implemented using the BOA (Basic Object Adapter). To know more about the BOA, refer to the CAA Encyclopedia home page. Click Middleware at the bottom left, then click the Object Modeler tab page. Several articles deal with the BOA.


Method Index


o CreateAlgoSettingsFrame(CATDialog*,unsigned long)
Creates a frame and dialogs to edit the algorithm settings.
o CreateStopAlgoDialog(CATDialog*,unsigned long,CATIOptOptimization_var&)
Instantiates an interruption dialog.

Methods


o CreateAlgoSettingsFrame
public virtual CATDlgFrame* CreateAlgoSettingsFrame(CATDialog* iFather,
unsigned long iStyle= 786433) = 0
Creates a frame and dialogs to edit the algorithm settings.
Role: This method builds a frame and fills it with dialog objects allowing interactive changes of the algorithm settings (radio buttons, check buttons, text editors, etc...). In your implementation, if you want to put callbacks on these different objects (in order to update the corresponding algorithm settings as soon as the user changes something), you will have to create a class that derives from CATDlgFrame (called "CATAlgoSettingsFrame" for example) in which you will insert your dialog objects and put the callbacks on them. Then this class will just instanciate your "CATAlgoSettingsFrame" object and return it.
Parameters:
iFather
The father dialog object. This argument is given by the optimization dialog and you will have to pass it to your "CATAlgoSettingsFrame" to respect the Optimizer dialog configuration.
iStyle
The style of the created dialog object. This argument is given by the optimization dialog and you will have to pass it to your "CATAlgoSettingsFrame" to respect the Optimizer dialog configuration. Default value is CATDlgFraNoTitle|CATDlgFraNoFrame|CATDlgGridLayout
Returns:
the instanciated frame that will be destroyed by the Optimizer dialog as soon as it will become useless.
o CreateStopAlgoDialog
public virtual CATDlgDialog* CreateStopAlgoDialog(CATDialog* iFather,
unsigned long iStyle,
const CATIOptOptimization_var& iOptim) = 0
Instantiates an interruption dialog.
Role: This method instantiates a dialog that will allow to stop the algorithm during its run as soon as : That is why you will have to create a class (called "CATStopAlgoDialog" for example) in which you will insert all the dialog objects ( among others : the STOP button) and put the needed callback on them (to update them while receiving the EndIterationNotification sent by the algorithm for example). Then, this class will just instanciate your "CATStopAlgoDialog" object and return it.
Parameters:
iFather
The father dialog object. This argument is given by the optimization dialog and you will have to pass it to your "CATStopAlgoDialog" to respect the Optimizer dialogs configuration.
iStyle
The style of the created dialog object. This argument is given by the optimization dialog and you will have to pass it to your "CATStopAlgoDialog" to respect the Optimizer dialogs configuration.
iOptim
the optimization you are running.
Returns:
the instanciated dialog object that will be destroyed by the Optimizer dialog as soon as it will become useless.

This object is included in the file: CATIOptAlgorithmUIFactory.h
If needed, your Imakefile.mk should include the module: OptimizationItf

Copyright © 2003, Dassault Systèmes. All rights reserved.