3D PLM PPR Hub Open Gateway |
Feature Modeler |
Frequently Asked Questions |
Quick Reference |
AbstractHere is a quick-access list of all the FAQs we have received from CAA partners as well as DS internal developers. In answers, links to the relevant documents or use cases are provided for a more detailed information. What interfaces should I use to delete a feature? When deleting a feature, how can I know if there are other features already pointing to it? |
What interfaces should I use to delete a feature?
Use the LifeCycleObject::remove
method when the
feature to be deleted is not aggregated by another feature. However, if it
itself aggregates other features, these will be deleted as well. Use the
CATISpecObject::GetFather
method to know if the feature is
aggregated or not.
Use CATISpecObject::Remove
(CATISpecObject_var)
to delete an aggregated feature. This method is executed on the aggregating
feature with the aggregated feature to be destroyed passed as an input
parameter.
Use CATICutAndPastable::Remove
on any feature, whether
aggregated or aggregating.
When deleting a feature, how can I know if there are other features already pointing to it?
Either one of two methods can be used to know if the feature you want to delete is currently being pointed at:
InverseAttrLink.
ListPointingObjects
. If the returned list of either method is not NULL, this means that other
features are pointing to the feature you want to delete through a
tk_component
or tk_specobject
link
The CCP/Delete options in the contextual menu are not enabled for my feature. What must I do to enable them?
You need to re-implement the CATICsoFilter interface of ApplicationFrame. However, you must first be sure that if the current UIActive object also implements this interface, it allows its re-implementation by others. This is the case in a Product document, but it may not be true in another context.
How can I change the name of a feature?
There are two ways to do this:
SetDisplayName
. This method
changes the name of the feature seen in the specs tree. It is not a
persistent change, i.e., if the document is saved and re-opened, the
feature's old name will appear in the specs tree again.SetAlias
method to permanently
change the name of a feature. If the feature is not a DS or DS-derived
feature, you must override this interface in order to provide a
persistent storage location for the new name.It may be important to understand how the default implementations actually work:
GetAlias
to retrieve the name of a feature. GetAlias
returns the name
calculated by CATISpecObject::GetDisplayName
: this is a
name based on the NLS text available for the feature.SetAlias
on a feature also
updates its display name which means that the NLS name is lost.I have created a new feature in my document but I cannot visualize its geometry nor see it in the specification tree. What do I need to do?
First of all, it is necessary for your feature to implement the CATI3DGeoVisu interface (or equivalent, deriving from CATIVisu) for geometry visualization and the CATINavigateObject interface for visualization and navigation in the specification tree. If this has been done, then it is only necessary to refresh the visualization process and the specification tree. This is done using the CATIModelEvents interface. Here is a code example you can follow:
CATIModelEvents *piModelEventNewFeat = NULL;
rc = piNewFeat->QueryInterface (IID_CATIModelEvents, (void**)&piModelEventNewFeat);
if (SUCCEEDED(rc))
{
CATCreate notif (piNewFeat, piParentFeat);
piModelEventNewFeat->Dispatch(notif);
piModelEventNewFeat->Release();
piModelEventNewFeat=NULL;
In the above code, you can see that, first of all, you need to retrieve a
CATIModelEvents pointer on your new feature. Then, you initialize a
CATCreate notification with the parent feature of the new feature and
then execute the Dispatch
method of CATIModelEvents to
dispatch the notification. Next, for visualization in the specification tree,
simply use the CATIRedrawEvents::Redraw
method on the
parent node of your new feature.
I use Extension Features onMechanical Features. I see them in the specifications tree for surfacic item but not for solid item, why?
Behaviors such as visualisation in the specifications tree or parameter display in f(x) are dependant of the extended feature.You should always refer to the corresponding documentation of the extended feature to confirm that the behaviors you experienced are specified and supported. If not documented, it means the behavior is not supported.Version: 1 [February 2002] | Document created |
Version: 2 [November 2004] | Extension clean up |
Version: 3 [November 2005] | Extension, graph question |
[Top] |
Copyright © 2002, Dassault Systèmes. All rights reserved.