diff --git a/js/encoding/BinaryXMLDecoder.js b/js/encoding/BinaryXMLDecoder.js
index 23276cf..609bd99 100644
--- a/js/encoding/BinaryXMLDecoder.js
+++ b/js/encoding/BinaryXMLDecoder.js
@@ -1,5 +1,5 @@
 /*
- * This class is used to encode and decode binary elements ( blog, type/value pairs)
+ * This class is used to decode ccnb binary elements (blob, type/value pairs).
  * 
  * @author: ucla-cs
  * See COPYING for copyright and distribution information.
@@ -71,49 +71,9 @@
 	var DEBUG_MAX_LEN =  32768;
 	
 	this.istream = istream;
-	//console.log('istream is '+ this.istream);
 	this.offset = 0;
 };
 
-
-BinaryXMLDecoder.prototype.readStartElement =function(
-	//String
-	startTag,				    
-	//TreeMap<String, String>
-	attributes) {
-
-	try {
-		//this.TypeAndVal 
-		tv = this.decodeTypeAndVal(this.istream);
-
-		if (null == tv) {
-			throw new Error("Expected start element: " + startTag + " got something not a tag.");
-		}
-		
-		//String 
-		decodedTag = null;
-		
-		if (tv.type() == XML_TAG) {
-			
-			decodedTag = this.decodeUString(this.Istream, tv.val()+1);
-			
-		} else if (tv.type() == XML_DTAG) {
-			decodedTag = tagToString(tv.val());	
-		}
-		
-		if ((null ==  decodedTag) || decodedTag != startTag) {
-			throw new Error("Expected start element: " + startTag + " got: " + decodedTag + "(" + tv.val() + ")");
-		}
-		
-		if (null != attributes) {
-			readAttributes(attributes); 
-		}
-		
-	} catch (e) {
-		throw new Error("readStartElement", e);
-	}
-};
-
 BinaryXMLDecoder.prototype.readAttributes = function(
 	//TreeMap<String,String> 
 	attributes){
@@ -125,18 +85,18 @@
 	try {
 
 		//this.TypeAndVal 
-		nextTV = this.peekTypeAndVal(this.istream);
+		nextTV = this.peekTypeAndVal();
 
 		while ((null != nextTV) && ((XML_ATTR == nextTV.type()) ||
 				(XML_DATTR == nextTV.type()))) {
 
 			//this.TypeAndVal 
-			thisTV = this.decodeTypeAndVal(this.Istream);
+			thisTV = this.decodeTypeAndVal();
 
 			var attributeName = null;
 			if (XML_ATTR == thisTV.type()) {
 				
-				attributeName = this.decodeUString(this.istream, thisTV.val()+1);
+				attributeName = this.decodeUString(thisTV.val()+1);
 
 			} else if (XML_DATTR == thisTV.type()) {
 				// DKS TODO are attributes same or different dictionary?
@@ -146,11 +106,11 @@
 				}
 			}
 			
-			var attributeValue = this.decodeUString(this.istream);
+			var attributeValue = this.decodeUString();
 
 			attributes.put(attributeName, attributeValue);
 
-			nextTV = this.peekTypeAndVal(this.istream);
+			nextTV = this.peekTypeAndVal();
 		}
 
 	} catch ( e) {
@@ -187,7 +147,7 @@
 		
 		//try {
 			//TypeAndVal 
-			tv = this.decodeTypeAndVal(this.istream);
+			tv = this.decodeTypeAndVal();
 			
 			if (null == tv) {
 				throw new Error("Expected start element: " + startTag + " got something not a tag.");
@@ -212,7 +172,7 @@
 				
 				//console.log('valval is ' +valval);
 				
-				decodedTag = this.decodeUString(this.istream,  valval);
+				decodedTag = this.decodeUString(valval);
 				
 			} else if (tv.type() == XML_DTAG) {
 				//console.log('gothere');
@@ -256,14 +216,14 @@
 	try {
 		// Now need to get attributes.
 		//TypeAndVal 
-		nextTV = this.peekTypeAndVal(this.istream);
+		nextTV = this.peekTypeAndVal();
 
 		while ((null != nextTV) && ((XML_ATTR == nextTV.type()) ||
 				(XML_DATTR == nextTV.type()))) {
 
 			// Decode this attribute. First, really read the type and value.
 			//this.TypeAndVal 
-			thisTV = this.decodeTypeAndVal(this.istream);
+			thisTV = this.decodeTypeAndVal();
 
 			//String 
 			attributeName = null;
@@ -276,7 +236,7 @@
 				else
 					valval = (tv.val())+ 1;
 				
-				attributeName = this.decodeUString(this.istream,valval);
+				attributeName = this.decodeUString(valval);
 
 			} else if (XML_DATTR == thisTV.type()) {
 				// DKS TODO are attributes same or different dictionary?
@@ -287,12 +247,12 @@
 			}
 			// Attribute values are always UDATA
 			//String
-			attributeValue = this.decodeUString(this.istream);
+			attributeValue = this.decodeUString();
 
 			//
 			attributes.push([attributeName, attributeValue]);
 
-			nextTV = this.peekTypeAndVal(this.istream);
+			nextTV = this.peekTypeAndVal();
 		}
 
 	} catch ( e) {
@@ -312,7 +272,7 @@
 		// Have to distinguish genuine errors from wrong tags. Could either use
 		// a special exception subtype, or redo the work here.
 		//this.TypeAndVal 
-		tv = this.decodeTypeAndVal(this.istream);
+		tv = this.decodeTypeAndVal();
 
 		if (null != tv) {
 
@@ -329,7 +289,7 @@
 				else
 					valval = (tv.val())+ 1;
 				
-				decodedTag = this.decodeUString(this.istream, valval);
+				decodedTag = this.decodeUString(valval);
 				
 				//Log.info(Log.FAC_ENCODING, "Unexpected: got text tag in peekStartElement; length: " + valval + " decoded tag = " + decodedTag);
 
@@ -388,7 +348,7 @@
 			// Have to distinguish genuine errors from wrong tags. Could either use
 			// a special exception subtype, or redo the work here.
 			//this.TypeAndVal
-			tv = this.decodeTypeAndVal(this.istream);
+			tv = this.decodeTypeAndVal();
 
 			if (null != tv) {
 
@@ -406,7 +366,7 @@
 					
 					// Tag value represents length-1 as tags can never be empty.
 					//String 
-					strTag = this.decodeUString(this.istream, valval);
+					strTag = this.decodeUString(valval);
 					
 					decodedTag = stringToTag(strTag);
 					
@@ -476,7 +436,7 @@
 //String	
 BinaryXMLDecoder.prototype.readUString = function(){
 			//String 
-			ustring = this.decodeUString(this.istream);	
+			ustring = this.decodeUString();	
 			this.readEndElement();
 			return ustring;
 
@@ -487,7 +447,7 @@
 BinaryXMLDecoder.prototype.readBlob = function() {
 			//byte []
 			
-			blob = this.decodeBlob(this.istream);	
+			blob = this.decodeBlob();	
 			this.readEndElement();
 			return blob;
 
@@ -527,9 +487,7 @@
 	return timestamp;
 };
 
-BinaryXMLDecoder.prototype.decodeTypeAndVal = function(
-		/*InputStream*/
-		istream) {
+BinaryXMLDecoder.prototype.decodeTypeAndVal = function() {
 	
 	/*int*/next;
 	/*int*/type = -1;
@@ -577,20 +535,18 @@
 
 
 //TypeAndVal
-BinaryXMLDecoder.peekTypeAndVal = function(
-		//InputStream 
-		istream) {
+BinaryXMLDecoder.peekTypeAndVal = function() {
 	//TypeAndVal 
 	tv = null;
 	
-	//istream.mark(LONG_BYTES*2);		
+	//this.istream.mark(LONG_BYTES*2);		
 	
 	var previousOffset = this.offset;
 	
 	try {
-		tv = this.decodeTypeAndVal(this.istream);
+		tv = this.decodeTypeAndVal();
 	} finally {
-		//istream.reset();
+		//this.istream.reset();
 		this.offset = previousOffset;
 	}
 	
@@ -600,15 +556,13 @@
 
 //byte[]
 BinaryXMLDecoder.prototype.decodeBlob = function(
-		//InputStream 
-		istream, 
 		//int 
 		blobLength) {
 	
 	
 	if(null == blobLength){
 		//TypeAndVal
-		tv = this.decodeTypeAndVal(this.istream);
+		tv = this.decodeTypeAndVal();
 
 		var valval ;
 		
@@ -619,7 +573,7 @@
 			valval = (tv.val());
 		
 		//console.log('valval here is ' + valval);
-		return  this.decodeBlob(this.istream, valval);
+		return  this.decodeBlob(valval);
 	}
 	
 	//
@@ -639,8 +593,6 @@
 
 //String
 BinaryXMLDecoder.prototype.decodeUString = function(
-		//InputStream 
-		istream, 
 		//int 
 		byteLength) {
 	
@@ -650,7 +602,7 @@
 	count++;
 	if(null == byteLength||  undefined == byteLength){
 		console.log("!!!!");
-		tv = this.decodeTypeAndVal(this.istream);
+		tv = this.decodeTypeAndVal();
 		var valval ;
 		if(typeof tv.val() == 'string'){
 			valval = (parseInt(tv.val()));
@@ -659,7 +611,7 @@
 			valval = (tv.val());
 		
 		if(LOG>4) console.log('valval  is ' + valval);
-		byteLength= this.decodeUString(this.istream, valval);
+		byteLength= this.decodeUString(valval);
 		
 		//if(LOG>4) console.log('byte Length found in type val is '+ byteLength.charCodeAt(0));
 		byteLength = parseInt(byteLength);
@@ -671,7 +623,7 @@
 	if(LOG>4)console.log('byteLength is '+byteLength);
 	if(LOG>4)console.log('type of byteLength is '+typeof byteLength);
 	
-	stringBytes = this.decodeBlob(this.istream, byteLength);
+	stringBytes = this.decodeBlob(byteLength);
 	
 	//console.log('String bytes are '+ stringBytes);
 	//console.log('stringBytes);
@@ -703,7 +655,7 @@
 		var tempStreamPosition = this.offset;
 			
 		//TypeAndVal 
-		tv = this.decodeTypeAndVal(istream);
+		tv = this.decodeTypeAndVal();
 		
 		if(LOG>3)console.log('TV is '+tv);
 		if(LOG>3)console.log(tv);
@@ -719,11 +671,11 @@
 			return "";
 		}
 			
-		return this.decodeUString(istream, tv.val());
+		return this.decodeUString(tv.val());
 	}
 	else{
 		//byte [] 
-		stringBytes = this.decodeBlob(istream, byteLength);
+		stringBytes = this.decodeBlob(byteLength);
 		
 		//return DataUtils.getUTF8StringFromBytes(stringBytes);
 		return  DataUtils.toString(stringBytes);
@@ -787,3 +739,12 @@
 		strElementText = this.readUString();
 		return strElementText;
 };
+
+/* 
+ * Set the offset into the input, used for the next read.
+ */
+BinaryXMLDecoder.prototype.seek = function(
+        //int
+        offset) {
+    this.offset = offset;        
+}
