quark.ResponseHolder Maven / Gradle / Ivy
/* Quark 1.0.452 run at 2016-11-10 18:39:58.222591 */
package quark;
public class ResponseHolder implements HTTPHandler, io.datawire.quark.runtime.QObject {
public static quark.reflect.Class quark_ResponseHolder_ref = datawire_mdk_md.Root.quark_ResponseHolder_md;
public HTTPResponse response;
public HTTPError failure = null;
public ResponseHolder() {}
public void onHTTPResponse(HTTPRequest request, HTTPResponse response) {
(this).response = response;
}
public void onHTTPError(HTTPRequest request, HTTPError error) {
this.failure = error;
}
public String _getClass() {
return "quark.ResponseHolder";
}
public Object _getField(String name) {
if ((name)==("response") || ((Object)(name) != null && ((Object) (name)).equals("response"))) {
return (this).response;
}
if ((name)==("failure") || ((Object)(name) != null && ((Object) (name)).equals("failure"))) {
return (this).failure;
}
return null;
}
public void _setField(String name, Object value) {
if ((name)==("response") || ((Object)(name) != null && ((Object) (name)).equals("response"))) {
(this).response = (HTTPResponse) (value);
}
if ((name)==("failure") || ((Object)(name) != null && ((Object) (name)).equals("failure"))) {
(this).failure = (HTTPError) (value);
}
}
public void onHTTPInit(HTTPRequest request) {}
public void onHTTPFinal(HTTPRequest request) {}
}