Interfaces

Similarly, the XML for interface symbols contain the common elements. In addition, they retain elements and attributes associated with SIDL interfaces. These include any extensions, parent interfaces it implements, and its methods. Method information includes its name, communication mode, short name, name extension (for languages that don't support method overloading), comment, return type, argument list, and exception list.

For example, the XML representation of sidl.BaseInterface is:


<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE Symbol PUBLIC "-//CCA//SIDL Symbol DTD v1.1//EN" "SIDL.dtd">
<Symbol>
   <SymbolName name="sidl.BaseInterface" version="0.8.2"/>
   <Metadata date="20030320 13:29:02 PST">
      <MetadataEntry key="source-url" value="file:/home/dahlgren/RELEASE/linux_kcc/share/../../babel/runtime/sidl/sidl.sidl"/>
      <MetadataEntry key="source-line" value="47"/>
      <MetadataEntry key="babel-version" value="0.8.2"/>
   </Metadata>
   <Comment>
Every interface in &lt;code&gt;SIDL&lt;/code&gt; implicitly inherits
from &lt;code&gt;BaseInterface&lt;/code&gt;, and it is implemented
by &lt;code&gt;BaseClass&lt;/code&gt; below.
   </Comment>
   <Interface>
      <ExtendsBlock/>
      <AllParentInterfaces/>
      <MethodsBlock>
         <Method communication="normal" copy="false" definition="abstract" extension="" shortname="addRef">
            <Comment>
&lt;p&gt;
Add one to the intrinsic reference count in the underlying object.
Object in &lt;code&gt;SIDL&lt;/code&gt; have an intrinsic reference count.
Objects continue to exist as long as the reference count is
positive. Clients should call this method whenever they
create another ongoing reference to an object or interface.
&lt;/p&gt;
&lt;p&gt;
This does not have a return value because there is no language
independent type that can refer to an interface or a
class.
&lt;/p&gt;
            </Comment>
            <Type type="void"/>
            <ArgumentList/>
            <ThrowsList/>
         </Method>
         <Method communication="normal" copy="false" definition="abstract" extension="" shortname="deleteRef">
            <Comment>
Decrease by one the intrinsic reference count in the underlying
object, and delete the object if the reference is non-positive.
Objects in &lt;code&gt;SIDL&lt;/code&gt; have an intrinsic reference count.
Clients should call this method whenever they remove a
reference to an object or interface.
            </Comment>
            <Type type="void"/>
            <ArgumentList/>
            <ThrowsList/>
         </Method>
         <Method communication="normal" copy="false" definition="abstract" extension="" shortname="isSame">
            <Comment>
Return true if and only if &lt;code&gt;obj&lt;/code&gt; refers to the same
object as this object.
            </Comment>
            <Type type="boolean"/>
            <ArgumentList>
               <Argument copy="false" mode="in" name="iobj">
                  <Type type="symbol">
                     <SymbolName name="sidl.BaseInterface" version="0.8.2"/>
                  </Type>
               </Argument>
            </ArgumentList>
            <ThrowsList/>
         </Method>
         <Method communication="normal" copy="false" definition="abstract" extension="" shortname="queryInt">
            <Comment>
Check whether the object can support the specified interface or
class.  If the &lt;code&gt;SIDL&lt;/code&gt; type name in &lt;code&gt;name&lt;/code&gt;
is supported, then a reference to that object is returned with the
reference count incremented.  The callee will be responsible for
calling &lt;code&gt;deleteRef&lt;/code&gt; on the returned object.  If
the specified type is not supported, then a null reference is
returned.
            </Comment>
            <Type type="symbol">
               <SymbolName name="sidl.BaseInterface" version="0.8.2"/>
            </Type>
            <ArgumentList>
               <Argument copy="false" mode="in" name="name">
                  <Type type="string"/>
               </Argument>
            </ArgumentList>
            <ThrowsList/>
         </Method>
         <Method communication="normal" copy="false" definition="abstract" extension="" shortname="isType">
            <Comment>
Return whether this object is an instance of the specified type.
The string name must be the &lt;code&gt;SIDL&lt;/code&gt; type name.  This
routine will return &lt;code&gt;true&lt;/code&gt; if and only if a cast to
the string type name would succeed.
            </Comment>
            <Type type="boolean"/>
            <ArgumentList>
               <Argument copy="false" mode="in" name="name">
                  <Type type="string"/>
               </Argument>
            </ArgumentList>
            <ThrowsList/>
         </Method>
         <Method communication="normal" copy="false" definition="abstract" extension="" shortname="getClassInfo">
            <Comment>
Return the meta-data about the class implementing this interface.
            </Comment>
            <Type type="symbol">
               <SymbolName name="sidl.ClassInfo" version="0.8.2"/>
            </Type>
            <ArgumentList/>
            <ThrowsList/>
         </Method>
      </MethodsBlock>
   </Interface>
</Symbol>





babel-0.10.2
users_guide Last Modified 2005-03-23

http://www.llnl.gov/CASC/components
components@llnl.gov