diff --git a/Makefile.am b/Makefile.am
index b498eed..0e49f84 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -37,6 +37,7 @@
 
 libndn_cpp_a_SOURCES = \
   config.h ndn-cpp/common.hpp \
+  ndn-cpp/Closure.hpp \
   ndn-cpp/ContentObject.cpp ndn-cpp/c/ContentObject.h ndn-cpp/ContentObject.hpp \
   ndn-cpp/Interest.cpp ndn-cpp/c/Interest.h ndn-cpp/Interest.hpp \
   ndn-cpp/Key.cpp ndn-cpp/c/Key.h ndn-cpp/Key.hpp \
diff --git a/Makefile.in b/Makefile.in
index ca0c617..dc90771 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -438,6 +438,7 @@
 
 libndn_cpp_a_SOURCES = \
   config.h ndn-cpp/common.hpp \
+  ndn-cpp/Closure.hpp \
   ndn-cpp/ContentObject.cpp ndn-cpp/c/ContentObject.h ndn-cpp/ContentObject.hpp \
   ndn-cpp/Interest.cpp ndn-cpp/c/Interest.h ndn-cpp/Interest.hpp \
   ndn-cpp/Key.cpp ndn-cpp/c/Key.h ndn-cpp/Key.hpp \
diff --git a/ndn-cpp/Closure.hpp b/ndn-cpp/Closure.hpp
new file mode 100644
index 0000000..99dafdb
--- /dev/null
+++ b/ndn-cpp/Closure.hpp
@@ -0,0 +1,68 @@
+/**
+ * @author: Jeff Thompson
+ * This is a port of py from PyCCN, written by: 
+ * Derek Kulinski <takeda@takeda.tk>
+ * Jeff Burke <jburke@ucla.edu>
+ * 
+ * See COPYING for copyright and distribution information.
+ */
+
+#ifndef NDN_CLOSURE_HPP
+#define	NDN_CLOSURE_HPP
+
+#include "Common.hpp"
+
+namespace ndn {
+
+enum UpcallResult {
+  CLOSURE_RESULT_ERR               = -1, // upcall detected an error
+  CLOSURE_RESULT_OK                =  0, // normal upcall return
+  CLOSURE_RESULT_REEXPRESS         =  1, // reexpress the same interest again
+  CLOSURE_RESULT_INTEREST_CONSUMED =  2, // upcall claims to consume interest
+  CLOSURE_RESULT_VERIFY            =  3, // force an unverified result to be verified
+  CLOSURE_RESULT_FETCHKEY          =  4  // get the key in the key locator and re-call the interest
+};
+
+enum UpcallKind {
+  UPCALL_FINAL              = 0, // handler is about to be deregistered
+  UPCALL_INTEREST           = 1, // incoming interest
+  UPCALL_CONSUMED_INTEREST  = 2, // incoming interest, someone has answered
+  UPCALL_CONTENT            = 3, // incoming verified content
+  UPCALL_INTEREST_TIMED_OUT = 4, // interest timed out
+  UPCALL_CONTENT_UNVERIFIED = 5, // content that has not been verified
+  UPCALL_CONTENT_BAD        = 6  // verification failed  
+};
+
+class NDN;
+class Interest;
+class ContentObject;
+
+class UpcallInfo {
+public:
+  UpcallInfo(NDN *ndn, ptr_lib::shared_ptr<Interest> interest, int matchedComps, ptr_lib::shared_ptr<ContentObject> contentObject) 
+  {
+    ndn_ = ndn;
+    interest_ = interest;
+    contentObject_ = contentObject;
+  }
+  
+  NDN *getNDN() { return ndn_; }
+  
+  ptr_lib::shared_ptr<Interest> getInterest() { return interest_; }
+  
+  ptr_lib::shared_ptr<ContentObject> getContentObject() { return contentObject_; }
+  
+private:
+  NDN *ndn_;
+  ptr_lib::shared_ptr<Interest> interest_;
+  ptr_lib::shared_ptr<ContentObject> contentObject_;
+};
+
+class Closure {
+public:
+  virtual UpcallResult upcall(UpcallKind kind, UpcallInfo &upcallInfo) = 0;
+};
+
+}
+
+#endif
diff --git a/ndn-cpp/NDN.cpp b/ndn-cpp/NDN.cpp
index ba47698..cd1dbe6 100644
--- a/ndn-cpp/NDN.cpp
+++ b/ndn-cpp/NDN.cpp
@@ -8,6 +8,8 @@
 #include "ContentObject.hpp"
 #include "NDN.hpp"
 
+using namespace std;
+
 namespace ndn {
 
 void NDN::onReceivedElement(unsigned char *element, unsigned int elementLength)
@@ -15,15 +17,11 @@
   BinaryXMLDecoder decoder(element, elementLength);
   
   if (decoder.peekDTag(ndn_BinaryXML_DTag_ContentObject)) {
-    ContentObject contentObject;
-    contentObject.decode(element, elementLength);
-
-#if 0
-    cout << "Got content with name " << contentObject.getName().to_uri() << endl;
-    for (unsigned int i = 0; i < contentObject.getContent().size(); ++i)
-      cout << contentObject.getContent()[i];
-    cout << endl;
-#endif
+    ptr_lib::shared_ptr<ContentObject> contentObject(new ContentObject());
+    contentObject->decode(element, elementLength);
+    
+    UpcallInfo upcallInfo(this, ptr_lib::shared_ptr<Interest>(), 0, contentObject);
+    closure_->upcall(UPCALL_CONTENT, upcallInfo);
   }
 }
 
diff --git a/ndn-cpp/NDN.hpp b/ndn-cpp/NDN.hpp
index a89918b..9c8c691 100644
--- a/ndn-cpp/NDN.hpp
+++ b/ndn-cpp/NDN.hpp
@@ -6,13 +6,22 @@
 #ifndef NDN_NDN_HPP
 #define	NDN_NDN_HPP
 
+#include "Closure.hpp"
 #include "encoding/BinaryXMLElementReader.hpp"
 
 namespace ndn {
 
 class NDN : public ElementListener {
 public:
+  NDN(Closure *closure)
+  {
+    closure_ = closure;
+  }
+  
   virtual void onReceivedElement(unsigned char *element, unsigned int elementLength);
+  
+private:
+  Closure *closure_;
 };
 
 }
diff --git a/tests/test-get-async.cpp b/tests/test-get-async.cpp
index 3ea187e..011c28f 100644
--- a/tests/test-get-async.cpp
+++ b/tests/test-get-async.cpp
@@ -8,11 +8,30 @@
 #include <iostream>
 #include <ndn-cpp/Interest.hpp>
 #include <ndn-cpp/ContentObject.hpp>
-#include <ndn-cpp/encoding/BinaryXMLStructureDecoder.hpp>
 #include <ndn-cpp/transport/TcpTransport.hpp>
+#include <ndn-cpp/c/encoding/BinaryXMLElementReader.h>
+#include <ndn-cpp/NDN.hpp>
 
 using namespace std;
 using namespace ndn;
+
+class MyClosure : public Closure {
+public:
+  virtual UpcallResult upcall(UpcallKind kind, UpcallInfo &upcallInfo)
+  {
+    if (kind == UPCALL_CONTENT || kind == UPCALL_CONTENT_UNVERIFIED) {
+      cout << "Got content with name " << upcallInfo.getContentObject()->getName().to_uri() << endl;
+      for (unsigned int i = 0; i < upcallInfo.getContentObject()->getContent().size(); ++i)
+        cout << upcallInfo.getContentObject()->getContent()[i];
+      cout << endl;
+      
+      return CLOSURE_RESULT_OK;
+    }
+    else
+      return CLOSURE_RESULT_OK;
+  }
+};
+
 int main(int argc, char** argv)
 {
   try {
@@ -25,33 +44,15 @@
     transport.connect((char *)"E.hub.ndn.ucla.edu", 9695);
     transport.send(&encoding[0], encoding.size());
 
-    BinaryXMLStructureDecoder structureDecoder;
-    vector<unsigned char> element;
-    while (true) {
-      while (true) {
-        unsigned char buffer[8000];
-        unsigned int nBytes = transport.receive(buffer, sizeof(buffer));
-        element.insert(element.end(), buffer, buffer + nBytes);
-
-        if (structureDecoder.findElementEnd(&element[0], element.size()))
-          break;
-      }
-      
-      if (element[0] == 0x04)
-        // Assume this is a ContentObject.
-        break;
-      
-      // Erase this element and try again.
-      element.erase(element.begin(), element.begin() + structureDecoder.getOffset());
-    }
-        
-    ContentObject contentObject;
-    contentObject.decode(&element[0], structureDecoder.getOffset());
+    MyClosure closure;
+    NDN ndn(&closure);
     
-    cout << "Got content with name " << contentObject.getName().to_uri() << endl;
-    for (unsigned int i = 0; i < contentObject.getContent().size(); ++i)
-      cout << contentObject.getContent()[i];
-    cout << endl;
+    ndn_BinaryXMLElementReader elementReader;
+    ndn_BinaryXMLElementReader_init(&elementReader, (struct ndn_ElementListener *)&ndn);
+    
+    unsigned char buffer[8000];
+    unsigned int nBytes = transport.receive(buffer, sizeof(buffer));
+    ndn_BinaryXMLElementReader_onReceivedData(&elementReader, buffer, nBytes);    
   } catch (exception &e) {
     cout << "exception: " << e.what() << endl;
   }
