Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > bad97183153701b09df5fae1052b1c30 > files > 3570

crystalspace-doc-1.2.1-5mdv2010.0.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Crystal Space 1.2.1: iScriptObject Struct Reference (Crystal Space 1.2.1 Public API Reference)</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<table border="0" cellpadding="0" cellspacing="0" width="100%" class="head">
 <tr height="59">
  <td class="head" width="202" valign="bottom" style="padding-left:0;"><a href="http://www.crystalspace3d.org/"><img src="csblur.png" width="236" height="59" alt="CrystalSpace" border="0"></a></td>
  <td class="head"><h2>Public API Reference</h2></td>
 </tr>
 <tr height="11">
  <td colspan="2" class="headshadow" valign="top" style="padding-left:0;"><img src="csblurb.png" width="236" height="11" alt="" border="0"></td>
 </tr>
</table>
<div class="content">
<!-- Generated by Doxygen 1.5.3 -->
<div class="tabs">
  <ul>
    <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
    <li><a href="modules.html"><span>Modules</span></a></li>
    <li><a href="namespaces.html"><span>Namespaces</span></a></li>
    <li class="current"><a href="classes.html"><span>Classes</span></a></li>
    <li><a href="files.html"><span>Files</span></a></li>
    <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
  </ul>
</div>
<div class="tabs">
  <ul>
    <li><a href="classes.html"><span>Alphabetical&nbsp;List</span></a></li>
    <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
    <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
    <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
  </ul>
</div>
<h1>iScriptObject Struct Reference</h1><!-- doxytag: class="iScriptObject" --><!-- doxytag: inherits="iBase" -->This provides the interface to an object in an object-oriented scripting language.  
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="script_8h-source.html">ivaria/script.h</a>&gt;</code>
<p>
<div class="dynheader">
Inheritance diagram for iScriptObject:</div>
<div class="dynsection">
<p><center><img src="structiScriptObject__inherit__graph.png" border="0" usemap="#iScriptObject__inherit__map" alt="Inheritance graph"></center>
<map name="iScriptObject__inherit__map">
<area shape="rect" href="classscfImplementation1.html" title="scfImplementation1\&lt; csScriptObjectCommon, iScriptObject \&gt;" alt="" coords="5,161,427,188"><area shape="rect" href="structiBase.html" title="This is the basic interface: all other interfaces should be derived from this one..." alt="" coords="188,7,244,33"><area shape="rect" href="classcsScriptObjectCommon.html" title="This intermediate class can be subclassed by implementors of iScriptObject." alt="" coords="129,239,303,265"></map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center></div>

<p>
<a href="structiScriptObject-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classcsPtr.html">csPtr</a><br>
&lt; <a class="el" href="structiScriptValue.html">iScriptValue</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#648a202dfe9bce6ca194a3ea0e6b38ad">Call</a> (const char *name, const <a class="el" href="classcsRefArray.html">csRefArray</a>&lt; <a class="el" href="structiScriptValue.html">iScriptValue</a> &gt; &amp;args=<a class="el" href="classcsRefArray.html">csRefArray</a>&lt; <a class="el" href="structiScriptValue.html">iScriptValue</a> &gt;())=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Calls a method in the object.  <a href="#648a202dfe9bce6ca194a3ea0e6b38ad"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classcsPtr.html">csPtr</a><br>
&lt; <a class="el" href="structiScriptValue.html">iScriptValue</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#d81a5d92dc87c43ba588be50b8cb0e8c">Get</a> (const char *name)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the value of a property in the script object.  <a href="#d81a5d92dc87c43ba588be50b8cb0e8c"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual const <a class="el" href="classcsRef.html">csRef</a><br>
&lt; <a class="el" href="structiString.html">iString</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#be5da03ed5f151d9778c1d4edfba3cb6">GetClass</a> () const =0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the name of this object's class.  <a href="#be5da03ed5f151d9778c1d4edfba3cb6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#6d5c93ac054b188e80491f8c0b463ce5">GetPointer</a> ()=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">If the object is from the cspace module, this will return its pointer.  <a href="#6d5c93ac054b188e80491f8c0b463ce5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="structiScript.html">iScript</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#1780349ab8f38544c2911488a2ed620b">GetScript</a> ()=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns a reference to the <a class="el" href="structiScript.html" title="This provides the interface to a scripting language interpreter.">iScript</a> to which this object belongs.  <a href="#1780349ab8f38544c2911488a2ed620b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#09b8d49d912f544d92b19b39e3862441">IsA</a> (const char *) const =0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns a boolean specifying whether or not the object "is a" or is derived from the named class.  <a href="#09b8d49d912f544d92b19b39e3862441"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#cb5eebb45500ca4e7b9d373f59e2d17c">IsType</a> (const char *) const =0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deprecated version of <a class="el" href="structiScriptObject.html#09b8d49d912f544d92b19b39e3862441" title="Returns a boolean specifying whether or not the object &quot;is a&quot; or is derived...">IsA()</a>.  <a href="#cb5eebb45500ca4e7b9d373f59e2d17c"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#819ed9b9f2eef80a1e7b6cccc2f164eb">Set</a> (const char *name, <a class="el" href="structiScriptValue.html">iScriptValue</a> *value)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets the value of a property in the script object.  <a href="#819ed9b9f2eef80a1e7b6cccc2f164eb"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structiScriptObject.html#cf68f97511740f07c8a7d2ee0a66fa4e">SetPointer</a> (void *)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">If the object is from the cspace module, this will allow you to change the reference to point to another object of the same class.  <a href="#cf68f97511740f07c8a7d2ee0a66fa4e"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This provides the interface to an object in an object-oriented scripting language. 
<p>
Main ways to get pointers to this interface:<ul>
<li><a class="el" href="structiScript.html#4c35384226576c32a2e89e2687fbeaa4" title="Creates an object in the script.">iScript::New()</a></li><li><a class="el" href="structiScriptValue.html#2e20ce8e2873bd17df256253d2c7ad47" title="Returns this value as a reference to a script object.">iScriptValue::GetObject()</a> </li></ul>

<p>Definition at line <a class="el" href="script_8h-source.html#l00102">102</a> of file <a class="el" href="script_8h-source.html">script.h</a>.</p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="648a202dfe9bce6ca194a3ea0e6b38ad"></a><!-- doxytag: member="iScriptObject::Call" ref="648a202dfe9bce6ca194a3ea0e6b38ad" args="(const char *name, const csRefArray&lt; iScriptValue &gt; &amp;args=csRefArray&lt; iScriptValue &gt;())=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classcsPtr.html">csPtr</a>&lt;<a class="el" href="structiScriptValue.html">iScriptValue</a>&gt; iScriptObject::Call           </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classcsRefArray.html">csRefArray</a>&lt; <a class="el" href="structiScriptValue.html">iScriptValue</a> &gt; &amp;&nbsp;</td>
          <td class="paramname"> <em>args</em> = <code><a class="el" href="classcsRefArray.html">csRefArray</a>&lt;&nbsp;<a class="el" href="structiScriptValue.html">iScriptValue</a>&nbsp;&gt;()</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Calls a method in the object. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>The name of the method to call. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>args</em>&nbsp;</td><td>An optional array of arguments to pass to the method. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>The return value of the method. If the named method does not exist or encounters a runtime error then it returns 0. If the method returns no value then it returns an <a class="el" href="structiScriptValue.html" title="This provides the interface to a value stored in the scripting language&#39;s native...">iScriptValue</a> with a bitmask of 0. </dd></dl>
<dl class="remark" compact><dt><b>Remarks:</b></dt><dd>Scripting languages that support pass-by-reference may change the values of the arguments. </dd></dl>

<p>Implemented in <a class="el" href="classcsScriptObjectCommon.html#e3b439ad9a523ac6ef8b09d398012c0a">csScriptObjectCommon</a>.</p>

</div>
</div><p>
<a class="anchor" name="d81a5d92dc87c43ba588be50b8cb0e8c"></a><!-- doxytag: member="iScriptObject::Get" ref="d81a5d92dc87c43ba588be50b8cb0e8c" args="(const char *name)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classcsPtr.html">csPtr</a>&lt;<a class="el" href="structiScriptValue.html">iScriptValue</a>&gt; iScriptObject::Get           </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the value of a property in the script object. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>The name of the property. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>The value of the property, or 0 if it does not exist. </dd></dl>
<dl class="remark" compact><dt><b>Remarks:</b></dt><dd>The minimum requirement for implementors of this method is that it work with objects from the cspace module. An implementation may support other classes, but if not then behaviour may be undefined when attempting to use such classes. </dd></dl>

<p>Implemented in <a class="el" href="classcsScriptObjectCommon.html#ee17cf93439dd148db8a1018b6cce61a">csScriptObjectCommon</a>.</p>

</div>
</div><p>
<a class="anchor" name="be5da03ed5f151d9778c1d4edfba3cb6"></a><!-- doxytag: member="iScriptObject::GetClass" ref="be5da03ed5f151d9778c1d4edfba3cb6" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="classcsRef.html">csRef</a>&lt;<a class="el" href="structiString.html">iString</a>&gt; iScriptObject::GetClass           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Returns the name of this object's class. 
<p>
If the object is from the cspace module, the name will be returned without the cspace namespace qualifier. 
</div>
</div><p>
<a class="anchor" name="6d5c93ac054b188e80491f8c0b463ce5"></a><!-- doxytag: member="iScriptObject::GetPointer" ref="6d5c93ac054b188e80491f8c0b463ce5" args="()=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void* iScriptObject::GetPointer           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
If the object is from the cspace module, this will return its pointer. 
<p>
If it is not from the cspace module, the behaviour will be undefined.<p>
Some implementations may wish to extend the behaviour of this method to return pointers to other types of object, but that would be specific to the implementation. 
</div>
</div><p>
<a class="anchor" name="1780349ab8f38544c2911488a2ed620b"></a><!-- doxytag: member="iScriptObject::GetScript" ref="1780349ab8f38544c2911488a2ed620b" args="()=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="structiScript.html">iScript</a>* iScriptObject::GetScript           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Returns a reference to the <a class="el" href="structiScript.html" title="This provides the interface to a scripting language interpreter.">iScript</a> to which this object belongs. 
<p>

</div>
</div><p>
<a class="anchor" name="09b8d49d912f544d92b19b39e3862441"></a><!-- doxytag: member="iScriptObject::IsA" ref="09b8d49d912f544d92b19b39e3862441" args="(const char *) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool iScriptObject::IsA           </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Returns a boolean specifying whether or not the object "is a" or is derived from the named class. 
<p>
This may or may not be a class from the cspace module. Also, such classes may be specified with or without the cspace namespace qualifier. 
</div>
</div><p>
<a class="anchor" name="cb5eebb45500ca4e7b9d373f59e2d17c"></a><!-- doxytag: member="iScriptObject::IsType" ref="cb5eebb45500ca4e7b9d373f59e2d17c" args="(const char *) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool iScriptObject::IsType           </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Deprecated version of <a class="el" href="structiScriptObject.html#09b8d49d912f544d92b19b39e3862441" title="Returns a boolean specifying whether or not the object &quot;is a&quot; or is derived...">IsA()</a>. 
<p>

<p>Implemented in <a class="el" href="classcsScriptObjectCommon.html#9531a46cb2389949b95ba7a053bef979">csScriptObjectCommon</a>.</p>

</div>
</div><p>
<a class="anchor" name="819ed9b9f2eef80a1e7b6cccc2f164eb"></a><!-- doxytag: member="iScriptObject::Set" ref="819ed9b9f2eef80a1e7b6cccc2f164eb" args="(const char *name, iScriptValue *value)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool iScriptObject::Set           </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structiScriptValue.html">iScriptValue</a> *&nbsp;</td>
          <td class="paramname"> <em>value</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Sets the value of a property in the script object. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>The name of the property. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>value</em>&nbsp;</td><td>The value that the property will be set to. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>False if the named property does not exist or cannot be set. </dd></dl>
<dl class="remark" compact><dt><b>Remarks:</b></dt><dd>The minimum requirement for implementors of this method is that it work with objects from the cspace module. An implementation may support other classes, but if not then behaviour may be undefined when attempting to use such classes. </dd></dl>

<p>Implemented in <a class="el" href="classcsScriptObjectCommon.html#967152e96305bfc54e04a2986eafc533">csScriptObjectCommon</a>.</p>

</div>
</div><p>
<a class="anchor" name="cf68f97511740f07c8a7d2ee0a66fa4e"></a><!-- doxytag: member="iScriptObject::SetPointer" ref="cf68f97511740f07c8a7d2ee0a66fa4e" args="(void *)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool iScriptObject::SetPointer           </td>
          <td>(</td>
          <td class="paramtype">void *&nbsp;</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
If the object is from the cspace module, this will allow you to change the reference to point to another object of the same class. 
<p>
NOTE: This is not guaranteed to work, is deprecated, and will be removed! 
<p>Implemented in <a class="el" href="classcsScriptObjectCommon.html#99fce64b3ff9cf097918aa8a898e4ec5">csScriptObjectCommon</a>.</p>

</div>
</div><p>
<hr>The documentation for this struct was generated from the following file:<ul>
<li>ivaria/<a class="el" href="script_8h-source.html">script.h</a></ul>
<hr size="1"><address><small>Generated for Crystal Space 1.2.1 by 
<a href="http://www.doxygen.org/index.html">doxygen</a> 1.5.3 
</small></address> </div></body> </html>