/**
* Extended Node interface with a basic IO API.
* @module node
* @submodule node-load
*/
/**
* The default IO complete handler.
* @method _ioComplete
* @protected
* @for Node
* @param {String} code The response code.
* @param {Object} response The response object.
* @param {Array} args An array containing the callback and selector
*/
tmp,
if (selector) {
}
this.setContent(content);
}
if (callback) {
}
};
/**
* Loads content from the given url and replaces the Node's
* existing content with the remote content.
* @method load
* @param {String} url The URL to load via XMLHttpRequest.
* @param {String} selector An optional selector representing a subset of an HTML document to load.
* @param {Function} callback An optional function to run after the content has been loaded.
* @chainable
*/
if (typeof selector == 'function') {
selector = null;
}
var config = {
context: this,
on: {
complete: this._ioComplete
},
};
return this;
}