The STEP Standard
The ISO STEP Standards (ISO 10303) define a methods for the exchange of engineering product data. These standards can be grouped into infrastructure components and industry specific information models. The infrastructure components include the following specifications:
- The EXPRESS information modeling language (Part 11)
- An EXPRESS-driven data exchange file specification (Part 21)
- An EXPRESS-driven data XML file specification (Part 28)
- An EXPRESS-driven application programming interface (SDAI) with bindings to the C, C++, Java, and IDL languages (Parts 22-26)
- A conformance testing framework (Part 31)
- A library of general purpose information models for things like geometry, topology, product identification, dates, times, etc. (The 40-series parts)
The STEP standard includes EXPRESS information models for the exchange of data within different industrial domains. The long list of these application protocols cover mechanical design, analysis, CNC machining, shipbuilding, and other areas.
The SDAI
The Standard Data Access Interface (SDAI) defines an application programming interface to EXPRESS defined data, such as STEP APs. STEP defines the SDAI operations and information models in Part 22 (ISO 10303-22:1998). Separate bindings describe how these operations appear in a specific programming language. SDAI bindings are defined for C, C++, and Java. Bindings for CORBA/IDL and Fortran were begun but never completed. This document describes the binding for C as it is defined in Part 24 (ISO 10303-24:2001) and implemented in ST-Developer.
SDAI bindings come in two flavors: early-bound and late-bound. An early-bound API defines access functions for a specific EXPRESS schema. Early-bound APIs are implemented using an EXPRESS compiler that generates code for a schema.
The SDAI C is a late-bound API. Late-bound APIs have a fixed set of functions that do not change with the schema. A late binding generally uses compiled representation of the EXPRESS schema, called the data dictionary. The SDAI data dictionary is defined in Part 22, Clause 6.
ST-Developer and the SDAI C Binding
This manual describes the ST-Developer implementation of the SDAI C language binding (Part 24). This is a late-bound, C-callable, library of functions for working with STEP data.
ST-Developer also includes a high performance, C++ interface to STEP data called ROSE. A STEP application can use either or both interfaces. The SDAI interface is built using the ROSE library, and includes a set of functions which map between the ROSE and the SDAI views of data. Each interface has certain advantages that you should be aware of when creating an application.
The ROSE library has the following advantages over the SDAI C library:
- Applications can either be early-bound or late bound. The C SDAI is exclusively late-bound.
- The ROSE library contains advanced traversal and manipulation features that are not available in the SDAI. While the SDAI is bound by an ISO specification, the ROSE interface has evolved from years of demanding application development, and contains features attuned to the specific needs of STEP application developers.
- ROSE is the native interface for ST-Developer. In the SDAI, there is a translation layer which maps the SDAI data structures to the corresponding ROSE objects. This mapping makes an SDAI application a bit slower and larger than the corresponding ROSE application.
- The ROSE library provides an object-oriented API which leverages the strengths of the C++ language. The SDAI library provides a function-based interface which is not object-oriented.
The SDAI Library has the following advantages over the ROSE library
- The SDAI library can be used from C applications or C++ code. The ROSE library is exclusively a C++ interface.
- The SDAI is an international standard, making code that uses it portable across SDAI implementations.
Manual Organization
This manual describes the SDAI library and the techniques necessary to develop SDAI applications using ST-Developer.
- SDAI Programming describes the details necessary develop SDAI applications with ST-Developer.
- SDAI Library Changes summarizes the differences between various versions of the SDAI library.
- Function Reference documents the standard SDAI functions.
- Extension Functions documents the ST-Developer extension functions to the SDAI.
- SDAI Schemas describes the EXPRESS information models defined by the SDAI.
Font Conventions
Within paragraphs, functions, keywords, and filenames are shown in bold, such as libsdai.a or /usr/local/bin. Function names are shown with trailing parenthesis, such as sdaiOpenSession() or sdaiGetAttrBN().
Attributes and entities from EXPRESS information models, are indicated in bold. When referring to an attribute of a specific entity, the entity name is separated from the attribute name with a dot such as schema_instance.repository. This refers to the repository attribute of the schema_instance entity.
Function prototypes are listed with each parameter on a separate line and the function name set off in bold as shown below.
SdaiAppInstance sdaiCreateInstance( SdaiModel model, SdaiEntity entity );
Programming examples are shown in a separate paragraph, in a typewriter-style font:
SdaiSet extent = sdaiGetEntityExtentBN (model, "curve"); SditItrerator itor = sdaiCreateIterator (extent); while (sdaiNext(itor)) { SdaiInstance inst=NULL; sdaiGetAggrByItrator (itor, sdaiINSTANCE, &inst); /* Process the value in the instance */ }