Tt_message ttdt_file_notice( Tt_message context, Tttk_op op, T_scope scope, const char * pathname, int send_and_destroy );
The ttdt_file_notice() function creates and, optionally, sends a standard ToolTalk notice about a file. Use this function to create the following standard file notices: Created, Deleted, Moved, Reverted, Saved, and Modified.
The ttdt_file_event() function is a higher-level interface than the ttdt_file_notice() function and is the preferred method to send all notices except the Moved notice.
If the context parameter is a value other than zero, messages created by this routine inherit all contexts whose slotname begins with ENV_.
This function creates a notice with the specified op and scope parameters, and sets its file attribute to pathname parameter.
If the send_and_destroy parameter is set, this function sends the message and then destroys it.
If the value of the send_and_destroy parameter is false, the created message is returned; if the value of the send_and_destroy parameter is true, zero is returned.
If an error occurs, an error pointer is returned. Use tt_ptr_error to find out the Tt_status. Table A-7 describes possible errors returned by this function.
Table A-7 Possible Errors Returned by ttdt_file_notice
Error Returned |
Description |
---|---|
The ttsession process is not available. The ToolTalk service tries to restart ttsession if it is not running. This error indicates that the ToolTalk service is either not installed or not installed correctly. |
|
The process identifier specified is out of date or invalid. |
|
There is not enough memory available to perform the operation. |
|
The ToolTalk service has received the maximum amount of active messages (2000) it can properly handle. |
|
The ToolTalk service could not access the ToolTalk database needed for this operation. |
|
The ToolTalk service did not find the specified ToolTalk database in the expected place. |
|
The operation was moved, and the value of the send_and_destroy parameter was true. |
|
The path name was null, or was a ToolTalk error pointer. |