Fri, 10 Sep 2010 09:04:45 +0200
Removed the obsolete plug-in repository handler.
Documentation/Source/eric5.E5XML.PluginRepositoryHandler.html | file | annotate | diff | comparison | revisions | |
E5XML/PluginRepositoryHandler.py | file | annotate | diff | comparison | revisions | |
eric5.e4p | file | annotate | diff | comparison | revisions |
--- a/Documentation/Source/eric5.E5XML.PluginRepositoryHandler.html Fri Sep 10 08:54:33 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,193 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' -'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'> -<html><head> -<title>eric5.E5XML.PluginRepositoryHandler</title> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body><a NAME="top" ID="top"></a> -<h1>eric5.E5XML.PluginRepositoryHandler</h1> -<p> -Module implementing the handler class for reading an XML tasks file. -</p> -<h3>Global Attributes</h3> -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> -<table> -<tr> -<td><a href="#PluginRepositoryHandler">PluginRepositoryHandler</a></td> -<td>Class implementing a sax handler to read an XML tasks file.</td> -</tr> -</table> -<h3>Functions</h3> -<table> -<tr><td>None</td></tr> -</table> -<hr /><hr /> -<a NAME="PluginRepositoryHandler" ID="PluginRepositoryHandler"></a> -<h2>PluginRepositoryHandler</h2> -<p> - Class implementing a sax handler to read an XML tasks file. -</p> -<h3>Derived from</h3> -XMLHandlerBase -<h3>Class Attributes</h3> -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> -<table> -<tr> -<td><a href="#PluginRepositoryHandler.__init__">PluginRepositoryHandler</a></td> -<td>Constructor</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endAuthor">endAuthor</a></td> -<td>Handler method for the "Author" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endDescription">endDescription</a></td> -<td>Handler method for the "Description" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endFilename">endFilename</a></td> -<td>Handler method for the "Filename" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endName">endName</a></td> -<td>Handler method for the "Name" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endPlugin">endPlugin</a></td> -<td>Handler method for the "Plugin" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endRepositoryUrl">endRepositoryUrl</a></td> -<td>Handler method for the "RepositoryUrl" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endShort">endShort</a></td> -<td>Handler method for the "Short" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endUrl">endUrl</a></td> -<td>Handler method for the "Url" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.endVersion">endVersion</a></td> -<td>Handler method for the "Version" end tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.getVersion">getVersion</a></td> -<td>Public method to retrieve the version of the tasks file.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.startDocumentPlugins">startDocumentPlugins</a></td> -<td>Handler called, when the document parsing is started.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.startPlugin">startPlugin</a></td> -<td>Handler method for the "Plugin" start tag.</td> -</tr><tr> -<td><a href="#PluginRepositoryHandler.startPlugins">startPlugins</a></td> -<td>Handler method for the "Plugins" start tag.</td> -</tr> -</table> -<a NAME="PluginRepositoryHandler.__init__" ID="PluginRepositoryHandler.__init__"></a> -<h4>PluginRepositoryHandler (Constructor)</h4> -<b>PluginRepositoryHandler</b>(<i>parent</i>) -<p> - Constructor -</p><dl> -<dt><i>parent</i></dt> -<dd> -reference to the parent dialog (PluginRepositoryDialog) -</dd> -</dl><a NAME="PluginRepositoryHandler.endAuthor" ID="PluginRepositoryHandler.endAuthor"></a> -<h4>PluginRepositoryHandler.endAuthor</h4> -<b>endAuthor</b>(<i></i>) -<p> - Handler method for the "Author" end tag. -</p><a NAME="PluginRepositoryHandler.endDescription" ID="PluginRepositoryHandler.endDescription"></a> -<h4>PluginRepositoryHandler.endDescription</h4> -<b>endDescription</b>(<i></i>) -<p> - Handler method for the "Description" end tag. -</p><a NAME="PluginRepositoryHandler.endFilename" ID="PluginRepositoryHandler.endFilename"></a> -<h4>PluginRepositoryHandler.endFilename</h4> -<b>endFilename</b>(<i></i>) -<p> - Handler method for the "Filename" end tag. -</p><a NAME="PluginRepositoryHandler.endName" ID="PluginRepositoryHandler.endName"></a> -<h4>PluginRepositoryHandler.endName</h4> -<b>endName</b>(<i></i>) -<p> - Handler method for the "Name" end tag. -</p><a NAME="PluginRepositoryHandler.endPlugin" ID="PluginRepositoryHandler.endPlugin"></a> -<h4>PluginRepositoryHandler.endPlugin</h4> -<b>endPlugin</b>(<i></i>) -<p> - Handler method for the "Plugin" end tag. -</p><a NAME="PluginRepositoryHandler.endRepositoryUrl" ID="PluginRepositoryHandler.endRepositoryUrl"></a> -<h4>PluginRepositoryHandler.endRepositoryUrl</h4> -<b>endRepositoryUrl</b>(<i></i>) -<p> - Handler method for the "RepositoryUrl" end tag. -</p><a NAME="PluginRepositoryHandler.endShort" ID="PluginRepositoryHandler.endShort"></a> -<h4>PluginRepositoryHandler.endShort</h4> -<b>endShort</b>(<i></i>) -<p> - Handler method for the "Short" end tag. -</p><a NAME="PluginRepositoryHandler.endUrl" ID="PluginRepositoryHandler.endUrl"></a> -<h4>PluginRepositoryHandler.endUrl</h4> -<b>endUrl</b>(<i></i>) -<p> - Handler method for the "Url" end tag. -</p><a NAME="PluginRepositoryHandler.endVersion" ID="PluginRepositoryHandler.endVersion"></a> -<h4>PluginRepositoryHandler.endVersion</h4> -<b>endVersion</b>(<i></i>) -<p> - Handler method for the "Version" end tag. -</p><a NAME="PluginRepositoryHandler.getVersion" ID="PluginRepositoryHandler.getVersion"></a> -<h4>PluginRepositoryHandler.getVersion</h4> -<b>getVersion</b>(<i></i>) -<p> - Public method to retrieve the version of the tasks file. -</p><dl> -<dt>Returns:</dt> -<dd> -String containing the version number. -</dd> -</dl><a NAME="PluginRepositoryHandler.startDocumentPlugins" ID="PluginRepositoryHandler.startDocumentPlugins"></a> -<h4>PluginRepositoryHandler.startDocumentPlugins</h4> -<b>startDocumentPlugins</b>(<i></i>) -<p> - Handler called, when the document parsing is started. -</p><a NAME="PluginRepositoryHandler.startPlugin" ID="PluginRepositoryHandler.startPlugin"></a> -<h4>PluginRepositoryHandler.startPlugin</h4> -<b>startPlugin</b>(<i>attrs</i>) -<p> - Handler method for the "Plugin" start tag. -</p><dl> -<dt><i>attrs</i></dt> -<dd> -list of tag attributes -</dd> -</dl><a NAME="PluginRepositoryHandler.startPlugins" ID="PluginRepositoryHandler.startPlugins"></a> -<h4>PluginRepositoryHandler.startPlugins</h4> -<b>startPlugins</b>(<i>attrs</i>) -<p> - Handler method for the "Plugins" start tag. -</p><dl> -<dt><i>attrs</i></dt> -<dd> -list of tag attributes -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/E5XML/PluginRepositoryHandler.py Fri Sep 10 08:54:33 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,143 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2005 - 2010 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing the handler class for reading an XML tasks file. -""" - -from .Config import pluginRepositoryFileFormatVersion -from .XMLHandlerBase import XMLHandlerBase - -import Preferences - -class PluginRepositoryHandler(XMLHandlerBase): - """ - Class implementing a sax handler to read an XML tasks file. - """ - def __init__(self, parent): - """ - Constructor - - @param parent reference to the parent dialog (PluginRepositoryDialog) - """ - XMLHandlerBase.__init__(self) - - self.startDocumentSpecific = self.startDocumentPlugins - - self.elements.update({ - 'Plugins' : (self.startPlugins, self.defaultEndElement), - 'Plugin' : (self.startPlugin, self.endPlugin), - 'Name' : (self.defaultStartElement, self.endName), - 'Short' : (self.defaultStartElement, self.endShort), - 'Description' : (self.defaultStartElement, self.endDescription), - 'Url' : (self.defaultStartElement, self.endUrl), - 'Author' : (self.defaultStartElement, self.endAuthor), - 'Version' : (self.defaultStartElement, self.endVersion), - 'Filename' : (self.defaultStartElement, self.endFilename), - 'RepositoryUrl' : (self.defaultStartElement, self.endRepositoryUrl), - }) - - self.parent = parent - - def startDocumentPlugins(self): - """ - Handler called, when the document parsing is started. - """ - self.version = '' - - ################################################### - ## below follow the individual handler functions - ################################################### - - def startPlugins(self, attrs): - """ - Handler method for the "Plugins" start tag. - - @param attrs list of tag attributes - """ - self.version = attrs.get('version', pluginRepositoryFileFormatVersion) - - def startPlugin(self, attrs): - """ - Handler method for the "Plugin" start tag. - - @param attrs list of tag attributes - """ - self.info = {"name" : "", - "short" : "", - "description" : "", - "url" : "", - "author" : "", - "version" : "", - "filename" : "", - } - self.info["status"] = attrs.get("status", "unknown") - - def endPlugin(self): - """ - Handler method for the "Plugin" end tag. - """ - self.parent.addEntry(self.info["name"], self.info["short"], - self.info["description"], self.info["url"], - self.info["author"], self.info["version"], - self.info["filename"], self.info["status"]) - - def endName(self): - """ - Handler method for the "Name" end tag. - """ - self.info["name"] = self.unescape(self.buffer) - - def endShort(self): - """ - Handler method for the "Short" end tag. - """ - self.info["short"] = self.unescape(self.buffer) - - def endDescription(self): - """ - Handler method for the "Description" end tag. - """ - txt = self.unescape(self.buffer) - self.info["description"] = [line.strip() for line in txt.splitlines()] - - def endUrl(self): - """ - Handler method for the "Url" end tag. - """ - self.info["url"] = self.unescape(self.buffer) - - def endAuthor(self): - """ - Handler method for the "Author" end tag. - """ - self.info["author"] = self.unescape(self.buffer) - - def endVersion(self): - """ - Handler method for the "Version" end tag. - """ - self.info["version"] = self.unescape(self.buffer) - - def endFilename(self): - """ - Handler method for the "Filename" end tag. - """ - self.info["filename"] = self.unescape(self.buffer) - - def endRepositoryUrl(self): - """ - Handler method for the "RepositoryUrl" end tag. - """ - url = self.unescape(self.buffer).strip() - Preferences.setUI("PluginRepositoryUrl5", url) - - def getVersion(self): - """ - Public method to retrieve the version of the tasks file. - - @return String containing the version number. - """ - return self.version
--- a/eric5.e4p Fri Sep 10 08:54:33 2010 +0200 +++ b/eric5.e4p Fri Sep 10 09:04:45 2010 +0200 @@ -724,7 +724,6 @@ <Source>E5XML/SessionHandler.py</Source> <Source>E5XML/UserProjectWriter.py</Source> <Source>E5XML/UserProjectHandler.py</Source> - <Source>E5XML/PluginRepositoryHandler.py</Source> <Source>E5XML/MultiProjectWriter.py</Source> <Source>E5XML/MultiProjectHandler.py</Source> <Source>E5XML/HighlightingStylesWriter.py</Source>