#define ITK_BATCH_TEXT_MODE 0 |
#define ITK_BATCH_TEXT_MODE 0 |
Default Text Mode for ITK Batch Program
Definition at line 42 of file tc_startup.h.
#define MDC_MAXARGS 5 |
Definition at line 31 of file tc_basic.h.
#define PROTO | ( | params | ) | params |
Definition at line 54 of file tc_basic.h.
#define SUCCESS NULL |
Definition at line 30 of file tc_basic.h.
#define tags_equal | ( | a, | |||
b | ) | ((a)==(b)) |
This macro is obsolescent and is only included for backwards compatability. Please use the == operator directly for all new code.
Definition at line 49 of file tc_basic.h.
typedef struct mdc_sblock * mdc_status_t |
TC_API logical ITK__ask_managed_mode | ( | void | ) |
Asks the current state of the tcserver managed mode. Returns true if the tcserver is in 4 tier mode
TC_API void ITK__convert_tag_to_uid | ( | tag_t | aTag, | |
char ** | uid | |||
) |
aTag | (I) |
uid | (OF) |
TC_API void ITK__convert_uid_to_tag | ( | const char * | uid, | |
tag_t * | aTag | |||
) |
uid | (I) |
aTag | (O) |
TCINIT_API void ITK__initialise_tc | ( | int | argc, | |
char ** | argv | |||
) |
TC_API void ITK__set_managed_mode | ( | logical | value | ) |
Sets the current state of the tcserver managed mode. TC_managed_mode is set to true if the tcserver is in 4 tier mode.
value | (I) Set to 1 to indicate server is in managed mode. |
TC_API char* ITK_ask_action | ( | void | ) |
Returns the action passed to the shell program by Application Encapsulation or Release Management (e.g., create, open, save as, etc.). The AE actions are defined in ae.h.
Restrictions:
This function only returns the action code, not any argument to the code. Use ITK_ask_action_argument to get the argument.
TC_API char* ITK_ask_action_argument | ( | const char * | key | ) |
This function returns the argument that was passed to an ITK program from Teamcenter when an external ITK program is invoked through Teamcenter.
There is a special parameter passed to the process that contains the tag of the object being acted on and the action.
In order to get the tag of the dataset, the function should be invoked as follows:
tag_string = ITK_ask_action_argument (NULL);
In order to get the format of the dataset, the function can be invoked as follows:
format_string = ITK_ask_action_argument("-f");
key | (I) |
TC_API int ITK_ask_argument_named_value | ( | const char * | argument, | |
char ** | flag, | |||
char ** | value | |||
) |
Extracts the switch string and the corresponding value string from the argument string passed into the function. The format of the switch-value pair must conform to the following pattern: [^=]*=[^=]*. The switch and the value can be any alpha-numeric string that does not contain the equal (=) character. The equal (=) character is used to delimit the switch and the value.
argument | (I) |
flag | (OF) |
value | (OF) |
TC_API int ITK_ask_bypass | ( | logical * | has_bypass | ) |
Checks if bypass is switched on.
has_bypass | (O) Whether bypass is switched on |
TC_API char* ITK_ask_cli_argument | ( | const char * | key | ) |
Provides support for command line argument parsing.
Restrictions:
The key cannot contain a space character as its last character, if the value expected is to follow immediately. Also, the key cannot exceed 255 characters.
Whenever the last character is a space, the next argument, if any, is returned as the value of the function.
Usage:
command -i=on if a program expects this type of command line, then it should call ITK_get_cli_argument("-i=") to return on.
command -i on if a program expects this type of command line, then it should call ITK_get_cli_argument("-i ") to return on.
key | (I) |
TC_API int ITK_ask_default_date_format | ( | char ** | date_string | ) |
date_string | (OF) |
TC_API int ITK_ask_in_ic_context | ( | logical * | in_ic_context | ) |
in_ic_context | (O) |
TC_API logical ITK_ask_journalling | ( | void | ) |
Asks the current state of the journalling flag as set via ITK_set_journalling. This allows users to develop code that can dynamically switch journalling on or off. Expected use would be in exits and methods.
Returns Journalling_enabled if true; Journalling_suppressed if false.
TC_API int ITK_ask_object | ( | tag_t * | objectId | ) |
Returns the tag of the object passed to your program as an argument. For an Application Encapsulation shell, this is the tag of the selected Dataset. For a follow-up action, this is the tag of the Job.
objectId | (O) |
TC_API int ITK_ask_update_level | ( | int * | update_level | ) |
Returns the version control information.
update_level | (O) Version number of the release |
TC_API int ITK_ask_version | ( | int * | version_number | ) |
Returns the version number of the current Teamcenter release.
version_number | (O) |
TC_API int ITK_ask_version_string | ( | char ** | version_string | ) |
Returns the version number of the current Teamcenter release as a string. The string is MEM_alloc()ed.
version_string | (OF) A string representing the version number |
TCINIT_API int ITK_auto_login | ( | void | ) |
Attempts an automatic login first by assuming sufficient data is available on the command line.
TC_API int ITK_date_to_string | ( | date_t | a_date, | |
char ** | a_string | |||
) |
Converts a date_t structure into a text representation. The date is formatted according to the DefaultDateFormat string defined in time.uil.
a_date | (I) Supplied date_t structure |
a_string | (OF) Text representation of specified date |
TC_API int ITK_exit_module | ( | logical | ignore_unsaved_stuff | ) |
Exits this module.
ignore_unsaved_stuff | (I) This flag is passed to POM_stop. If false, an error is returned if there are unsaved modified objects. |
TCINIT_API int ITK_init_from_cpp | ( | int | argc, | |
char ** | argv | |||
) |
This function initializes the Teamcenter environment for all ITK programs.
Restrictions:
If an ITK program has its own main() routine, this ITK function must be called before any other ITK routines. Otherwise, the ITK program must linked with the ITK_main.o module which performs the same function as this routine.
argc | (I) Argument count from the main() routine |
argv | (I) argc Array of arguments from the main() routine |
TCINIT_API int ITK_init_module | ( | const char * | user_id, | |
const char * | user_password, | |||
const char * | user_group | |||
) |
Attempts a login with the passed-in information.
user_id | (I) The ID of the user to log-in |
user_password | (I) The associated password |
user_group | (I) The group in which to log-in the user |
TC_API int ITK_init_to_login | ( | void | ) |
This function calls as much initialisation code as possible without actually logging in with a user name and password. Calling this before ITK_init_module may make ITK_init_module faster.
TC_API int ITK_initialize_text_services | ( | int | unused | ) |
Initializes the Teamcenter text services. This is necessary to get the correct error strings when you use EMH_get_error_string, or by certain other Teamcenter functions that make use of text services, like forms.
unused | (I) The value is not used anymore |
TCINIT_API void ITK_log_cmdline_args | ( | int | argc, | |
char ** | argv | |||
) |
This function can be used to print command line arguments in syslog for ITK programs.
argc | (I) Argument count from the main() routine |
argv | (I) argc Array of arguments from the main() routine |
TC_API int ITK_reset_obj_edited_in_ic_context | ( | tag_t | obj | ) |
obj | (I) |
TC_API int ITK_set_bypass | ( | logical | on_or_off | ) |
This function allows a system administrator to bypass Access Manager controls on objects. Switching the bypass on typically allows the system administrator to modify, delete, or otherwise access objects at will.
When using the old AM, all access control is disabled by the bypass facility. However, the effect of bypass in the new AM is dependent on the Has Bypass rule in the AM Rules Tree.
The user must be a Teamcenter system administrator.
on_or_off | (I) Whether to switch bypass on (true) or off (false) |
TC_API int ITK_set_in_ic_context | ( | logical | on_or_off | ) |
on_or_off | (I) |
TC_API int ITK_set_journalling | ( | int | on_or_off | ) |
Sets journalling for the ITK, WSOM, AOM, and FL functions of Teamcenter.
on_or_off | (I) Set to 0 to turn journalling off, or to non-zero to turn journalling on. |
TC_API int ITK_set_obj_edited_in_ic_context | ( | tag_t | obj | ) |
obj | (I) |
TC_API int ITK_string_to_date | ( | const char * | a_string, | |
date_t * | a_date | |||
) |
Converts a text string into a date_t structure. The string is assumed to be formatted according to the DefaultDateFormat value in time.uil.
Returns ITK_invalid_date if string is not a valid date.
a_string | (I) Specified date string |
a_date | (O) Date as a date_t structure |
int ITK_user_main | ( | int | , | |
char ** | ||||
) |
TC_API void TC__initialise_tc | ( | int | argc, | |
char ** | argv | |||
) |
TC_API int TC_ask_memory_in_use | ( | void | ) |
Reports SM+OM in-use space. Ignores OM-UNDO
TC_API int TC_ask_memory_statistics | ( | int * | count, | |
char *** | names, | |||
int ** | values | |||
) |
Implemented in memorymonitorwindow.cxx
Returns virtual memory use under various categories (some CPU types give more data than others) (These numbers may be of interest to ITK programmers, but probably not to system administrators)
count | (O) |
names | (OF) count |
values | (OF) count |
TC_API int TC_auto_login | ( | void | ) |
ITK_init_module attempts an automatic login first by assuming sufficient data is available on the command line.
This method is now in libtcinit, and calls register_init_functions() followed by a call to TC_init_module, which is the old ITK_init_module() in infomanager_itk.cxx
TC_API int TC_dump_objects | ( | ) |
TC_API int TC_init_cmain | ( | int | argc, | |
char ** | argv | |||
) |
Routine to initialize the basic system service routines from SYSS module. It also initializes the PREF module.
TC_API int TC_init_module | ( | const char * | users_id, | |
const char * | users_password, | |||
const char * | users_group | |||
) |
The original method, ITK_init_module, initializes the Integration Tool Kit (ITK) for use. \ For convenience, also logs into the POM. This method is now in libtcinit, and calls register_init_functions() followed by a call to TC_init_module. TC_init_module is the rest of the method that was not moved to tcinit.
users_id | (I) |
users_password | (I) |
users_group | (I) |
TC_API int TC_print_memory_statistics | ( | FILE * | output_file | ) |
Prints the current memory statistics into a specified file.
output_file | - File pointer to an already opened output file where the memory statistics will be written out |
output_file | (I) File pointer to an already opened output file where the memory statistics will be written out |
TC_API void TC_report_serious_error | ( | const char * | file_name, | |
int | line_number, | |||
const char * | control_string, | |||
... | ||||
) |
file_name | (I) |
line_number | (I) |
control_string | (I) |
TC_API void TC_write_syslog | ( | const char * | control_string, | |
... | ||||
) |
control_string | (I) |