Previous Next  

Element: Interface

Document type

Shared_Library_API

Document XPath

/Shared_Library_API/Interface

Schema XPath

/Shared_Library_API/Interface

Description

The Interface element describes one interface to a shared library. Multiple shared library interfaces may be defined, corresponding to different versions of the API supported by the library. This allows you to define separate interfaces for cert and non-cert versions of the library and to define different versions of the interface to maintain backward compatibility when the library is updated.

To define an interface, add an Interface element to your Shared_Library_API document:

<Shared_Library_API ... Name="vThreads">
 <Interface>
  <Version Name="apexMinimal"/> 
 </Interface>
</Shared_Library_API>
			

The Interface element contains a Version element that is used to identify the interface. Applications use this name to link to a specific version of the API.

An interface definition is made up of one or more interface subsets. Using interface subsets allows you to configure multiple interfaces that contain some of the same routines.

If you include any Wind River supplied components in your library, you must include the interface subsets for those components. The interface subset configuration files for the components are located in installDir/vxworks653-2.2/target/vThreads/config/comps/xml.

There are three different ways to add an interface subset to an interface.

You can add the interface subset inline by adding an Interface_Subset element to the Interface element:

<Shared_Library_API ... Name="vThreads">
 <Interface>
  <Version Name="apexMinimal" /> 
  <Interface_Subset>
	 ...
  </Interface_Subset>
 </Interface>
</Shared_Library_API>
			

You can add the interface subset by reference. If the same interface subset is used in more than one interface, you can define the interface subset at the Shared_Library_API level, give it a name, and then reference that name in an Interface_Subset element at the Interface level:

<Shared_Library_API ... Name="vThreads">
 <Interface_Subset Name="apexRoutines">
  ... 
 </Interface_Subset>
 <Interface>
  <Version Name="apexMinimal"/> 
  <Interface_Subset NameRef="apexRoutines"/> 
 </Interface>
</Shared_Library_API>
			

You can include the interface subset from an ApplicationDescription document in an external file using an xi:include element:

<Shared_Library_API ... Name="vThreads">
 <Interface>
  <Version Name="apexMinimal" /> 
  <xi:include href="apex.xml" /> 
 </Interface>
</Shared_Library_API>
			

In the example above, the xi:include must give a full or relative path to the included file.

All three methods can be mixed freely in defining a single interface.

Use

Required

Children

Interface_Subset

Version

xi:include

Attributes

None

Restrictions

None




Generated on 2007-10-15 17:17:22.