capuchin r61 - in trunk/src/libcapuchin: . Xml
- From: sebp svn gnome org
- To: svn-commits-list gnome org
- Subject: capuchin r61 - in trunk/src/libcapuchin: . Xml
- Date: Sun, 9 Mar 2008 11:14:42 +0000 (GMT)
Author: sebp
Date: Sun Mar 9 11:14:41 2008
New Revision: 61
URL: http://svn.gnome.org/viewvc/capuchin?rev=61&view=rev
Log:
(De)serialization classes must be public
Methods of AppObject contain Plugin when a plugin id is required
Modified:
trunk/src/libcapuchin/AppObject.cs
trunk/src/libcapuchin/IAppObject.cs
trunk/src/libcapuchin/Xml/ItemsDict.cs
trunk/src/libcapuchin/Xml/Repository.cs
trunk/src/libcapuchin/Xml/author.cs
trunk/src/libcapuchin/Xml/changelog.cs
trunk/src/libcapuchin/Xml/checksum.cs
trunk/src/libcapuchin/Xml/item.cs
Modified: trunk/src/libcapuchin/AppObject.cs
==============================================================================
--- trunk/src/libcapuchin/AppObject.cs (original)
+++ trunk/src/libcapuchin/AppObject.cs Sun Mar 9 11:14:41 2008
@@ -205,7 +205,7 @@
/// <summary>
/// Get name of plugin with given <code>plugin_id</code>
/// </summary>
- public string GetName (string plugin_id)
+ public string GetPluginName (string plugin_id)
{
return this.RepoItems[plugin_id].Name;
}
@@ -213,7 +213,7 @@
/// <summary>
/// Get description for given <code>plugin_id</code>
/// </summary>
- public string GetDescription (string plugin_id)
+ public string GetPluginDescription (string plugin_id)
{
return this.RepoItems[plugin_id].Description;
}
@@ -221,7 +221,7 @@
/// <summary>
/// Get changes for plugin with given ID made in given version
/// </summary>
- public string GetChanges (string plugin_id, string version)
+ public string GetPluginChanges (string plugin_id, string version)
{
if (this.RepoItems[plugin_id].Changelog.ContainsKey (version))
{
@@ -234,7 +234,7 @@
/// <summary>Get tags for the plugin with ID <code>plugin_id</code></summary>
/// <param name="plugin_id">Plugin's ID</param>
/// <returns>An array of tags</returns>
- public string[] GetTags (string plugin_id)
+ public string[] GetPluginTags (string plugin_id)
{
Log.Info("Getting tags for plugin with id '{0}'", plugin_id);
string[] tags = this.RepoItems[plugin_id].Tags;
@@ -244,7 +244,7 @@
/// <summary>Get the author's name and e-mail address for the plugin with ID <code>plugin_id</code></summary>
/// <param name="plugin_id">Plugin's ID</param>
/// <returns>Dictionary with keys "name" and "email"</returns>
- public string[] GetAuthor (string plugin_id)
+ public string[] GetPluginAuthor (string plugin_id)
{
Log.Info("Getting author of plugin with id '{0}'", plugin_id);
@@ -252,6 +252,11 @@
return new string[] { plugin_author.Name, plugin_author.Email };
}
+ public string[] GetTags ()
+ {
+ return null;
+ }
+
/// <summary>Tell the object that it isn't needed anymore</summary>
public void Close()
{
Modified: trunk/src/libcapuchin/IAppObject.cs
==============================================================================
--- trunk/src/libcapuchin/IAppObject.cs (original)
+++ trunk/src/libcapuchin/IAppObject.cs Sun Mar 9 11:14:41 2008
@@ -26,11 +26,12 @@
string[] GetAvailablePlugins ();
string[] GetAvailableUpdates (string[][] plugins);
string[] GetPluginsWithTag (string tag);
- string GetName (string plugin_id);
- string GetDescription (string plugin_id);
- string GetChanges (string plugin_id, string version);
- string[] GetTags (string plugin_id);
- string[] GetAuthor (string plugin_id);
+ string GetPluginName (string plugin_id);
+ string GetPluginDescription (string plugin_id);
+ string GetPluginChanges (string plugin_id, string version);
+ string[] GetPluginTags (string plugin_id);
+ string[] GetPluginAuthor (string plugin_id);
+ string[] GetTags ();
void Close ();
}
}
Modified: trunk/src/libcapuchin/Xml/ItemsDict.cs
==============================================================================
--- trunk/src/libcapuchin/Xml/ItemsDict.cs (original)
+++ trunk/src/libcapuchin/Xml/ItemsDict.cs Sun Mar 9 11:14:41 2008
@@ -6,7 +6,7 @@
namespace Capuchin.Xml
{
- internal class ItemsDict : Dictionary<string, item>, IXmlSerializable
+ public class ItemsDict : Dictionary<string, item>, IXmlSerializable
{
public System.Xml.Schema.XmlSchema GetSchema()
{
Modified: trunk/src/libcapuchin/Xml/Repository.cs
==============================================================================
--- trunk/src/libcapuchin/Xml/Repository.cs (original)
+++ trunk/src/libcapuchin/Xml/Repository.cs Sun Mar 9 11:14:41 2008
@@ -5,7 +5,7 @@
namespace Capuchin.Xml
{
[XmlRootAttribute(ElementName="repository", Namespace="", IsNullable=false)]
- internal class Repository
+ public class Repository
{
[XmlElementAttribute("application")]
public string application;
Modified: trunk/src/libcapuchin/Xml/author.cs
==============================================================================
--- trunk/src/libcapuchin/Xml/author.cs (original)
+++ trunk/src/libcapuchin/Xml/author.cs Sun Mar 9 11:14:41 2008
@@ -6,7 +6,7 @@
{
[XmlRootAttribute(ElementName="author", Namespace = "", IsNullable = false)]
- internal class author
+ public class author
{
[XmlAttributeAttribute("name", typeof(string))]
public string Name;
Modified: trunk/src/libcapuchin/Xml/changelog.cs
==============================================================================
--- trunk/src/libcapuchin/Xml/changelog.cs (original)
+++ trunk/src/libcapuchin/Xml/changelog.cs Sun Mar 9 11:14:41 2008
@@ -6,8 +6,8 @@
namespace Capuchin.Xml
{
- [XmlRootAttribute(ElementName="changelog", Namespace = "", IsNullable = false)]
- internal class changelog : Dictionary<string, string>, IXmlSerializable
+ [XmlRootAttribute(ElementName="changelog", Namespace = "", IsNullable = false)]
+ public class changelog : Dictionary<string, string>, IXmlSerializable
{
public System.Xml.Schema.XmlSchema GetSchema()
{
Modified: trunk/src/libcapuchin/Xml/checksum.cs
==============================================================================
--- trunk/src/libcapuchin/Xml/checksum.cs (original)
+++ trunk/src/libcapuchin/Xml/checksum.cs Sun Mar 9 11:14:41 2008
@@ -5,14 +5,14 @@
namespace Capuchin.Xml
{
- internal enum checksumType
+ public enum checksumType
{
sha1,
md5,
}
[XmlRootAttribute(Namespace = "", IsNullable = false)]
- internal class checksum
+ public class checksum
{
private checksumType typeField;
Modified: trunk/src/libcapuchin/Xml/item.cs
==============================================================================
--- trunk/src/libcapuchin/Xml/item.cs (original)
+++ trunk/src/libcapuchin/Xml/item.cs Sun Mar 9 11:14:41 2008
@@ -6,7 +6,7 @@
{
[XmlRootAttribute(Namespace = "", IsNullable = false)]
- internal class item
+ public class item
{
[XmlElementAttribute("author", typeof(author), IsNullable = false)]
public author Author;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]