FeatureModelerExt Interface CATIFmFeatureBehaviorCustomization

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


interface CATIFmFeatureBehaviorCustomization

Interface to implement user defined behaviors.

Refer to the CAA Encyclopedia Feature Modeler pages, and more specifically the articles:

before implementing this interface on the Late Types of your StartUps.

Usage restriction: This interface is U4 only because no specific value exist for interface that must only be implemented.
Application or not allowed to query or use this Interface on any objects but their own.

BOA information: This interface must be implemented using the BOA (Basic Object Adapter). To know more about the BOA, refer to the CAA Encyclopedia home page. Several articles deal with the BOA.


Method Index


o BeforeRemove()
Performs additional applicative clean-up at a Feature removal.
o Build()
Generates the result of a Feature for the Update.
o CanBeRemoved(CATBoolean&)
Retrieves the deletability of a Feature from its application owner perspective.
o CcpPaste(CATFmCCPContext&)
Creates the link between the copies and the paste targets.
o CcpRegisterAdditionalObjectsForCopy(CATListValCATBaseUnknown_var&,CATListValCATBaseUnknown_var&)
Computes the list of objects to take part in a Copy operation.
o CcpRegisterAdditionalObjectsForRemove(CATListValCATBaseUnknown_var&,CATListValCATBaseUnknown_var&)
Computes the list of objects to take part in a Cut operation.
o CcpUpdate(CATFmCCPContext&)
Integrates the created objects in their environment.

Methods


o BeforeRemove
public virtual BeforeRemove()
Performs additional applicative clean-up at a Feature removal.
Role: This method is invoked on each feature when its logical removal is just beginning.
Override this method to perform additional model alteration related to the object removal, like the deletion of a singleton Feature that will become useless after the removal of the last Feature that used the singleton.
All the components (recursively) of the current feature will be deleted automatically. This is the default behavior.
Warnings:
Returns:
An HRESULT value.
Legal values:
S_OK
The clean-up has been performed successfuly.
E_FAIL
Otherwise. How the removal process will handle this failure is currently unspecified.
E_NOTIMPL
This method has been implemented only for C++ reasons, the default behavior being sufficient for the current Feature.
This return code is not considered as a failure, the value of the output parameter is ignored and the process continues using only the default behavior.
This is the value returned by the CATFmFeatureCustomizationAdaptor method.
o Build
public virtual Build()
Generates the result of a Feature for the Update.
Role: The build is launched by the Update Engine, after the Feature inputs (sp_in attributes) have been updated.
Override this method to compute the result of the Feature.
In the implementation:
Returns:
An HRESULT value.
Legal values:
S_OK
The build succeeded.
E_FAIL
Otherwise (the Update process is then aborted).
E_NOTIMPL
This method has been implemented only for C++ reasons, the current Feature is not expected to be involved in an Update process.
How the Update process will handle this failure is currently unspecified.
If the current Feature is to be involved in an Update process, override this method and return S_OK even if nothing speecific must be done.
o CanBeRemoved
public virtual CanBeRemoved( oDeletable)
Retrieves the deletability of a Feature from its application owner perspective.
Role: Services and algorithms may invoke this method to check if the removal of an applicative Feature is legitimate.

Override it to let the caller know if he should proceed with the removal. If this method is not overriden, the default rule is to allow the deletion of all Features that are not aggregated, and refuse the deletion of any aggregated Feature.

Warnings:

Parameters:
oDeletable
[out] Whether or not the Feature deletion is legitimate within the application design.
Returns:
An HRESULT value.
Legal values:
S_OK
oDeletable has been valuated.
E_FAIL
Otherwise. How the removal process will handle this failure is currently unspecified.
E_NOTIMPL
This method has been implemented only for C++ reasons, the default behavior being correct for the current Feature.
This return code is not considered as a failure, the value of the output parameter is ignored and the process continues using only the default behavior.
This is the value returned by the CATFmFeatureCustomizationAdaptor method.
o CcpPaste
public virtual CcpPaste( const iContext)
Creates the link between the copies and the paste targets.
Role: Override this method to implement the final step of the paste operation.
This method will be invoked on the target Features, once all the copies have been created and updated. Depending on the applicative modelization, a link or aggregation link may have to be set between the Paste target(s) and the created copies. The default behavior is to do nothing.
Parameters:
iContext
[in] An object describing the context of the operation and providing additional inputs required to implement the method.
Returns:
An HRESULT value.
Legal values:
S_OK
The operation succeeded.
E_FAIL
Otherwise (the Paste process is then aborted).
E_NOTIMPL
This method has been implemented only for C++ reasons, the default behavior being sufficient for the current Feature.
This return code is not considered as a failure, the process continues using only the default behavior.
This is the value returned by the CATFmFeatureCustomizationAdaptor method.
See also:
o CcpRegisterAdditionalObjectsForCopy
public virtual CcpRegisterAdditionalObjectsForCopy( const iInitialSetOfObjects,
oObjectToAddToBoundary)
Computes the list of objects to take part in a Copy operation.
Role: Override this method to provide a list of additional objects that need to be copied along with the current Feature.
All the components and extensions (both recursively) of the current feature will necessarily be copied. This cannot be prevented and is considered as the default behavior. Adding components of the current feature is useless and may slow down the process.
Warning: this method is intended to be called at any time, even when the model MUST NOT be modified. DO NOT alter or try to alter the model.
Parameters:
iInitialSetOfObjects
[in] The set of objects intially selected to be duplicated by the Copy operation.
oObjectToAddToBoundary
[out] The additional objects that must also be copied and must be included in the Copy algorithm.
Returns:
An HRESULT value.
Legal values:
S_OK
The operation succeeded.
E_FAIL
Otherwise (the Copy/Paste process is then aborted).
E_NOTIMPL
This method has been implemented only for C++ reasons, the default behavior being sufficient for the current Feature.
This return code is not considered as a failure, the value of the output parameter is ignored and the process continues using only the default behavior.
This is the value returned by the CATFmFeatureCustomizationAdaptor method.
o CcpRegisterAdditionalObjectsForRemove
public virtual CcpRegisterAdditionalObjectsForRemove( const iInitialSetOfObjects,
oObjectToAddToBoundary)
Computes the list of objects to take part in a Cut operation.
Role: Override this method to provide a list of additional objects that need to be deleted along with the current Feature.
All the components and extensions (both recursively) of the current feature will necessarily be deleted. This cannot be prevented and is considered as the default behavior. Adding components of the current feature is useless and may slow down the process.
Note: Some implementations of the interactive Delete command are also based on the Cut algorithm internally.
Warning: this method is intended to be called at any time, even when the model MUST NOT be modified. DO NOT alter or try to alter the model.
Parameters:
iInitialSetOfObjects
[in] The set of objects intially selected to be suppressed by the Cut operation.
oObjectToAddToBoundary
[out] The additional objects that must also be deleted and must be included in the Cut algorithm.
Returns:
An HRESULT value.
Legal values:
S_OK
The operation succeeded.
E_FAIL
Otherwise (the Cut/Delete process is then aborted).
E_NOTIMPL
This method has been implemented only for C++ reasons, the default behavior being sufficient for the current Feature.
This return code is not considered as a failure, the value of the output parameter is ignored and the process continues using only the default behavior.
This is the value returned by the CATFmFeatureCustomizationAdaptor method.
o CcpUpdate
public virtual CcpUpdate( const iContext)
Integrates the created objects in their environment.
Role: Override this method to perform modification to the clone structure to adapt it to its new context.
Modifications to be performed in this method are for example the invalidation of a computed cache or result stored in an attribute value, or manage refrences to a singleton.
The deletion of any "copy" is to be avoided as it could prevent correct rerouting of links among the "copies" and lead to a corrupted model.
This method will be invoked on all "copy" Features, once all the copies have been created. A link set on a Feature that has been copied to itself or to another Feature also copied will be rerouted to reference the copy of its original target. This cannot be prevented and is considered as the default behavior.
Warnings:
Parameters:
iContext
[in] An object describing the context of the operation and providing additional inputs required to implement the method.
Returns:
An HRESULT value.
Legal values:
S_OK
The operation succeeded.
E_FAIL
Otherwise (the Copy/Paste process is then aborted).
E_NOTIMPL
This method has been implemented only for C++ reasons, the default behavior being sufficient for the current Feature.
This return code is not considered as a failure, the process continues using only the default behavior.
This is the value returned by the CATFmFeatureCustomizationAdaptor method.
See also:

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

Copyright © 1999-2014, Dassault Systèmes. All rights reserved.