cvs commit: ALFS/docs/syntax_doc/alfs_dtd xml_dtd-syntax.xml

jwrober at linuxfromscratch.org jwrober at linuxfromscratch.org
Tue Mar 30 17:53:55 PST 2004


jwrober     04/03/30 18:53:55

  Modified:    docs/syntax_doc/alfs_dtd xml_dtd-syntax.xml
  Log:
  finished
  
  Revision  Changes    Path
  1.5       +92 -30    ALFS/docs/syntax_doc/alfs_dtd/xml_dtd-syntax.xml
  
  Index: xml_dtd-syntax.xml
  ===================================================================
  RCS file: /home/cvsroot/ALFS/docs/syntax_doc/alfs_dtd/xml_dtd-syntax.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- xml_dtd-syntax.xml	16 Mar 2004 04:12:26 -0000	1.4
  +++ xml_dtd-syntax.xml	31 Mar 2004 01:53:55 -0000	1.5
  @@ -1,20 +1,19 @@
   <sect1 id="xml_dtd-syntax" xreflabel="XML DTD Syntax">
   <?dbhtml filename="xml_dtd-syntax.html" dir="alfs_dtd"?>
  -<title>XML DTD Syntax</title>
  +<title>XML & DTD Syntax</title>
   
   <sect2>
  -<title>Quick Introduction to XML</title>
  +<title>Quick Introduction to XML Syntax</title>
   
   <para>To ensure that all readers of the &book-product; get as much as
   possible from its contents, it is necessary to provide a quick introduction
   to the concepts of <acronym>XML</acronym> and <acronym>DTD</acronym>
  -syntax. The eXtensible Markup Language is very powerful and easy to use and
  -understand.</para>
  +syntax.</para>
   
  -<note><para>This introduction provides very few examples.  This book is
  +<note><para>This introduction provides very few examples. This book is
   written in an <acronym>XML</acronym> <acronym>DTD</acronym> called DocBook
  -<acronym>XML</acronym>.  For an example of <acronym>XML</acronym> just look
  -at the book's source.  Since this book is documenting an
  +<acronym>XML</acronym>. For an example of <acronym>XML</acronym> just look
  +at the book's source. Since this book is documenting an
   <acronym>XML</acronym> <acronym>DTD</acronym>, look at the rest of the
   book's contents for examples of <acronym>DTD</acronym>
   syntax.</para></note>
  @@ -49,10 +48,9 @@
   <listitem><para>With <acronym>XML</acronym>, white space is
   preserved.</para></listitem>
   
  -<listitem><para>With <acronym>XML</acronym>,
  -<filename><acronym>CR</acronym></filename> /
  -<filename><acronym>LF</acronym></filename> is converted to
  -<filename><acronym>LF</acronym></filename></para></listitem>
  +<listitem><para>With <acronym>XML</acronym>, <filename>CR</filename> /
  +<filename>LF</filename> is converted to
  +<filename>LF</filename></para></listitem>
   
   </itemizedlist>
   
  @@ -62,18 +60,19 @@
   <title>XML Elements and Attributes</title>
   
   <para><acronym>XML</acronym> is designed to hold any kind of information.
  -This information is stored in Elements.  Elements are the basic building
  -blocks of <acronym>XML</acronym> and are represented in an
  -<acronym>XML</acronym> documents as tag pairs.  Attributes provide a
  -mechanism to further define or classify an element.  Elements have
  -relationships with other elements in a document.  Some are parents and some
  -are children.  Using this symantic description, one can see that children
  -elements need parent elements defined and used first.  As mentioned in the
  +This information is stored in Elements. Elements are the basic building
  +blocks of <acronym>XML</acronym> and are represented in a
  +<acronym>XML</acronym> document as tag pairs. Attributes provide a
  +mechanism to further define or classify an element. Elements have
  +relationships with other elements in a document. Some are parents and some
  +are children. Using this symantic description, one can see that children
  +elements need parent elements defined and used first. As mentioned in the
   last section, an <acronym>XML</acronym> document must have a root element.
  -Think of this as the ultimate parent element.  It must be defined and used
  -before all other elements and all sub-elements (children) will reside
  -inside of the root element.  An element can have element content, mixed
  -content, simple content, empty content or attributes.</para>
  +Think of this as the ultimate parent element. The root element must be
  +defined and used before all other elements and all sub-elements (children).
  +All elements and sub-elements will reside inside of the root element. An
  +element can have parsed content, mixed content, simple content, empty
  +content or attributes in their definition.</para>
   
   <para><acronym>XML</acronym> elements must follow these naming
   rules :</para>
  @@ -100,7 +99,7 @@
   
   <para>Once an <acronym>XML</acronym> document is written, it is generally a
   good idea to validate the elements used in the document against a known
  -<acronym>DTD</acronym>.  The Document Type Definition is the mechanism with
  +<acronym>DTD</acronym>. The Document Type Definition is the mechanism with
   which one validates the content of a well-formed <acronym>XML</acronym>
   document.</para>
   
  @@ -119,15 +118,15 @@
   
   <listitem><para>Entities : Entities are the same thing as
   variables inside a <acronym>DTD</acronym> file or <acronym>XML</acronym>
  -document.</para></listitem>
  +document. They can hold any kind of data.</para></listitem>
   
  -<listitem><para><filename><acronym>PCDATA</acronym></filename> : <filename><acronym>PCDATA</acronym></filename>
  -is Parsed Character DATA. <filename><acronym>PCDATA</acronym></filename> is
  +<listitem><para><filename>PCDATA</filename> : <filename>PCDATA</filename>
  +is Parsed Character DATA. <filename>PCDATA</filename> is
   text that will be parsed by a parser. Tags inside the text will be treated
   as markup and entities will be expanded.</para></listitem>
   
  -<listitem><para><filename><acronym>CDATA</acronym></filename> : <filename><acronym>CDATA</acronym></filename>
  -is Character DATA. <filename><acronym>CDATA</acronym></filename> is text
  +<listitem><para><filename>CDATA</filename> : <filename>CDATA</filename>
  +is Character DATA. <filename>CDATA</filename> is text
   that will NOT be parsed by a parser. Tags inside the text will NOT be
   treated as markup and entities will not be expanded.</para></listitem>
   
  @@ -172,14 +171,14 @@
   <para>When an element is declared with children, it will also define how
   the children can be used inside an <acronym>XML</acronym> document.  There
   are four ways that children elements can be defined in a
  -<acronym>DTD</acronym> file : </para>
  +<acronym>DTD</acronym> file :</para>
   
   <itemizedlist>
   
   <listitem><para>One Occurance Only : Example : 
   <xref linkend="elem_search_replace"/>. The child elements of
   <search_replace> &emdash; <file>, <find>, and
  -<replace> can one be used once. Notice that there are no symbols
  +<replace> can only be used once. Notice that there are no symbols
   after any of the child element names. This is the
   identifier.</para></listitem>
   
  @@ -213,6 +212,69 @@
   
   <sect2>
   <title><acronym>DTD</acronym> Attribute Declaration</title>
  +
  +<para>As mentioned above, attributes can help to define
  +"classes" of Elements. Attributes are defined with types and
  +values. There are 11 types :</para>
  +
  +<itemizedlist>
  +
  +<listitem><para><filename>CDATA</filename> : The
  +value is Character Data.</para></listitem>
  +
  +<listitem><para><filename>(en1|en2|...)</filename> : The value is
  +an enumerated list.</para></listitem>
  +
  +<listitem><para><filename>ID</filename> : The value is a unique
  +id.</para></listitem>
  +
  +<listitem><para><filename>IDREF</filename> : The value is the id
  +of another element.</para></listitem>
  +
  +<listitem><para><filename>IDREFS</filename> : The value is a list
  +of other ids,</para></listitem>
  +
  +<listitem><para><filename>NMTOKEN</filename> : The value is a
  +valid <acronym>XML</acronym> name.</para></listitem>
  +
  +<listitem><para><filename>NMTOKENS</filename> : The value is a
  +list of valid <acronym>XML</acronym> names.</para></listitem>
  +
  +<listitem><para><filename>ENTITY</filename> : The value is an
  +entity.</para></listitem>
  +
  +<listitem><para><filename>ENTITIES</filename> : The value is a
  +list of entities.</para></listitem>
  +
  +<listitem><para><filename>NOTATION</filename> : The value is a
  +name of a notation.</para></listitem>
  +
  +<listitem><para><filename>xml</filename> : The value is a
  +predefined <acronym>XML</acronym> value.</para></listitem>
  +
  +</itemizedlist>
  +
  +<para>There are four value options :</para>
  +
  +<itemizedlist>
  +
  +<listitem><para><filename>Value</filename> : The default value of
  +the attribute surrounded by quotes [ " " ].
  +Example : <xref linkend="elem_alfs"/>.</para></listitem>
  +
  +<listitem><para><filename>#IMPLIED</filename> : The attribute is
  +optional. Example : 
  +<xref linkend="elem_alfs"/>.</para></listitem>
  +
  +<listitem><para><filename>#REQUIRED</filename> : The attribute is
  +required when the element is used. Example : 
  +<xref linkend="elem_execute"/>.</para></listitem>
  +
  +<listitem><para><filename>#FIXED</filename> : A fixed value. Used
  +with the <filename>Value</filename> option. Example : 
  +<xref linkend="elem_alfs"/>.</para></listitem>
  +
  +</itemizedlist>
   
   </sect2>
   
  
  
  



More information about the alfs-log mailing list