All Frameworks Class Hierarchy This Framework Previous Next Indexes
CATxPDMInterfaces Interface CATIxPDMSendToService
System.IUnknown
|
+---System.IDispatch
|
+---System.CATBaseUnknown
|
+---CATIxPDMSendToService
Usage: an implementation of this interface is supplied and you must use it as is. You should not reimplement it.
interface CATIxPDMSendToService
Interface to manage the Send To functionality.
Role:
This interface must be used to copy any CATIA V5 file document to a directory as soon as the document is linked to others.
The Send to functionality automatically reroutes the internal link in order to get in the target directory
a consistency set of linked documents. The target directory is those given as argument of the
CATxPDMFileServices.CreateSendToService method.
Functionalities are offered to rename, add or remove files to be send to a target directory.
Using the
Simulate method, you can predict the result of the
Run method which executes the resulting Send to operation.
The usage of this interface requires the installation of CATIA - PPR xPDM Gateway 1 Product (PX1)
or the installation of the CATIA-SmarTeam plugin.
In case one of these products is not granted any method of the interface fails.
It is required to not modify and save the documents in session between 2 consecutive calls to the
Add method and the
Simulate or
CATIxPDMSendToService.Run methods. This could leads to inconsitent result because of links modifications. An interface pointer is accessible using the
CATxPDMFileServices.CreateSendToService method.
- See also:
- CATIxPDMItem
Method Index
- o
Add(CATIxPDMItem_var&)
- Adds a file to the list of the files to be copied.
- o
AddFromDirectory(CATIxPDMItem_var&,CATListOfCATUnicodeString,CATBoolean)
- nodoc
- o
Remove(CATIxPDMItem_var&)
- Removes a file from the list of files to be copied.
- o
Rename(CATIxPDMItem_var&,CATUnicodeString&)
- Renames one file to be copied.
- o
Run(CATListValCATIxPDMItem_var&)
- Executes the Send To action.
- o
Simulate(CATListOfInt&,CATListValCATIxPDMItem_var&,CATListValCATIxPDMItem_var&)
- Simulates the Send To operation.
Methods
o Add
public virtual HRESULT Add( | CATIxPDMItem_var& | iInputItem) = 0 |
-
Adds a file to the list of the files to be copied.
Role: Verifies that the given input file is valid (exists on disk and is not a directory),
and recursively adds the pointed documents of the added file.
- Parameters:
-
- iInputItem
- The item to add. It can be retrieved from
CATxPDMFileServices.GetItemFromFile service.
- Returns:
-
- S_OK : item is well added to the list of to be copied files.
- E_FAIL: The method has failed. The possible returned errors (listed by their identifier) are:
- InputERR_1001:
The PX1 license is not available.
- InputERR_2004:
Item already in List.
- InputERR_2005:
Invalid input item.
- InputERR_2006:
The input item has no read permission.
o AddFromDirectory
-
nodoc
o Remove
public virtual HRESULT Remove( | CATIxPDMItem_var& | iInputItem) = 0 |
-
Removes a file from the list of files to be copied.
- Parameters:
-
- iInputItem
- The item to remove from the list of file to be copied.
It can be retrieved from
CATxPDMFileServices.GetItemFromFile service.
- Returns:
-
- S_OK : if item is well removed from the list of to be copied files.
- E_FAIL: The method has failed. The possible returned errors (listed by their identifier) are:
- InputERR_1001:
The PX1 license is not available.
- InputERR_2005:
Invalid input item.
- InputERR_2007:
Item not in the list.
- InputERR_2014:
Item already removed.
o Rename
-
Renames one file to be copied. The new name may not have invalid characters.
- Parameters:
-
- iInputItem
- The item to rename.
- iNewName
- New file identifier of the item (file name without extension).
- Returns:
-
- S_OK : item is well renamed.
- E_FAIL: The method has failed. The possible returned errors (listed by their identifier) are:
- InputERR_1001:
The PX1 license is not available.
- InputERR_2005:
The Invalid input item.
- InputERR_2007:
Item not in the list.
- InputERR_2008:
Invalid file identifier.
- InputERR_2011:
Input new name /P1 already used in the list.
- InputERR_2013:
Item to rename has been removed from list.
o Run
public virtual HRESULT Run( | CATListValCATIxPDMItem_var& | oListOutputItems) = 0 |
-
Executes the Send To action.
- Parameters:
-
- oListOutputItems
- List of all the final items in the targetted directory.
The targetted directory is the iTargetDirectory input parameter of the
CATxPDMFileServices.CreateSendToService service.
- Returns:
-
- S_OK : Send to successfully done.
- E_FAIL: The method has failed. The possible returned errors (listed by their identifier) are:
- InputERR_1119:
An item is loaded and modified in session, it should be saved before. (The NLS message includes the name of this wrong document).
- InputERR_1001:
The PX1 license is not available.
- InputERR_2009:
No data to Send To. At least 1 item has to be added.
- InputERR_2010:
Internal error.
- InputERR_2012:
2 different documents to copy have the same final identification.
(The NLS message includes the name of this wrong document)
- InputERR_2015:
No data to Send To. All items have been removed.
o Simulate
public virtual HRESULT Simulate( | CATListOfInt& | oStatusListOK, |
| CATListValCATIxPDMItem_var& | oListInputItems, |
| CATListValCATIxPDMItem_var& | oListOutputItems) = 0 |
-
Simulates the Send To operation.
Role: gives for each item included in the initial set of
documents its status and its final localization.
In case of a not null status, the corresponding output Items are set to NULL_var.
- Parameters:
-
- oStatusListOK
- For each item to be copied, targeted status.
The status can be:
- 0: The Item will be theorically successfully sent to.
- -1: The Item will not be copied because it has been removed from the list of files to Send To.
- 1: The Item will not be copied because the item is missing. This is a pointed document not retrieved on disk.
- 2: The Item will not be copied because the final item name is already used.
- 3: The Item will not be copied because it is modified in session.
- oListInputItems
- List of all the input items
- oListOutputItems
- List of all the final items.
Note that because this is only a simulation, the real final files are not generated. Dummy objects are computed.
They implement only the
CATIxPDMItem.GetDocFileName method of the
CATIxPDMItem interface.
- Returns:
-
- S_OK : Send To simulation successfully done.
- E_FAIL: The method has failed. The possible returned errors (listed by their identifier) are:
- InputERR_1001:
The PX1 license is not available.
- InputERR_1119:
An item is loaded and modified in session, it should be saved before. (The NLS message includes the name of this wrong document).
- InputERR_2009:
No data to Send To. At least 1 item has to be added.
- InputERR_2010:
Internal error.
- InputERR_2012:
2 different documents to copy have the same final identification.
(The NLS message includes the name of this wrong document)
- InputERR_2015:
No data to Send To. All items have been removed.
This object is included in the file: CATIxPDMSendToService.h
If needed, your Imakefile.mk should include the module: CATxPDMInterfaces