[pLog-svn] r1580 - in plog/trunk/class/xml: . parser rssparser rssparser/magpierss tree

oscar at devel.plogworld.net oscar at devel.plogworld.net
Tue Mar 22 19:53:04 GMT 2005


Author: oscar
Date: 2005-03-22 19:53:03 +0000 (Tue, 22 Mar 2005)
New Revision: 1580

Modified:
   plog/trunk/class/xml/XPath.class.php
   plog/trunk/class/xml/parser/Parser.php
   plog/trunk/class/xml/pathparser.class.php
   plog/trunk/class/xml/rssparser/magpierss/rss_cache.inc
   plog/trunk/class/xml/rssparser/magpierss/rss_fetch.inc
   plog/trunk/class/xml/rssparser/magpierss/rss_parse.inc
   plog/trunk/class/xml/rssparser/magpierss/rss_utils.inc
   plog/trunk/class/xml/rssparser/rsschannel.class.php
   plog/trunk/class/xml/rssparser/rssenclosure.class.php
   plog/trunk/class/xml/rssparser/rssitem.class.php
   plog/trunk/class/xml/rssparser/rssparser.class.php
   plog/trunk/class/xml/tree/Node.php
   plog/trunk/class/xml/tree/Tree.php
Log:
documentation for the xml module

Modified: plog/trunk/class/xml/XPath.class.php
===================================================================
--- plog/trunk/class/xml/XPath.class.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/XPath.class.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -1,10 +1,8 @@
 <?php
 
-    /**
-     * @package xml
-     */
-
-/**
+/**
+ * \ingroup XML
+ *
  * Php.XPath
  *
  * +======================================================================================================+
@@ -162,15 +160,8 @@
  *
  * @author  S.Blum / N.Swinson / D.Allen / (P.Mehl)
  * @link    http://sourceforge.net/projects/phpxpath/
- * @version 3.4
- * @CVS $Id: XPath.class.php,v 1.1 2004/04/18 18:14:03 phunkphorce Exp $
+ * @version 3.4
  */
-
-/************************************************************************************************
-* ===============================================================================================
-*                               X P a t h B a s e  -  Class                                      
-* ===============================================================================================
-************************************************************************************************/
 class XPathBase {
   var $_lastError;
   

Modified: plog/trunk/class/xml/parser/Parser.php
===================================================================
--- plog/trunk/class/xml/parser/Parser.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/parser/Parser.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -68,7 +68,9 @@
  */
 define('XML_PARSER_ERROR_REMOTE', 205);
 
-/**
+/**
+ * \ingroup XML
+ *
  * XML Parser class.
  *
  * This is an XML parser based on PHP's "xml" extension,

Modified: plog/trunk/class/xml/pathparser.class.php
===================================================================
--- plog/trunk/class/xml/pathparser.class.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/pathparser.class.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -1,7 +1,10 @@
 <?
 
     /**
-     * @package xml
+     * \defgroup XML
+     *
+     * This module includes several external libraries and modules that deal with XML content
+     * including parsing, RSS and so on. 
      */
 
 // ##################################################################################
@@ -38,6 +41,11 @@
 
 include_once( PLOG_CLASS_PATH."class/object/object.class.php" );
 
+/**
+ * \ingroup XML
+ *
+ * Allows to create XPath queries for XML documents, if needed.
+ */
 class Path_parser extends Object {
   var $paths;
   var $context=Array();

Modified: plog/trunk/class/xml/rssparser/magpierss/rss_cache.inc
===================================================================
--- plog/trunk/class/xml/rssparser/magpierss/rss_cache.inc	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/magpierss/rss_cache.inc	2005-03-22 19:53:03 UTC (rev 1580)
@@ -1,5 +1,7 @@
 <?php
-/*
+/**
+ * \ingroup XML
+ *
  * Project:     MagpieRSS: a simple RSS integration tool
  * File:        rss_cache.inc, a simple, rolling(no GC), cache 
  *              for RSS objects, keyed on URL.
@@ -15,7 +17,6 @@
  * http://lists.sourceforge.net/lists/listinfo/magpierss-general
  *
  */
-
 class RSSCache {
     var $BASE_CACHE = './cache';    // where the cache files are stored
     var $MAX_AGE    = 3600;         // when are files stale, default one hour

Modified: plog/trunk/class/xml/rssparser/magpierss/rss_fetch.inc
===================================================================
--- plog/trunk/class/xml/rssparser/magpierss/rss_fetch.inc	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/magpierss/rss_fetch.inc	2005-03-22 19:53:03 UTC (rev 1580)
@@ -1,5 +1,7 @@
 <?php
-/*
+/**
+ * \ingroup XML
+ *
  * Project:     MagpieRSS: a simple RSS integration tool
  * File:        rss_fetch.inc, a simple functional interface
                 to fetching and parsing RSS files, via the

Modified: plog/trunk/class/xml/rssparser/magpierss/rss_parse.inc
===================================================================
--- plog/trunk/class/xml/rssparser/magpierss/rss_parse.inc	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/magpierss/rss_parse.inc	2005-03-22 19:53:03 UTC (rev 1580)
@@ -1,6 +1,13 @@
 <?php
 
-/**
+define('RSS', 'RSS');
+define('ATOM', 'Atom');
+
+require_once (MAGPIE_DIR . 'rss_utils.inc');
+
+/**
+* \ingroup XML
+*
 * Project:     MagpieRSS: a simple RSS integration tool
 * File:        rss_parse.inc  - parse an RSS or Atom feed
 *               return as a simple object.
@@ -19,18 +26,6 @@
 * @license          GPL
 *
 */
-
-define('RSS', 'RSS');
-define('ATOM', 'Atom');
-
-require_once (MAGPIE_DIR . 'rss_utils.inc');
-
-/**
-* Hybrid parser, and object, takes RSS as a string and returns a simple object.
-*
-* see: rss_fetch.inc for a simpler interface with integrated caching support
-*
-*/
 class MagpieRSS {
     var $parser;
     

Modified: plog/trunk/class/xml/rssparser/magpierss/rss_utils.inc
===================================================================
--- plog/trunk/class/xml/rssparser/magpierss/rss_utils.inc	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/magpierss/rss_utils.inc	2005-03-22 19:53:03 UTC (rev 1580)
@@ -1,5 +1,7 @@
 <?php
-/*
+/**
+ * \ingroup XML
+ *
  * Project:     MagpieRSS: a simple RSS integration tool
  * File:        rss_utils.inc, utility methods for working with RSS
  * Author:      Kellan Elliott-McCrea <kellan at protest.net>

Modified: plog/trunk/class/xml/rssparser/rsschannel.class.php
===================================================================
--- plog/trunk/class/xml/rssparser/rsschannel.class.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/rsschannel.class.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -3,6 +3,8 @@
 	include_once( PLOG_CLASS_PATH."class/object/object.class.php" );
 
     /**
+     * \ingroup XML
+     * 
      * <p>Provides information about an RSS channel, fetched from an RSS resource.</p>
      * <p>This class provides methods to get the value of some of the attributes and possible child
      * tags of the &lt;channel&lt; tag. In case we need to know about any other value that is not available

Modified: plog/trunk/class/xml/rssparser/rssenclosure.class.php
===================================================================
--- plog/trunk/class/xml/rssparser/rssenclosure.class.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/rssenclosure.class.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -3,8 +3,13 @@
 	include_once( PLOG_CLASS_PATH."class/object/object.class.php" );
 	
 	/**
+	 * \ingroup XML
+	 *
 	 * represents an enclosure from an rss 2.0 feed. This object needs
-	 * the patched version of MagpieRSS which has support for enclosures!!
+	 * our patched version of MagpieRSS which has support for enclosures.
+	 *
+	 * Objects of this class are returned via the RssItem::getEnclosures() method, as an
+	 * array of enclosures in case the RSS item has any.
 	 */
 	class RssEnclosure extends Object
 	{

Modified: plog/trunk/class/xml/rssparser/rssitem.class.php
===================================================================
--- plog/trunk/class/xml/rssparser/rssitem.class.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/rssitem.class.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -4,6 +4,8 @@
 	include_once( PLOG_CLASS_PATH."class/xml/rssparser/rssenclosure.class.php" );
 
     /**
+     * \ingroup XML
+     *
      * <p>Provides information about an RSS item, fetched from an RSS resource.</p>
      * <p>This class provides methods to get the value of some of the attributes and possible child
      * tags of the &lt;item&lt; tag. In case we need to know about any other value that is not available

Modified: plog/trunk/class/xml/rssparser/rssparser.class.php
===================================================================
--- plog/trunk/class/xml/rssparser/rssparser.class.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/rssparser/rssparser.class.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -9,6 +9,8 @@
 	include_once( PLOG_CLASS_PATH."class/xml/rssparser/rssitem.class.php" );
 
     /**
+     * \ingroup XML
+     *
      * <p>This parser is a wrapper around the functionality provided by the MagpieRSS parser, which
      * can be found at http://magpierss.sourceforge.net/. The RSS parser is compatible with
      * RSS 0.9, 1.0 and almost all the modules of the 1.0 specification.</p>
@@ -16,13 +18,15 @@
      * and/or the content of other pages in our journal. To do so, this object is exported with
      * "rss" as its identifier, so a simple operation to fetch the headlines from Slashdot would
      * look like:</p>
+     *
      * <pre>
      * {if $rss->parse("http://slashdot.org/slashdot.rdf")}
      *  {foreach from=$rss->getItems() item=rssItem}
-     *    &lt;a href="{$rssItem->getLink()}"&gt;{$rssItem->getTitle()}&lt;/a&gt;&lt;br/&gt;
+     *    <a href="{$rssItem->getLink()}">{$rssItem->getTitle()}</a>
      *  {/foreach}
      * {/if}
      * </pre>
+     *
      * <p>The parse() method takes a url as a parameter, and it will return true if the url
      * was correctly fetched. If so, we can then ask the parser to gives us an array of
      * RSSItem objects which contain information about all the different &lt;item&gt; tags that were

Modified: plog/trunk/class/xml/tree/Node.php
===================================================================
--- plog/trunk/class/xml/tree/Node.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/tree/Node.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -21,14 +21,15 @@
 // $Id: Node.php,v 1.22 2004/05/26 15:03:25 davey Exp $
 //
 
-/**
+/**
+ * \ingroup XML
+ *
  * PEAR::XML_Tree_Node
  *
  * @author  Bernd Römer <berndr at bonn.edu>
  * @package XML_Tree
  * @version 1.0  16-Aug-2001
  */
-
 class XML_Tree_Node {
     /**
      * Attributes of this node

Modified: plog/trunk/class/xml/tree/Tree.php
===================================================================
--- plog/trunk/class/xml/tree/Tree.php	2005-03-22 19:33:57 UTC (rev 1579)
+++ plog/trunk/class/xml/tree/Tree.php	2005-03-22 19:53:03 UTC (rev 1580)
@@ -25,7 +25,9 @@
 require_once PLOG_CLASS_PATH."class/xml/parser/Parser.php";
 require_once PLOG_CLASS_PATH."class/xml/tree/Node.php";
 
-/**
+/**
+ * \ingroup XML
+ *
  * PEAR::XML_Tree
  *
  * Purpose




More information about the pLog-svn mailing list