activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jgo...@apache.org
Subject svn commit: r984506 - /activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/Util/URISupport.cs
Date Wed, 11 Aug 2010 18:16:32 GMT
Author: jgomes
Date: Wed Aug 11 18:16:31 2010
New Revision: 984506

URL: http://svn.apache.org/viewvc?rev=984506&view=rev
Log:
Fixed API for .NET CF compatibility.

Modified:
    activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/Util/URISupport.cs

Modified: activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/Util/URISupport.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/Util/URISupport.cs?rev=984506&r1=984505&r2=984506&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/Util/URISupport.cs (original)
+++ activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/Util/URISupport.cs Wed Aug 11
18:16:31 2010
@@ -64,7 +64,7 @@ namespace Apache.NMS.Util
             {
                 return EmptyMap;
             }
-			
+
             // strip the initial "?"
             if(query.StartsWith("?"))
             {
@@ -139,7 +139,7 @@ namespace Apache.NMS.Util
                 }
             }
         }
-		
+
         /// <summary>
         /// Sets the public properties of a target object using a string map.
         /// This method uses .Net reflection to identify public properties of
@@ -157,7 +157,7 @@ namespace Apache.NMS.Util
 
             foreach(string key in map.Keys)
             {
-                if(key.ToLower().StartsWith(prefix.ToLower()))
+                if(key.StartsWith(prefix, StringComparison.InvariantCultureIgnoreCase))
                 {
                     string bareKey = key.Substring(prefix.Length);
                     PropertyInfo prop = type.GetProperty(bareKey,
@@ -210,9 +210,9 @@ namespace Apache.NMS.Util
 
             foreach(string key in props.Keys)
             {
-                if(key.StartsWith(prefix))
+                if(key.StartsWith(prefix, StringComparison.InvariantCultureIgnoreCase))
                 {
-                    string bareKey = key.Substring(prefix.Length);					
+                    string bareKey = key.Substring(prefix.Length);
                     String value = props[key];
                     result[bareKey] = value;
                 }
@@ -220,7 +220,7 @@ namespace Apache.NMS.Util
 
             return result;
         }
-		
+
         public static StringDictionary ExtractProperties(StringDictionary props, string prefix)
{
 
             if(props == null)
@@ -233,7 +233,7 @@ namespace Apache.NMS.Util
 
             foreach(string key in props.Keys)
             {
-                if(key.StartsWith(prefix, true, CultureInfo.InvariantCulture))
+                if(key.StartsWith(prefix, StringComparison.InvariantCultureIgnoreCase))
                 {
                     String value = props[key];
                     result[key] = value;
@@ -408,7 +408,7 @@ namespace Apache.NMS.Util
 
         public static String StripPrefix(String value, String prefix)
         {
-            if(value.StartsWith(prefix))
+            if(value.StartsWith(prefix, StringComparison.InvariantCultureIgnoreCase))
             {
                 return value.Substring(prefix.Length);
             }



Mime
View raw message