 if(dojox.sql("SELECT * FROM DOCUMENTS WHERE fileName = ?", key).length){ dojox.sql("UPDATE DOCUMENTS SET content = ? WHERE fileName = ?", value, key); for(var i = 0; i < this._documents.length; i++){ if(this._documents[i].fileName == key){ this._documents[i].content = value; break; } } }else{ dojox.sql("INSERT INTO DOCUMENTS (fileName, content) VALUES (?, ?)", key, value); this._documents.push({fileName: key, content: value}); }  
	_saveOffline: function(key, value){		// create an action object to capture this action		var action = {name: "save", key: key, value: value};				// save it in our action log for replaying when we 		// go back online		dojox.off.sync.actions.add(action);				// also add it to our offline, downloaded data		this._documents.push({fileName: key, content: value});		dojox.sql("INSERT INTO DOCUMENTS (fileName, content) VALUES (?, ?)",						key, value);				// update our UI		this._printStatus("Saved '" + key + "'");		this._addKey(key);		this._printAvailableKeys();	},
5168	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/5168/c6a281ff7e98486bd4754a45abb1f770e78608f6/editor.js/buggy/off/demos/editor/editor.js