org.graffiti.managers.pluginmgr
Class PluginXMLParser

java.lang.Object
  extended by org.graffiti.managers.pluginmgr.PluginXMLParser

public class PluginXMLParser
extends Object

The XML parser for the plugin descriptions. The plugin description ( plugin.xml) file is validated by the plugin.dtd.

Version:
$Revision: 5767 $

Field Summary
static String PLUGIN_DTD_LOCAL
          The local plugin dtd.
static String PREFERENCES_DTD_IDENTIFIER
          The public identifier of the preferences dtd.
static String PREFERENCES_DTD_LOCAL
          The local preferences dtd.
static String PUBLIC_DTD_IDENTIFIER
          The public identifier of the plugin dtd.
 
Constructor Summary
PluginXMLParser()
          Constructs a new plugin xml parser instance.
 
Method Summary
 PluginDescription parse(InputStream is)
          Parses the given plugin.xml file.
 void setPluginDescription(PluginDescription description)
          Sets the internal temporary plugin description to the given value.
 void validateDescription(PluginDescription description)
          Validates the given current plugin description.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PUBLIC_DTD_IDENTIFIER

public static final String PUBLIC_DTD_IDENTIFIER
The public identifier of the plugin dtd.


PLUGIN_DTD_LOCAL

public static final String PLUGIN_DTD_LOCAL
The local plugin dtd.


PREFERENCES_DTD_IDENTIFIER

public static String PREFERENCES_DTD_IDENTIFIER
The public identifier of the preferences dtd.


PREFERENCES_DTD_LOCAL

public static String PREFERENCES_DTD_LOCAL
The local preferences dtd.

Constructor Detail

PluginXMLParser

public PluginXMLParser()
Constructs a new plugin xml parser instance.

Method Detail

setPluginDescription

public void setPluginDescription(PluginDescription description)
Sets the internal temporary plugin description to the given value. This method is used by the xml parser only.

Parameters:
description - the new value.

parse

public PluginDescription parse(InputStream is)
                        throws IOException,
                               SAXException,
                               SAXParseException
Parses the given plugin.xml file.

Parameters:
is - input stream of theplugin.xml file.
Returns:
an instance of plugin description, which contains the parsed information.
Throws:
IOException - DOCUMENT ME!
SAXException - DOCUMENT ME!
SAXParseException - DOCUMENT ME!

validateDescription

public void validateDescription(PluginDescription description)
                         throws SAXException
Validates the given current plugin description.

Parameters:
description - the description to validate.
Throws:
SAXException - DOCUMENT ME!


Generated at 2012-05-30 11:00:14 PM CEST