libs-base/Documentation/gsdoc/GSXMLAttribute.html
CaS 0a86bba7b0 Documentation regeneration and XML parsing fixes/updates.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@9698 72102866-910b-0410-8b05-ffd578937521
2001-04-25 14:19:57 +00:00

203 lines
4.8 KiB
HTML

<html><head>
<title>GSXMLAttribute</title>
</head>
<body>
<a href ="GSXMLNode.html">[Previous] </a>
<a href ="GSXML.html">[Up] </a>
<a href ="GSXMLDocument.html">[Next] </a>
<h1>GSXMLAttribute</h1>
<h3>Authors </h3>
<dl>
<dt>Michael Pakhantsov
<dd>
<dt>Richard Frith-Macdonald
<dd>
</dl>
<p>Version: $Revision$</p>
<p>Date: $Date$</p>
<h2><a name ="cont-0">GSXMLAttribute</a></h2>
<h2><a name ="GSXMLAttribute">GSXMLAttribute</a></h2>
<p><b>Declared in: </b> GSXML.h</p>
<p><b>Inherits from: </b> GSXMLNode</p>
<hr>
XML Attribute.
<h2>Instance Variables </h2>
<ul>
</ul>
<h2>Methods </h2>
<ul>
<li ><a href ="GSXMLAttribute.html#method-4">+attributeFrom:</a>
<li ><a href ="GSXMLAttribute.html#method-0">+attributeWithNode:name:value:</a>
<li ><a href ="GSXMLAttribute.html#method-1">+descriptionFromType:</a>
<li ><a href ="GSXMLAttribute.html#method-2">+typeFromDescription:</a>
<li ><a href ="GSXMLAttribute.html#method-5">-initFrom:</a>
<li ><a href ="GSXMLAttribute.html#method-3">-initWithNode:name:value:</a>
<li ><a href ="GSXMLAttribute.html#method-6">-lib</a>
<li ><a href ="GSXMLAttribute.html#method-7">-name</a>
<li ><a href ="GSXMLAttribute.html#method-9">-next</a>
<li ><a href ="GSXMLAttribute.html#method-11">-prev</a>
<li ><a href ="GSXMLAttribute.html#method-12">-type</a>
<li ><a href ="GSXMLAttribute.html#method-13">-typeDescription</a>
<li ><a href ="GSXMLAttribute.html#method-8">-value</a>
</ul>
<hr><h2>Class Methods </h2>
<h3><a name ="method-0">attributeWithNode:name:value:</a></h3>
+ (GSXMLAttribute*) <b>attributeWithNode:</b> (GSXMLNode*)node <b>name:</b> (NSString*)name <b>value:</b> (NSString*)value;<br>
<p>
Create a new property carried by a node.
</p>
<hr>
<h3><a name ="method-1">descriptionFromType:</a></h3>
+ (NSString*) <b>descriptionFromType:</b> (int)type;<br>
<p>
Return the string constant value for the attribute
type given.
</p>
<hr>
<h3><a name ="method-2">typeFromDescription:</a></h3>
+ (int) <b>typeFromDescription:</b> (NSString*)desc;<br>
<p>
Return the numeric constant value for the attribute
type named. This method is inefficient, so the returned
value should be saved for re-use later. The possible
values are -
</p>
<ul>
<li >XML_ATTRIBUTE_CDATA
<li >XML_ATTRIBUTE_ID
<li >XML_ATTRIBUTE_IDREF
<li >XML_ATTRIBUTE_IDREFS
<li >XML_ATTRIBUTE_ENTITY
<li >XML_ATTRIBUTE_ENTITIES
<li >XML_ATTRIBUTE_NMTOKEN
<li >XML_ATTRIBUTE_NMTOKENS
<li >XML_ATTRIBUTE_ENUMERATION
<li >XML_ATTRIBUTE_NOTATION
</ul>
<hr>
<h3><a name ="method-4">attributeFrom:</a></h3>
+ (GSXMLAttribute*) <b>attributeFrom:</b> (void*)data;<br>
<p>
Creation of a new Attribute from libxml data.
</p>
<hr>
<hr><h2>Instances Methods </h2>
<h3><a name ="method-3">initWithNode:name:value:</a></h3>
- (id) <b>initWithNode:</b> (GSXMLNode*)node <b>name:</b> (NSString*)name <b>value:</b> (NSString*)value;<br>
<p>
Create a new property carried by a node.
</p>
<hr>
<h3><a name ="method-5">initFrom:</a></h3>
<b>This is the designated initialiser </b><br>
- (id) <b>initFrom:</b> (void*)data;<br>
<p>
Creation of a new Attribute from libxml data.
</p>
<hr>
<h3><a name ="method-6">lib</a></h3>
- (void*) <b>lib</b>;<br>
<p>
Return pointer to xmlAttribute structure.
</p>
<hr>
<h3><a name ="method-7">name</a></h3>
- (NSString*) <b>name</b>;<br>
<p>
Return a Attribute name.
</p>
<hr>
<h3><a name ="method-8">value</a></h3>
- (NSString*) <b>value</b>;<br>
<p>
Return a value of this attribute.
</p>
<hr>
<h3><a name ="method-9">next</a></h3>
- (GSXMLAttribute*) <b>next</b>;<br>
<p>
Return next Attribute.
</p>
<a name ="label-10">example </a>
<pre>
id a = [node properties];
NSLog(@"n1 property name - %@ value - %@", [a name], [a value]);
while ((a = [a next]) != nil)
{
NSLog(@"n1 property name - %@ value - %@", [a name], [a value]);
}
</pre>
<hr>
<h3><a name ="method-11">prev</a></h3>
- (GSXMLAttribute*) <b>prev</b>;<br>
<p>
Return previous Attribute.
</p>
<hr>
<h3><a name ="method-12">type</a></h3>
- (int) <b>type</b>;<br>
<p>
Return the numeric type code for this attribute.
</p>
<hr>
<h3><a name ="method-13">typeDescription</a></h3>
- (NSString*) <b>typeDescription</b>;<br>
<p>
Return the string type code for this attribute.
</p>
<hr>
</body>
</html>