directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From szoer...@apache.org
Subject svn commit: r757162 - in /directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops: BaseReadonlyPartition.java Main.java SystemPropertyPartition.java backend/SystemPropertyGenerator.java
Date Sun, 22 Mar 2009 09:57:25 GMT
Author: szoerner
Date: Sun Mar 22 09:57:24 2009
New Revision: 757162

URL: http://svn.apache.org/viewvc?rev=757162&view=rev
Log:
Changes from patch DIR-244 from Pierre-Arnaud applied in order to fix compilation issues with
Java 5

Modified:
    directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/BaseReadonlyPartition.java
    directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/Main.java
    directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/SystemPropertyPartition.java
    directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/backend/SystemPropertyGenerator.java

Modified: directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/BaseReadonlyPartition.java
URL: http://svn.apache.org/viewvc/directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/BaseReadonlyPartition.java?rev=757162&r1=757161&r2=757162&view=diff
==============================================================================
--- directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/BaseReadonlyPartition.java
(original)
+++ directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/BaseReadonlyPartition.java
Sun Mar 22 09:57:24 2009
@@ -118,7 +118,6 @@
         return suffixDn;
     }
 
-    @Override
     public LdapDN getUpSuffixDn() throws Exception {
 
         LOG.debug("getUpSuffixDn()");
@@ -126,4 +125,4 @@
         return new LdapDN(suffix);
     }
 
-}
\ No newline at end of file
+}

Modified: directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/Main.java
URL: http://svn.apache.org/viewvc/directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/Main.java?rev=757162&r1=757161&r2=757162&view=diff
==============================================================================
--- directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/Main.java
(original)
+++ directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/Main.java
Sun Mar 22 09:57:24 2009
@@ -1,7 +1,5 @@
 package org.apache.directory.samples.partition.sysprops;
 
-import java.io.File;
-
 import org.apache.directory.server.core.DefaultDirectoryService;
 import org.apache.directory.server.core.DirectoryService;
 import org.apache.directory.server.ldap.LdapService;

Modified: directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/SystemPropertyPartition.java
URL: http://svn.apache.org/viewvc/directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/SystemPropertyPartition.java?rev=757162&r1=757161&r2=757162&view=diff
==============================================================================
--- directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/SystemPropertyPartition.java
(original)
+++ directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/SystemPropertyPartition.java
Sun Mar 22 09:57:24 2009
@@ -49,7 +49,6 @@
         SystemPropertyGenerator.fill(storage);
     }
 
-    @Override
     public boolean hasEntry(EntryOperationContext ctx) throws Exception {
 
         boolean result = false;
@@ -73,7 +72,6 @@
         return result;
     }
 
-    @Override
     public EntryFilteringCursor list(ListOperationContext ctx) throws Exception {
 
         LOG.debug("list()");
@@ -81,7 +79,6 @@
         return null;
     }
 
-    @Override
     public ClonedServerEntry lookup(LookupOperationContext ctx)
             throws Exception {
 
@@ -108,13 +105,11 @@
         return null;
     }
 
-    @Override
     public ClonedServerEntry lookup(Long arg0) throws Exception {
         LOG.debug("lookup()");
         return null;
     }
 
-    @Override
     public EntryFilteringCursor search(SearchOperationContext ctx)
             throws Exception {
 

Modified: directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/backend/SystemPropertyGenerator.java
URL: http://svn.apache.org/viewvc/directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/backend/SystemPropertyGenerator.java?rev=757162&r1=757161&r2=757162&view=diff
==============================================================================
--- directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/backend/SystemPropertyGenerator.java
(original)
+++ directory/sandbox/szoerner/syspropPartition/src/main/java/org/apache/directory/samples/partition/sysprops/backend/SystemPropertyGenerator.java
Sun Mar 22 09:57:24 2009
@@ -1,5 +1,8 @@
 package org.apache.directory.samples.partition.sysprops.backend;
 
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.util.List;
 import java.util.Properties;
 import java.util.ResourceBundle;
 import java.util.TreeSet;
@@ -25,14 +28,20 @@
      */
     public static void fill(PropertyStorage storage) {
         Properties props = System.getProperties();
-
+        
+        Enumeration<String> bundleKeys = bundle.getKeys();
+		List<String> bundleKeysList = new ArrayList<String>();
+		while (bundleKeys.hasMoreElements()) {
+			bundleKeysList.add(bundleKeys.nextElement());
+		}
+		
         TreeSet<Object> keys = new TreeSet<Object>(props.keySet());
         for (Object object : keys) {
 
             String key = (String) object;
             String value = props.getProperty(key);
             String desc = null;
-            if (bundle.containsKey(key)) {
+            if (bundleKeysList.contains(key)) {
                 desc = bundle.getString(key);
             }
 



Mime
View raw message