You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by rv...@apache.org on 2015/02/17 13:42:56 UTC

[47/50] [abbrv] jena git commit: Migrate simple registry from Fuseki2 to Atlas

Migrate simple registry from Fuseki2 to Atlas

Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/49fe906b
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/49fe906b
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/49fe906b

Branch: refs/heads/eliminate-assignments
Commit: 49fe906bf8913fb6cdbf0c1cc5e72dc3181b3ac0
Parents: 65ee909
Author: Andy Seaborne <an...@apache.org>
Authored: Tue Feb 17 10:54:45 2015 +0000
Committer: Andy Seaborne <an...@apache.org>
Committed: Tue Feb 17 10:54:45 2015 +0000

----------------------------------------------------------------------
 .../org/apache/jena/atlas/lib/Registry.java     | 39 ++++++++++++++++++++
 .../apache/jena/fuseki/migrate/Registry.java    | 39 --------------------
 .../fuseki/server/DataAccessPointRegistry.java  |  2 +-
 3 files changed, 40 insertions(+), 40 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jena/blob/49fe906b/jena-arq/src/main/java/org/apache/jena/atlas/lib/Registry.java
----------------------------------------------------------------------
diff --git a/jena-arq/src/main/java/org/apache/jena/atlas/lib/Registry.java b/jena-arq/src/main/java/org/apache/jena/atlas/lib/Registry.java
new file mode 100644
index 0000000..b1e0d74
--- /dev/null
+++ b/jena-arq/src/main/java/org/apache/jena/atlas/lib/Registry.java
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.jena.atlas.lib;
+
+import java.util.Collection ;
+import java.util.Map ;
+import java.util.concurrent.ConcurrentHashMap ;
+
+public class Registry<K,T>
+{
+    protected Map<K, T> registry = new ConcurrentHashMap<>() ;
+    
+    public Registry() {}
+    
+    public void put(K key, T value)     { registry.put(key, value) ; }
+    public T get(K key)                 { return registry.get(key) ; }
+    public boolean isRegistered(K key)  { return registry.containsKey(key) ; }
+    public void remove(K key)           { registry.remove(key) ; } 
+    public Collection<K> keys()         { return registry.keySet() ; }
+    //public Iterator<String> keys()      { return registry.keySet().iterator() ; }
+    public int size()                   { return registry.size() ; }
+    public boolean isEmpty()            { return registry.isEmpty() ; }
+}

http://git-wip-us.apache.org/repos/asf/jena/blob/49fe906b/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/migrate/Registry.java
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/migrate/Registry.java b/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/migrate/Registry.java
deleted file mode 100644
index 9e7f729..0000000
--- a/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/migrate/Registry.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.jena.fuseki.migrate;
-
-import java.util.Collection ;
-import java.util.Map ;
-import java.util.concurrent.ConcurrentHashMap ;
-
-public class Registry<K,T>
-{
-    protected Map<K, T> registry = new ConcurrentHashMap<>() ;
-    
-    public Registry() {}
-    
-    public void put(K key, T value)     { registry.put(key, value) ; }
-    public T get(K key)                 { return registry.get(key) ; }
-    public boolean isRegistered(K key)  { return registry.containsKey(key) ; }
-    public void remove(K key)           { registry.remove(key) ; } 
-    public Collection<K> keys()         { return registry.keySet() ; }
-    //public Iterator<String> keys()      { return registry.keySet().iterator() ; }
-    public int size()                   { return registry.size() ; }
-    public boolean isEmpty()            { return registry.isEmpty() ; }
-}

http://git-wip-us.apache.org/repos/asf/jena/blob/49fe906b/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/server/DataAccessPointRegistry.java
----------------------------------------------------------------------
diff --git a/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/server/DataAccessPointRegistry.java b/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/server/DataAccessPointRegistry.java
index 19119a9..acd3e93 100644
--- a/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/server/DataAccessPointRegistry.java
+++ b/jena-fuseki2/jena-fuseki-core/src/main/java/org/apache/jena/fuseki/server/DataAccessPointRegistry.java
@@ -18,8 +18,8 @@
 
 package org.apache.jena.fuseki.server;
 
+import org.apache.jena.atlas.lib.Registry ;
 import org.apache.jena.fuseki.FusekiException ;
-import org.apache.jena.fuseki.migrate.Registry ;
 
 public class DataAccessPointRegistry extends Registry<String, DataAccessPoint>
 {