VPMEditorInterfaces Interface CATIPrdObjectInContextUI

Usage: an implementation of this interface is supplied and you must use it as is. You should not reimplement it.


interface CATIPrdObjectInContextUI

Interface to create a CATOmbObjectInContext in a command design context.
Role: This interface is to be used in interactive commands to ease the creation of CATOmbObjectInContext from the object obtained after a selection in a graphical viewer.
You can retrieve a pointer on this interface thanks to the global function.
Code sample:

...
  CATIPrdObjectInContextUI * piPrdObjInContextUI = NULL;
  rc = ::CATInstantiateComponent("CATPrdUIFactory",IID_CATIPrdObjectInContextUI,
                                (void**)&piPrdObjInContextUI);
  if(SUCCEEDED(rc) && NULL != piPrdObjInContextUI)
  {
    ...
	 piPrdObjInContextUI->Release(); piPrdObjInContextUI = NULL;
  }
   ...
 
"CATPrdUIFactory" is a static string defining the component name.
Refer to the CATOmbObjectInContext technical article in the documentation for explanations about the creation and usage of those objects.


Method Index


o ComputeListOfObjectInContextFromPathElement(CATPathElement&,CATIPLMComponent*,CATLISTV(CATBaseUnknown_var)&)
Creates a list of possible CATOmbObjectInContext from the given CATPathElement.
o ComputeObjectInContextFromPathElement(CATPathElement&,CATBoolean,CATIPLMComponent*,CATOmbObjectInContext*&)
Creates a CATOmbObjectInContext from the given CATPathElement.

Methods


o ComputeListOfObjectInContextFromPathElement
public virtual ComputeListOfObjectInContextFromPathElement( iPathElement,
ipRequiredRoot,
oListObjectInContext)
Creates a list of possible CATOmbObjectInContext from the given CATPathElement.
Note: If the target is pointed by a Port, itself pointed by another Port, the resulting list will contain more than one element. Otherwise, the result will be the same as with
Parameters:
iPathElement
The given path element.
ipRequiredRoot
The component used to determine the root PLM Reference of the context.
  • If NULL is given, the root PLM Reference is extracted from the CATPathElement.
  • The given PLM Component should be either a Product Instance or a Product Reference related to a Product object (Reference, Instance or Occurrence) in the given
.
oListObjectInContext
The output list of computed CATOmbObjectInContext.
Returns:
  • S_OK if the list of computed CATOmbObjectInContext was successfully created
  • E_FAIL otherwise
o ComputeObjectInContextFromPathElement
public virtual ComputeObjectInContextFromPathElement( iPathElement,
iLookForFirstPort,
ipRequiredRoot,
oObjectInContext)
Creates a CATOmbObjectInContext from the given CATPathElement.
Parameters:
iPathElement
The given path element, which will be interpreted by the method to create the CATOmbObjectInContext object.
iLookForFirstPort
  • TRUE: The method lookups for a Port pointing the target object.

  • When several Ports exist, a CATOmbObjectInContext identifying the topmost Port is returned.
    Otherwise, a CATOmbObjectInContext identifying the target object is returned.
  • FALSE: a CATOmbObjectInContext identifying the target object is returned.
ipRequiredRoot
The component used to determine the root PLM Reference of the context.
  • If NULL is given, the root PLM Reference is extracted from the CATPathElement.
  • The given PLM Component should be either a Product Instance or a Product Reference related to a Product object (Reference, Instance or Occurrence) in the given
.
oObjectInContext
[out, CATBaseUnknown#Release] The built CATOmbObjectInContext representing the CATPathElement in this context.
Returns:
  • S_OK if oObjectInContext has been successfully created.
  • E_FAIL otherwise.

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

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