jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alexparvule...@apache.org
Subject svn commit: r1485635 - /jackrabbit/oak/trunk/oak-mongomk/src/main/java/org/apache/jackrabbit/mongomk/util/LogWrapper.java
Date Thu, 23 May 2013 09:53:36 GMT
Author: alexparvulescu
Date: Thu May 23 09:53:36 2013
New Revision: 1485635

URL: http://svn.apache.org/r1485635
Log:
OAK-836 MongoMk LogWrapper generics

Modified:
    jackrabbit/oak/trunk/oak-mongomk/src/main/java/org/apache/jackrabbit/mongomk/util/LogWrapper.java

Modified: jackrabbit/oak/trunk/oak-mongomk/src/main/java/org/apache/jackrabbit/mongomk/util/LogWrapper.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-mongomk/src/main/java/org/apache/jackrabbit/mongomk/util/LogWrapper.java?rev=1485635&r1=1485634&r2=1485635&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-mongomk/src/main/java/org/apache/jackrabbit/mongomk/util/LogWrapper.java
(original)
+++ jackrabbit/oak/trunk/oak-mongomk/src/main/java/org/apache/jackrabbit/mongomk/util/LogWrapper.java
Thu May 23 09:53:36 2013
@@ -28,20 +28,24 @@ import org.slf4j.LoggerFactory;
 /**
  * A logging microkernel implementation.
  */
-public class LogWrapper implements MicroKernel {
+public class LogWrapper<T extends MicroKernel> implements MicroKernel {
     
     private static final Logger LOG = LoggerFactory.getLogger(LogWrapper.class);
 
     private static final boolean DEBUG = Boolean.parseBoolean(System.getProperty("mk.debug",
"true"));
     private static final AtomicInteger NEXT_ID = new AtomicInteger();
 
-    private final MicroKernel mk;
+    private final T mk;
     private final int id = NEXT_ID.getAndIncrement();
 
-    public LogWrapper(MicroKernel mk) {
+    public LogWrapper(T mk) {
         this.mk = mk;
     }
 
+    public T unwrap() {
+        return mk;
+    }
+
     @Override
     public String commit(String path, String jsonDiff, String revisionId, String message)
{
         try {



Mime
View raw message