LoadSystemMethodInfo (XmlDoc subroutine): Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (1 revision)
mNo edit summary
 
(29 intermediate revisions by 5 users not shown)
Line 1: Line 1:
<span style="font-size:120%; color:black"><b>Load info about system methods into XmlDoc</b></span>
{{Template:XmlDoc:LoadSystemMethodInfo subtitle}}
[[Category:XmlDoc methods|LoadSystemMethodInfo subroutine]]
<var>LoadSystemMethodInfo</var> loads an <var>XmlDoc</var> with information about methods in classes selected by a "pattern" argument.  This method is primarily intended for <var class="product">SOUL</var> products delivered by Rocket Software, and the schema of the document may change from release to release. Users of [[SoulEdit]] (V7.5 and later) can see this method in action via the INFO command which provides introspection into specified methods.
[[Category:XmlDoc API methods]]
 
[[Category:System methods]]
==Syntax==
<!--DPL?? Category:XmlDoc methods|LoadSystemMethodInfo subroutine: Load info about system methods into XmlDoc-->
{{Template:XmlDoc:LoadSystemMethodInfo syntax}}
<!--DPL?? Category:XmlDoc API methods|LoadSystemMethodInfo (XmlDoc subroutine): Load info about system methods into XmlDoc-->
<!--DPL?? Category:System methods|LoadSystemMethodInfo (XmlDoc subroutine): Load info about system methods into XmlDoc-->
<p>
LoadSystemMethodInfo is a member of the [[XmlDoc class]].
</p>


This method loads an XmlDoc with information about methods in
===Syntax terms===
classes selected by a &ldquo;pattern&rdquo; argument.
<table class="syntaxTable">
This method is primarily intended for User Language products delivered
<tr><th>doc</th>
by Sirius Software, and the schema of the document may change from release
<td>An expression that points to the <var>XmlDoc</var> to contain the selected method information.</td></tr>
to release.
===Syntax===
  Call doc:LoadSystemMethodInfo(pattern)


====Syntax Terms====
<tr><th>pattern</th>
<dl>
<td>A string whose case is ignored and that can have any of the following forms:
<table class="syntaxNested">


<dt>doc
<tr><th>methodPattern</th>
<dd>An expression that points to the XmlDoc to contain the
<td>This selects, from any system class, all methods that match the specified pattern.</td></tr>
selected method information.
<dt>pattern
<dd>A string whose case is ignored and
which can have any of the following forms:
<dl>
<dt><i>methodPattern</i>
<dd>This selects, from any system class, all methods
which match the specified pattern.
<dt><i>classPattern':'methodPattern</i>
<dd>This selects, from any system class matching ''classPattern'',
all methods which match ''methodPattern''.
<dt><i>'System:'classPattern':'methodPattern</i>
<dd>This is the same as ''classPattern':'methodPattern''.
</dl>


</dl>
<tr><th>classPattern<var>:</var>methodPattern</th>
<td>This selects, from any system class matching <var class="term">classPattern</var>, all methods that match <var class="term">methodPattern</var>. </td></tr>


===Usage Notes===
<tr><th><var>System:</var>classPattern<var>:</var>methodPattern</th>
<td>This is the same as <var class="term">classPattern<var>:</var>methodPattern</var>. </td></tr>
</table></td></tr>


<tr><th><var>ShowBase</var></th>
<td>A <var>[[Enumerations#Using_Boolean_enumerations|Boolean]]</var> enumeration that specifies how to handle base and extension classes:
<ul>
<ul>
<li>The &ldquo;New&rdquo; method will only be displayed if either is
<li>If <var>False</var>, the default, then base classes are omitted from the output <var>XmlDoc</var>, and the methods in extension classes include methods from their base classes. </li>
true:
 
<ul>
<li>If <var>True</var>, then base classes (which match the selection pattern) are included in the output <var>XmlDoc</var>, and the members of base classes are not included in extension classes. </li>
<li>The ''methodPattern'' is the string <tt>New</tt>.
<li>The New method has any arguments.
</ul>
<li>LoadSystemMethodInfo will not display classes in the module LOCAL,
if they are selected by a pattern
(that is, ''pattern'' contains a wildcard character), or if
there is no ''classPattern'' component.
</ul>
</ul>
This [[Notation conventions for methods#Named parameters|name required]] argument was new in version 7.9 of the <var class="product">Sirius Mods</var>.</td></tr>
</table>


===Example===
==Usage notes==
<ul>
<li>The <var>New</var> method will only be displayed if either is true:
<ul>
<li>The ''methodPattern'' is the string <code>New</code>.</li>
<li>The <var>New</var> method has any arguments. </li>
</ul></li>


The following request displays the class data for the AddAttribute method:
<li><var>LoadSystemMethodInfo</var> will not display classes in the module LOCAL, if they are selected by a pattern (that is, ''pattern'' contains a wildcard character), or if there is no ''classPattern'' component.</li>
<pre>
</ul>
    Begin
    %d is Object XmlDoc
    %d = New
    %d:LoadSystemMethodInfo('AddAttribute')
    %d:Print
    End
</pre>


The example result follows.
==Examples==
<pre>
The following request displays the class data for the <var>[[AddAttribute (XmlNode function)|AddAttribute]]</var> method:
    <classes selection="AddAttribute">
<p class="code">begin
      <class name="XMLNODE" system="yes" new="no" discard="no">
  %d is object xmlDoc
        <methods module="JSOPF" offset="00000CBC">
  %d = new
          <method name="ADDATTRIBUTE" type="function" callable="yes">
  %d:loadSystemMethodInfo('AddAttribute')
  %d:print
end
</p>
The example result follows:
<p class="output"><classes selection="AddAttribute">
  <class name="XmlNode" system="yes" new="no" discard="no" docObject="nod">
      <methods module="JSOPF" offset="00002038">
        <method name="AddAttribute" type="function" callable="yes" requiredProdNum="35" desc="Add Attribute to Element node">
             <result>
             <result>
              <type name="Object" class="XMLNODE"/>
              <type name="Object" class="XmlNode"/>
             </result>
             </result>
             <arg>
             <arg docArg="name">
              <type name="Longstring"/>
              <type name="Unicode"/>
             </arg>
             </arg>
             <arg>
             <arg docArg="value">
              <type name="Longstring"/>
              <type name="Unicode"/>
             </arg>
             </arg>
             <arg optional="yes">
             <arg optional="yes" docArg="uri">
              <type name="Longstring"/>
              <type name="Unicode"/>
             </arg>
             </arg>
          </method>
        </method>
        </methods>
      </methods>
      </class>
  </class>
    </classes>
</classes>
</pre>
</p>
 
==See also==
{{Template:XmlDoc:LoadSystemMethodInfo footer}}

Latest revision as of 13:38, 11 August 2015

Load info about system methods into this XmlDoc (XmlDoc class)

LoadSystemMethodInfo loads an XmlDoc with information about methods in classes selected by a "pattern" argument. This method is primarily intended for SOUL products delivered by Rocket Software, and the schema of the document may change from release to release. Users of SoulEdit (V7.5 and later) can see this method in action via the INFO command which provides introspection into specified methods.

Syntax

doc:LoadSystemMethodInfo( pattern, [ShowBase= boolean])

Syntax terms

doc An expression that points to the XmlDoc to contain the selected method information.
pattern A string whose case is ignored and that can have any of the following forms:
methodPattern This selects, from any system class, all methods that match the specified pattern.
classPattern:methodPattern This selects, from any system class matching classPattern, all methods that match methodPattern.
System:classPattern:methodPattern This is the same as classPattern:methodPattern.
ShowBase A Boolean enumeration that specifies how to handle base and extension classes:
  • If False, the default, then base classes are omitted from the output XmlDoc, and the methods in extension classes include methods from their base classes.
  • If True, then base classes (which match the selection pattern) are included in the output XmlDoc, and the members of base classes are not included in extension classes.
This name required argument was new in version 7.9 of the Sirius Mods.

Usage notes

  • The New method will only be displayed if either is true:
    • The methodPattern is the string New.
    • The New method has any arguments.
  • LoadSystemMethodInfo will not display classes in the module LOCAL, if they are selected by a pattern (that is, pattern contains a wildcard character), or if there is no classPattern component.

Examples

The following request displays the class data for the AddAttribute method:

begin %d is object xmlDoc %d = new %d:loadSystemMethodInfo('AddAttribute') %d:print end

The example result follows:

<classes selection="AddAttribute"> <class name="XmlNode" system="yes" new="no" discard="no" docObject="nod"> <methods module="JSOPF" offset="00002038"> <method name="AddAttribute" type="function" callable="yes" requiredProdNum="35" desc="Add Attribute to Element node"> <result> <type name="Object" class="XmlNode"/> </result> <arg docArg="name"> <type name="Unicode"/> </arg> <arg docArg="value"> <type name="Unicode"/> </arg> <arg optional="yes" docArg="uri"> <type name="Unicode"/> </arg> </method> </methods> </class> </classes>

See also