From e9eb88e1b3cd993641f68add997061a831e5b315 Mon Sep 17 00:00:00 2001
From: "Christoph M. Wintersteiger" <cwinter@microsoft.com>
Date: Fri, 24 Jun 2016 15:08:56 +0100
Subject: [PATCH] fixed java build issues. Relates to #648.

---
 examples/java/JavaExample.java | 2 +-
 src/api/java/Context.java      | 5 +++++
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/examples/java/JavaExample.java b/examples/java/JavaExample.java
index 74e94617d..5c8a7508f 100644
--- a/examples/java/JavaExample.java
+++ b/examples/java/JavaExample.java
@@ -188,7 +188,7 @@ class JavaExample
             /* do something with the context */
 
             /* be kind to dispose manually and not wait for the GC. */
-            ctx.dispose();
+            ctx.close();
         }
     }
 
diff --git a/src/api/java/Context.java b/src/api/java/Context.java
index 39d35d9d3..da924026c 100644
--- a/src/api/java/Context.java
+++ b/src/api/java/Context.java
@@ -35,6 +35,11 @@ public class Context implements AutoCloseable {
         init();
     }
 
+    protected Context (long m_ctx) {
+        this.m_ctx = m_ctx;
+        init();
+    }
+
 
     /**
      * Constructor.