JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
ToolTalk User's Guide
search filter icon
search icon

Document Information

Preface

1.  Introducing the ToolTalk Service

2.  An Overview of the ToolTalk Service

3.  Message Patterns

4.  Setting Up and Maintaining the ToolTalk Processes

5.  Maintaining Application Information

6.  Maintaining Files and Objects Referenced in ToolTalk Messages

7.  Participating in ToolTalk Sessions

8.  Sending Messages

9.  Dynamic Message Patterns

10.  Static Message Patterns

11.  Receiving Messages

12.  Objects

13.  Managing Information Storage

14.  Handling Errors

Retrieving ToolTalk Error Status

Checking ToolTalk Error Status

Returned Value Status

Functions with Natural Return Values

Functions with No Natural Return Values

Returned Pointer Status

Returned Integer Status

Broken Connections

Error Propagation

A.  Migrating from the Classing Engine to the ToolTalk Types Database

B.  A Simple Demonstration of How the ToolTalk Service Works

C.  The ToolTalk Standard Message Sets

D.  Frequently Asked Questions

Glossary

Index

Returned Value Status

The following sections describe the return value status of functions with natural return values and functions with no natural return value.

Functions with Natural Return Values

If a ToolTalk function has a natural return value such as a pointer or an integer, a special error value is returned instead of the real value.

Functions with No Natural Return Values

If a ToolTalk function does not have a natural return value, the return value is an element of Tt_status enum.

To see if there is an error, use the ToolTalk macro tt_is_err, which returns an integer.

If there is an error, you can use the tt_status_message function to obtain the character string that explains the Tt_status code, as shown in .

Example 14-1 Obtaining an Error Explanation

char *spec_id, my_application_name;
Tt_status tterr;

tterr = tt_spec_write(spec_id);
if (tt_is_err(tterr)) {
    fprintf(stderr, “%s: %s\n”, my_application_name,
        tt_status_message(tterr));
}