beagle r4582 - trunk/beagle-xesam/src
- From: arunsr svn gnome org
- To: svn-commits-list gnome org
- Subject: beagle r4582 - trunk/beagle-xesam/src
- Date: Thu, 6 Mar 2008 14:22:00 +0000 (GMT)
Author: arunsr
Date: Thu Mar 6 14:22:00 2008
New Revision: 4582
URL: http://svn.gnome.org/viewvc/beagle?rev=4582&view=rev
Log:
Fix handling of properties with a ":" in them
Modified:
trunk/beagle-xesam/src/Ontologies.cs
trunk/beagle-xesam/src/Parser.cs
Modified: trunk/beagle-xesam/src/Ontologies.cs
==============================================================================
--- trunk/beagle-xesam/src/Ontologies.cs (original)
+++ trunk/beagle-xesam/src/Ontologies.cs Thu Mar 6 14:22:00 2008
@@ -48,14 +48,14 @@
{
fields_mapping = new Dictionary<string, string> ();
- fields_mapping.Add ("dc:title", "property:dc:title");
- fields_mapping.Add ("xesam:title", "property:dc:title");
+ fields_mapping.Add ("dc:title", "dc:title");
+ fields_mapping.Add ("xesam:title", "dc:title");
- fields_mapping.Add ("dc:author", "property:dc:author");
- fields_mapping.Add ("xesam:author", "property:dc:author");
+ fields_mapping.Add ("dc:author", "dc:author");
+ fields_mapping.Add ("xesam:author", "dc:author");
- fields_mapping.Add ("dc:creator", "property:dc:creator");
- fields_mapping.Add ("xesam:creator", "property:dc:creator");
+ fields_mapping.Add ("dc:creator", "dc:creator");
+ fields_mapping.Add ("xesam:creator", "dc:creator");
fields_mapping.Add ("dc:date", "date");
Modified: trunk/beagle-xesam/src/Parser.cs
==============================================================================
--- trunk/beagle-xesam/src/Parser.cs (original)
+++ trunk/beagle-xesam/src/Parser.cs Thu Mar 6 14:22:00 2008
@@ -86,7 +86,13 @@
private static string ParseXesamField (XPathNavigator nav)
{
string field = nav.GetAttribute ("name", String.Empty);
- return Ontologies.XesamToBeagleField (field);
+ field = Ontologies.XesamToBeagleField (field);
+
+ if (field.Contains (":")) {
+ field = "property:" + field;
+ }
+
+ return field;
}
private static string ParseXesamData (XPathNavigator nav, ComparisonType dateComp)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]