#include "System.h" #include "MethodResultJni.h" #include "rhodes/JNIRhoJS.h" #include "logging/RhoLog.h" #undef DEFAULT_LOGCATEGORY #define DEFAULT_LOGCATEGORY "SystemJS" typedef rho::CSystemProxy > ObjectProxy; using namespace rho::apiGenerator; rho::String js_s_System_getMain_window_closed(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getMain_window_closed(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getPlatform(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getPlatform(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasCamera(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasCamera(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getScreenWidth(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getScreenWidth(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getScreenHeight(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getScreenHeight(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getRealScreenWidth(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getRealScreenWidth(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getRealScreenHeight(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getRealScreenHeight(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getScreenOrientation(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getScreenOrientation(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getPpiX(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getPpiX(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getPpiY(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getPpiY(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getDeviceOwnerEmail(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getDeviceOwnerEmail(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getDeviceOwnerName(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getDeviceOwnerName(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getDevicePushId(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getDevicePushId(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getPhoneId(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getPhoneId(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getDeviceName(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getDeviceName(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getOsVersion(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getOsVersion(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getLocale(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getLocale(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getCountry(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getCountry(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getIsEmulator(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getIsEmulator(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getIsRhoSimulator(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getIsRhoSimulator(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasCalendar(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasCalendar(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getIsSymbolDevice(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getIsSymbolDevice(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getIsMotorolaDevice(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getIsMotorolaDevice(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getOemInfo(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getOemInfo(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getUuid(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getUuid(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getApplicationIconBadge(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getApplicationIconBadge(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setApplicationIconBadge(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setApplicationIconBadge(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHttpProxyURI(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHttpProxyURI(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setHttpProxyURI(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setHttpProxyURI(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getLockWindowSize(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getLockWindowSize(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setLockWindowSize(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setLockWindowSize(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getKeyboardState(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getKeyboardState(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setKeyboardState(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setKeyboardState(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getLocalServerPort(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getLocalServerPort(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getFreeServerPort(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getFreeServerPort(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getScreenAutoRotate(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getScreenAutoRotate(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setScreenAutoRotate(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setScreenAutoRotate(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasTouchscreen(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasTouchscreen(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getWebviewFramework(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getWebviewFramework(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getScreenSleeping(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getScreenSleeping(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setScreenSleeping(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setScreenSleeping(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasNetwork(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasNetwork(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasWifiNetwork(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasWifiNetwork(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasCellNetwork(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasCellNetwork(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getHasSqlite(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getHasSqlite(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_applicationInstall(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::applicationInstall(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_isApplicationInstalled(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::isApplicationInstalled(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_applicationUninstall(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::applicationUninstall(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getStartParams(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getStartParams(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_openUrl(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::openUrl(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_unzipFile(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 3)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::unzipFile(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_zipFile(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 3)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::zipFile(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_zipFiles(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 3) || (argc > 4)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::zipFiles(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setRegistrySetting(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setRegistrySetting(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getRegistrySetting(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getRegistrySetting(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_deleteRegistrySetting(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::deleteRegistrySetting(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setWindowFrame(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 4) || (argc > 4)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setWindowFrame(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setWindowPosition(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setWindowPosition(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setWindowSize(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setWindowSize(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_bringToFront(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::bringToFront(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_replaceCurrentBundle(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::replaceCurrentBundle(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_deleteFolder(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::deleteFolder(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setDoNotBackupAttribute(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setDoNotBackupAttribute(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_isBlobAttr(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 3) || (argc > 3)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::isBlobAttr(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_updateBlobAttribs(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::updateBlobAttribs(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_get_locale(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::get_locale(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setPushNotification(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 3)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setPushNotification(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setScreenRotationNotification(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setScreenRotationNotification(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_exit(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::exit(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_set_sleeping(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::set_sleeping(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_startTimer(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 3)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::startTimer(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_stopTimer(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::stopTimer(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setNetworkStatusNotify(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setNetworkStatusNotify(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_clearNetworkStatusNotify(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::clearNetworkStatusNotify(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_set_http_proxy_url(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::set_http_proxy_url(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_unset_http_proxy(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::unset_http_proxy(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_set_application_icon_badge(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::set_application_icon_badge(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_runApplication(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 3)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::runApplication(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_hideSplashScreen(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::hideSplashScreen(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getProperty(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getProperty(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getProperties(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getProperties(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_getAllProperties(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 0) || (argc > 0)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::getAllProperties(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setProperty(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 2) || (argc > 2)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setProperty(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; } rho::String js_s_System_setProperties(const rho::String& strObjID, rho::json::CJSONArray& argv, const rho::String& strCallbackID, const rho::String& strJsVmID, const rho::String& strCallbackParam) { RAWTRACE2("%s(id=%s)", __FUNCTION__, strObjID.c_str()); MethodResultJni result(false); if(!result) { result.setError("JNI error: failed to initialize MethodResult java object"); RAWLOG_ERROR("JNI error: failed to initialize MethodResult java object ^^^"); return CMethodResultConvertor().toJSON(result); } int argc = argv.getSize(); if((argc < 1) || (argc > 1)) { result.setArgError("Wrong number of arguments"); RAWLOG_ERROR1("Wrong number of arguments: %d ^^^", argc); return CMethodResultConvertor().toJSON(result); } if(strCallbackID.length() != 0) { result.setCallBack(strCallbackID, strCallbackParam); } ObjectProxy::setProperties(argumentsAdapter(argv), result); rho::String res = CMethodResultConvertor().toJSON(result); RAWTRACE(res.c_str()); RAWTRACE2("%s(id=%s) end ^^^", __FUNCTION__, strObjID.c_str()); return res; }