The object types, including all their internal supporting data, that can be imported or exported are:
Folders | When exporting, you may choose to export any general folder. You may not export pseudo folders. |
Datasets | When exporting, you may choose to export either all versions, the latest version, or a specific version. |
Forms | When exporting, you may choose to export a Form. The definition of the form (UIL) must be identical at both sites. |
Items | When exporting, if you choose an Item, then the Item and all its related data (such as the Item Revisions, BOM View and BOM View Revisions, associated Item Master and Item Revision master forms, and also any exportable Requirement, Specification, Manifestation or Reference objects) are exported. Additionally, if the selected Item has an assembly (structure), then all the items that make up the assembly are exported. |
You cannot choose part of an Item to be exported. For example, you cannot choose an Item Revision alone to be exported. You need to select the Item which contains this Item Revision, in order to export the Item. Similarly, the same would be true with BOMView and BOMViewRevision objects.
When exporting, there is an option to transfer the ownership to another site. If the ownership is transferred to a particular site, then, when the same objects are imported at that particular site, they will be imported with a read/write privilege. If the ownership is not transferred, then the ownership of the objects still belongs to the export site. When these objects are imported at another site, they will be imported with read only privilege. Any modifications attempted on them would not be allowed.
Common Return Values
Return Value | Description |
BIER_invalid_for_remote_bier_type | manager_tag was not created with the proper type. |
IDSM_client_access_denied | The local site is not a permitted client of the remote site. |
IDSM_no_connect | Unable to connect to remote site. |
OBJIO_cannot_reuse_dir | area_name has already been used for object export. |
OBJIO_dir_not_found | area_name does not exist. |
OBJIO_invalid_attribute_flag | The attribute flag given for the import/export area is not supported. See objio.h for valid attribute flags. |
OBJIO_invalid_dir_contents | Cannot read the import data. Most likely due to out-of-date or missing POM transmit files. |
OBJIO_invalid_site | The given target site is not defined in the database. |
OBJIO_invalid_tag | The given tag for the import/export manager is not valid. |
OBJIO_unsupported_type | The type given for the import/export area is not supported. See objio.h for valid types. |
typedef struct OBJIO_report_s OBJIO_report_t |
enum ORGExpType |
OBJIO_API int OBJIO__make_temp_staging_dir | ( | char ** | directory | ) |
directory | (OF) |
OBJIO_API int OBJIO_abort_sst_export | ( | tag_t | export_bier_tag | ) |
export_bier_tag | (I) |
OBJIO_API int OBJIO_abort_sst_export_post_write | ( | tag_t | main_object_tag | ) |
main_object_tag | (I) |
OBJIO_API int OBJIO_abort_sst_import | ( | tag_t | obj_tag | ) |
obj_tag | (I) |
Lists the contents of the area specified by manager_tag.
You must call OBJIO_read before using this function, otherwise no objects will be listed.
The client is responsible for freeing objects with MEM_free.
manager_tag | (I) Tag of the OBJIO area |
n_objects | (O) Number of objects in the area |
objects | (OF) n_objects Tags of the objects in the area |
OBJIO_API int OBJIO_ask_distributed_assy_info | ( | tag_t | manager_tag, | |
int * | n_dist_components, | |||
tag_t ** | dist_component_list, | |||
int ** | owning_site_list | |||
) |
This function retrieves information regarding distributed components from the import/export metafile.
manager_tag | (I) Import manager tag |
n_dist_components | (O) Number of distributed components |
dist_component_list | (OF) n_dist_components Tags of distributed components |
owning_site_list | (OF) n_dist_components Site ID of corresponding owning site for each component tag |
OBJIO_API int OBJIO_ask_error_report_info | ( | tag_t | manager_tag, | |
int * | n_info, | |||
OBJIO_report_t ** | info_list | |||
) |
OBJIO_API int OBJIO_ask_failures | ( | tag_t | manager_tag, | |
int * | n_failures, | |||
tag_t ** | failing_objects, | |||
int ** | failures | |||
) |
Lists the objects which failed to be stored/restored by a call to OBJIO_store_objects or OBJIO_restore_objects. For example, an object will not be restored if it does not exist in the area.
The client is responsible for freeing failing_objects and failures with MEM_free.
manager_tag | (I) Tag of the OBJIO area |
n_failures | (O) Number of objects that failed to be stored/restored |
failing_objects | (OF) n_failures Tags of the objects which failed to be stored/restored |
failures | (OF) n_failures Reasons why the objects failed |
manager_tag | (I) |
metafile_tag | (O) |
OBJIO_API int OBJIO_ask_receiving_group | ( | tag_t | manager_tag, | |
char | receiving_group[SS_MAXPATHLEN+1] | |||
) |
manager_tag | (I) |
receiving_group | (O) |
OBJIO_API int OBJIO_ask_receiving_group2 | ( | tag_t | manager_tag, | |
char ** | receiving_group | |||
) |
Used to get the receiving group of the imported objects
manager_tag | (I) |
receiving_group | (OF) |
OBJIO_API int OBJIO_ask_receiving_user | ( | tag_t | manager_tag, | |
char | receiving_user[SA_user_size_c+1] | |||
) |
manager_tag | (I) |
receiving_user | (O) |
OBJIO_API int OBJIO_ask_receiving_user2 | ( | tag_t | manager_tag, | |
char ** | receiving_user | |||
) |
Used to get the receiving user of the imported objects
manager_tag | (I) |
receiving_user | (OF) |
OBJIO_API int OBJIO_ask_report_info | ( | tag_t | manager_tag, | |
int * | n_info, | |||
OBJIO_report_t ** | info_list | |||
) |
manager_tag | (I) |
n_info | (O) |
info_list | (O) |
OBJIO_API int OBJIO_ask_sending_group | ( | tag_t | manager_tag, | |
char | sending_group[SS_MAXPATHLEN+1] | |||
) |
manager_tag | (I) |
sending_group | (O) |
OBJIO_API int OBJIO_ask_sending_group2 | ( | tag_t | manager_tag, | |
char ** | sending_group | |||
) |
Used to get the sending group of the imported objects
manager_tag | (I) |
sending_group | (OF) |
OBJIO_API int OBJIO_ask_sending_user | ( | tag_t | manager_tag, | |
char | sending_user[SA_user_size_c+1] | |||
) |
manager_tag | (I) |
sending_user | (O) |
OBJIO_API int OBJIO_ask_sending_user2 | ( | tag_t | manager_tag, | |
char ** | sending_user | |||
) |
Used to get the sending user of the imported objects
manager_tag | (I) |
sending_user | (OF) |
OBJIO_API int OBJIO_create | ( | int | type, | |
char * | area_name, | |||
tag_t * | manager_tag | |||
) |
Creates an area to use when moving objects into or out of the database.
Restrictions:
type must be OBJIO_import_type or OBJIO_export_type.
type | (I) Type of area to create |
area_name | (I) Name of the area (for OBJIO_export_type, this is the name of the directory to be written to; for OBJIO_import_type, it is the name of the directory to be read from). |
manager_tag | (O) Tag of the newly created area |
OBJIO_API int OBJIO_delete | ( | tag_t | manager_tag | ) |
Deletes the area specified by manager_tag.
manager_tag | (I) Tag of the OBJIO area to be deleted |
OBJIO_API int OBJIO_delete_staging_dir | ( | const char * | directory | ) |
directory | (I) |
OBJIO_API int OBJIO_end_remote_transfer | ( | tag_t | manager_tag, | |
int | error_code | |||
) |
manager_tag | (I) |
error_code | (I) |
Specifies a number of objects to be excluded explicitly from operations on the area specified by manager_tag.
For example, when exporting a folder with many contents, you can conveniently export most of the contents by first setting the OBJIO_include_contents attribute to 1, and then using this function to specify the small number of objects that you do not wish to export.
This function must be called before OBJIO_store_objects or OBJIO_restore_objects.
You may call this function several times before calling OBJIO_store_objects or OBJIO_restore_objects.
manager_tag | (I) Tag of the OBJIO area |
n_objects | (I) Number of objects to exclude |
objects | (I) n_objects Tags of the objects to exclude |
manager_tag | (I) |
count | (I) |
relation_types | (I) count |
OBJIO_API int OBJIO_find_export_sites_by_tag | ( | tag_t | object_tag, | |
int * | nSites, | |||
tag_t ** | site_tags, | |||
char ** | export_sites_as_string, | |||
logical * | isSiteStrNull | |||
) |
The following is intended to be used while deleting replicated organization objects
The following is intended to be used while deleting replicated organization objects
OBJIO_API int OBJIO_get_bg_report_file | ( | char * | reportStr, | |
char ** | report_file_name | |||
) |
reportStr | (I) |
report_file_name | (OF) |
OBJIO_API int OBJIO_get_report_file | ( | char ** | report_file_name | ) |
The following is intended to be used by the Portal Report Service mechanism, and is intended to be called by users via user_exits
report_file_name | (OF) |
OBJIO_API int OBJIO_read | ( | tag_t | manager_tag | ) |
Reads the objects that were written to the area specified by manager_tag, preparatory to listing those objects.
manager_tag | (I) Tag of the OBJIO area |
OBJIO_API int OBJIO_record_being_imported | ( | tag_t | manager_tag | ) |
manager_tag | (I) |
OBJIO_API int OBJIO_release_and_replicate | ( | EPM_action_message_t | msg | ) |
The following is intended to be used as workflow handler for initating controlled replication
msg | (I) |
manager_tag | (I) |
relation_type | (I) |
Restores the specified objects from the area specified by manager_tag.
You must call OBJIO_read before using this function, otherwise no objects will be restored.
You may call this function several times with the same manager_tag.
manager_tag | (I) Tag of the OBJIO area |
n_objects | (I) Number of objects to restore |
objects | (I) n_objects Tags of the objects to restore |
Exports object(s) from the given remote site into a metafile within a local directory.
Before calling this function, the following functions must be called first with the appropriate parameters:
OBJIO_create | This should be called to create the manager_tag, specifying a type of OBJIO_remote_transfer_from_type as well as the local directory where the metafile will go into. |
OBJIO_store_objects | This should be called to specify which remote object(s) to export. |
OBJIO_set_attribute | May also be called before calling OBJIO_retrieve. If OBJIO_retrieve returns a successful status, it is recommended that you call OBJIO_ask_failures to determine if any error occurred. |
Restrictions:
The local site must be a permitted client of the remote site.
manager_tag | (I) Export manager tag created via an earlier call to OBJIO_create |
source_site | (I) Tag of remote site to export from |
Imports object(s) from a metafile within a local directory into a remote site.
Before calling this function, OBJIO_create must be called with a type of OBJIO_remote_transfer_to_type and with the local directory containing the metafile.
If OBJIO_send returns a successful status, it is recommended that you call OBJIO_ask_failures to determine if any error occurred.
Restrictions:
The local site must be a permitted client of the remote site.
Before calling this function, the metafile must already exist in the directory given in the OBJIO_create call. If the object to be sent has not been exported yet, then you need to create a separate manager area, store objects (via OBJIO_store_objects) and write the objects (via OBJIO_write). After the object is exported, create a second manager area for sending and then call OBJIO_send.
manager_tag | (I) Export manager tag created via an earlier call to OBJIO_create |
destination_site | (I) Tag of remote site to import into |
OBJIO_API int OBJIO_set_attribute | ( | tag_t | manager_tag, | |
int | attribute_flag, | |||
int | value | |||
) |
Sets an attribute for the area specified by manager_tag.
manager_tag | (I) Tag of the OBJIO area |
attribute_flag |
(I) Attribute flag to set or unset. Valid values are in objio.h. The following attribute flags show examples of the valid values: OBJIO_dataset_all_versions If value is non-zero, include all revisions of any specified datasets. OBJIO_include_contents If value is non-zero, include the contents of any specified folders. |
value | (I) Value to which to set the attribute |
OBJIO_API int OBJIO_set_export_reason | ( | tag_t | manager_tag, | |
const char * | export_reason | |||
) |
Sets the export reason for the particular export. This is optional.
manager_tag | (I) Tag of the OBJIO area to export data to |
export_reason | (I) Reason for the export. This can be up to 240 characters. |
OBJIO_API int OBJIO_set_incremental_bvr_changes | ( | tag_t | manager_tag, | |
tag_t | bvr_tag, | |||
int | n_modified_or_added_occs, | |||
const tag_t * | modified_or_added_occs, | |||
int | n_deleted_occs, | |||
const tag_t * | deleted_occs | |||
) |
Sets the given site as the new owning site. Either this function or OBJIO_set_target_sites is required when exporting data.
manager_tag | (I) Tag of the OBJIO area to export data to |
site_tag | (I) Tag of the new owning site |
OBJIO_API int OBJIO_set_receiving_group | ( | tag_t | manager_tag, | |
const char | receiving_user[SA_group_name_size_c+1] | |||
) |
manager_tag | (I) |
receiving_user | (I) |
OBJIO_API int OBJIO_set_receiving_group2 | ( | tag_t | manager_tag, | |
const char * | receiving_user | |||
) |
The following are used to set the owning group of the imported objects
manager_tag | (I) |
receiving_user | (I) |
OBJIO_API int OBJIO_set_receiving_user | ( | tag_t | manager_tag, | |
const char | receiving_user[SA_user_size_c+1] | |||
) |
manager_tag | (I) |
receiving_user | (I) |
OBJIO_API int OBJIO_set_receiving_user2 | ( | tag_t | manager_tag, | |
const char * | receiving_user | |||
) |
Used to set the owning user of the imported objects
manager_tag | (I) |
receiving_user | (I) |
OBJIO_API int OBJIO_set_release_status | ( | tag_t | manager_tag, | |
const char | status_type[WSO_name_size_c+1] | |||
) |
For the release status type to take effect, the attribute OBJIO_specific_status_only must be set through OBJIO_set_attribute.
Restrictions:
The given release status type must be defined in the database where the export is being performed.
manager_tag | (I) Export manager tag created via OBJIO_create |
status_type | (I) Valid release status type. Only revisions with this release status will be exported. |
OBJIO_API int OBJIO_set_release_status2 | ( | tag_t | manager_tag, | |
const char * | status_type | |||
) |
Sets the release status type that will be used to select item revisions to be exported.
For the release status type to take effect, the attribute OBJIO_specific_status_only must be set through OBJIO_set_attribute.
Restrictions:
The given release status type must be defined in the database where the export is being performed.
manager_tag | (I) Export manager tag created via OBJIO_create |
status_type | (I) Valid release status type. Only revisions with this release status will be exported. |
OBJIO_API int OBJIO_set_revision_rule | ( | tag_t | manager_tag, | |
const char | status_type[WSO_name_size_c+1] | |||
) |
OBJIO_API int OBJIO_set_revision_rule2 | ( | tag_t | manager_tag, | |
const char * | status_type | |||
) |
OBJIO_API int OBJIO_set_script | ( | tag_t | manager_tag, | |
const char | script[SS_MAXPATHLEN+1] | |||
) |
NOT intended for customer-written ITK programs
manager_tag | (I) |
script | (I) |
OBJIO_API int OBJIO_set_script2 | ( | tag_t | manager_tag, | |
const char * | script | |||
) |
manager_tag | (I) |
script | (I) |
OBJIO_API int OBJIO_set_sending_group | ( | tag_t | manager_tag, | |
const char | sending_group[SS_MAXPATHLEN+1] | |||
) |
manager_tag | (I) |
sending_group | (I) |
OBJIO_API int OBJIO_set_sending_group2 | ( | tag_t | manager_tag, | |
const char * | sending_group | |||
) |
Used to set the sending group of the imported objects
manager_tag | (I) |
sending_group | (I) |
OBJIO_API int OBJIO_set_sending_user | ( | tag_t | manager_tag, | |
const char | sending_user[SA_user_size_c+1] | |||
) |
manager_tag | (I) |
sending_user | (I) |
OBJIO_API int OBJIO_set_sending_user2 | ( | tag_t | manager_tag, | |
const char * | sending_user | |||
) |
Used to set the sending user of the imported objects
manager_tag | (I) |
sending_user | (I) |
OBJIO_API int OBJIO_set_site_based_attribute | ( | tag_t | manager_tag, | |
tag_t | remote_site, | |||
int | attribute_flag, | |||
int | value | |||
) |
Sets an attribute for the area specified by manager_tag. The attribute may not be supported by all sites.
manager_tag | (I) Tag of the OBJIO area |
remote_site | (I) Tag of remote site |
attribute_flag | (I) Attribute flag to set or unset. |
value | (I) Value to which to set the attribute |
OBJIO_API int OBJIO_set_sync_options | ( | tag_t | owning_site, | |
int | options_token, | |||
int | n_obj_tags, | |||
const tag_t * | obj_tags, | |||
int ** | failure_codes | |||
) |
This function is called from the replica side to the owning site and is used to set synchronization options for the existing replica objects given in the obj_tags argument. The desired options are specified via the options_token argument.
Restrictions:
The given owning site must be running V7.0 or later and must enable Subscriptions.
owning_site | (I) Integer site id of the site that owns the objects given in object_tags |
options_token | (I) Integer value that indicates the sync options specified. Valid values are defined in objio.h. |
n_obj_tags | (I) Number of replica objects to apply sync options to |
obj_tags | (I) Replica objects tags to apply options to. All tags must be of the WorkspaceObject class. |
failure_codes | (OF) n_obj_tags Error code returned for each corresponding object in object_tags list |
Identifies the sites that are authorized to import the data that will be exported without ownership transfer. Either this function or OBJIO_set_owning_site is required when exporting data.
manager_tag | (I) Tag of the OBJIO area to export data to |
site_count | (I) Number of target sites |
site_list | (I) site_count Tag of target sites |
Stores the specified objects, ready for writing to the area specified by manager_tag.
You may call this function several times before calling OBJIO_write.
Restrictions:
You must have read access to all the objects.
manager_tag | (I) Tag of the OBJIO area |
n_objects | (I) Number of objects to store |
objects | (I) n_objects Tags of the objects to store |
OBJIO_API int OBJIO_write | ( | tag_t | manager_tag | ) |
Writes the objects, specified in calls to OBJIO_store_objects, to the area specified by manager_tag.
Restrictions:
You should not call this function more than once with the same manager_tag, as it is not cumulative; that is, each call will overwrite the result of the previous call.
manager_tag | (I) Tag of the OBJIO area to which to write objects |