libs-base/Documentation/gsdoc/GSXMLDocument.gsdoc
CaS 8f6392e943 Fixed typo in last mod
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@9280 72102866-910b-0410-8b05-ffd578937521
2001-03-03 09:58:53 +00:00

165 lines
4.3 KiB
XML

<?xml version="1.0"?>
<!DOCTYPE gsdoc PUBLIC "-//GNUstep//DTD gsdoc 0.6.6//EN" "http://www.gnustep.org/gsdoc-0_6_6.xml">
<gsdoc base="GSXMLDocument" next="GSXMLParser" up="GSXML" prev="GSXMLAtrribute">
<head>
<title>GSXMLDocument</title>
<author name="Michael Pakhantsov">
<email address="mishel@berest.dp.ua"/>
</author>
<version>$Revision$</version>
<date>$Date$</date>
</head>
<body>
<chapter>
<heading>GSXMLDocument</heading>
<class name="GSXMLDocument" super="NSObject">
<declared>GSXML.h</declared>
<desc>
<p>
XML Document.
</p>
</desc>
<method type="GSXMLDocument*" factory="yes">
<sel>documentWithVersion:</sel>
<arg type="NSString*">version</arg>
<desc>
<p>
Creation of a new XML document.
</p>
<example>
id d = [GSXMLDocument documentWithVersion: @"1.0"];
[d setRoot: [d makeNodeWithNamespace: nil name: @"plist" content: nil]];
[[d root] setProp: @"version" value: @"0.9"];
n1 = [[d root] makeChildWithNamespace: nil name: @"dict" content: nil];
[n1 makeComment: @" this is a comment "];
[n1 makePI: @"pi1" content: @"this is a process instruction"];
[n1 makeChildWithNamespace: nil name: @"key" content: @"Year Of Birth"];
[n1 makeChildWithNamespace: nil name: @"integer" content: @"65"];
[n1 makeChildWithnamespace: nil name: @"key" content: @"Pets Names"];
</example>
</desc>
</method>
<method type="id">
<sel>initWithVersion:</sel>
<arg type="NSString*">version</arg>
<desc>
<p>
Creation of a new XML document.
</p>
</desc>
</method>
<method type="GSXMLDocument*" factory="yes">
<sel>documentFrom:</sel>
<arg type="void*">data</arg>
<desc>
<p>
Creation of a new Document from libxml data.
</p>
</desc>
</method>
<method type="id" init="yes">
<sel>initFrom:</sel>
<arg type="void*">data</arg>
<desc>
<p>
Creation of a new Document from libxml data.
</p>
</desc>
</method>
<method type="NSString*">
<sel>version</sel>
<desc>
<p>
Return the version of document.
</p>
</desc>
</method>
<method type="NSString*">
<sel>encoding</sel>
<desc>
<p>
Return the encoding of document.
</p>
</desc>
</method>
<method type="void">
<sel>save:</sel>
<arg type="NSString*">filename</arg>
<desc>
<p>
Save XML document.
</p>
</desc>
</method>
<method type="void*">
<sel>lib</sel>
<desc>
<p>
Return pointer to xmlDoc structure.
</p>
</desc>
</method>
<method type="GSXMLNode*">
<sel>root</sel>
<desc>
<p>
Return the root name of document.
</p>
</desc>
</method>
<method type="GSXMLNode*">
<sel>setRoot:</sel>
<arg type="GSXMLNode*">node</arg>
<desc>
<p>
Set the root element of the document.
Return the old root element.
</p>
</desc>
</method>
<method type="GSXMLDocument*">
<sel>makeNodeWithNamespace:</sel>
<arg type="GSXMLNamespace*">ns</arg>
<sel>name:</sel>
<arg type="NSString*">name</arg>
<sel>content:</sel>
<arg type="NSString*">content</arg>
<desc>
<p>
Creation of a new node element within a document.
</p>
<example>
GSXMLNode *n1, *n2;
GSXMLDocument *d;
d = [GSXMLDocument documentWithVersion: @"1.0"];
[d setRoot: [d makeNodeWithNamespace: nil name: @"plist" content: nil]];
[[d root] setProp: @"version" value: @"0.9"];
n1 = [[d root] makeChildWithNamespace: nil name: @"dict" content: nil];
</example>
</desc>
</method>
</class>
</chapter>
</body>
</gsdoc>