All Frameworks  Class Hierarchy  This Framework  Previous  Next  Indexes

VPMDesktopObjects Interface CATIAVPMVDAComputeInstanceID

System.IUnknown
  |
  +---System.IDispatch
    |
    +---System.CATBaseUnknown
      |
      +---System.CATBaseDispatch
        |
        +---System.CATIABase
          |
          +---VPMDesktopObjects.CATIAVPMVDACommand
            |
            +---CATIAVPMVDAComputeInstanceID
 

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


interface CATIAVPMVDAComputeInstanceID

Interface to define the command to Generate the default instance ID.
Role : When a new instance is inserted in an assembly the instance ID is generated based on the V_ID value of the associated part/product. It is guaranteed to be unique compared to the other immediate children of the same parent. Example: Two instances of Part1 inserted below the same parent will result in instance IDs of Part1.1 and Part1.2. Note: If a user attempts to insert a part and fails for some reason, i.e. security, the next successfully generated id for the same part will skip a number. The algorithm is for uniqueness, not for a certain sequence.


Method Index


o get_Result()
Gets the value generated by the command.
o put_BObject(ENOVIABusinessObject*)
Sets the parent object.
o put_Value(CATUnicodeString&)
Sets the V_ID of the instance to create.
o set_Result(CATUnicodeString&)
Sets the value for the instance ID.

Methods


o get_Result
public virtual CATUnicodeString get_Result()= 0
Gets the value generated by the command.
Returns:
CATUnicodeString: the value of the new V_instance_ID.
o put_BObject
public virtual HRESULT put_BObject(ENOVIABusinessObject* object)= 0
Sets the parent object.
Parameters:
object:
the next higher assembly or the PRC in the case of a first level assembly.
Returns:
S_OK if successful, E_FAIL if internal error.
o put_Value
public virtual HRESULT put_Value( const CATUnicodeString& iVID) = 0
Sets the V_ID of the instance to create.
Parameters:
iVID:
the V_ID of the new instance.
Returns:
S_OK if successful, E_FAIL if internal error.
o set_Result
public virtual void set_Result( const CATUnicodeString& iInstanceID) = 0
Sets the value for the instance ID. This is for customization which modifies the generated instance id or replaces the default algorithm entirely. If this method is used in custom Prepare() code to set a non-empty string, then the default naming algorithm is skipped.
Parameters:
iInstanceID
: the value of the new V_instance_ID attribute.

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

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