当前位置: 首页>>代码示例>>Java>>正文


Java LuaState.getField方法代码示例

本文整理汇总了Java中org.keplerproject.luajava.LuaState.getField方法的典型用法代码示例。如果您正苦于以下问题:Java LuaState.getField方法的具体用法?Java LuaState.getField怎么用?Java LuaState.getField使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.keplerproject.luajava.LuaState的用法示例。


在下文中一共展示了LuaState.getField方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onSuccess

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void onSuccess(int l, Header aheader[], byte abyte0[])
{
    String s = Utils.getStringFromBytes(abyte0);
    j j1;
    j1 = (j)Utils.getGson().fromJson(s, cn/com/smartdevices/bracelet/lua/j);
    if (j1.a != 1)
    {
        Debug.i("chenee", (new StringBuilder()).append("get latest luaZipFile error (message:").append(j1.b).append(")").toString());
        return;
    }
    try
    {
        byte abyte1[] = Base64.decode(j1.c.b, 2);
        LuaZipFile luazipfile = new LuaZipFile();
        luazipfile.setVersion(j1.c.c);
        luazipfile.setZipFile(abyte1);
        LuaZipFileDao luazipfiledao = DaoManager.getInstance().getLuaZipFileDao();
        luazipfiledao.insertOrReplace(luazipfile);
        Keeper.keepLatestDBLuaVersion(j1.c.c);
        Debug.i("chenee", (new StringBuilder()).append("save DB luaZipFile onSuccess====(version:").append(j1.c.c).append(")").toString());
        a.resetLuaState();
        LuaState luastate = a.getLuaState();
        luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "setLocale");
        luastate.pushString(Locale.getDefault().toString());
        a.callLua(1, 0);
        Debug.i("chenee", (new StringBuilder()).append("zipfile count:").append(luazipfiledao.count()).toString());
        return;
    }
    catch (Exception exception)
    {
        Debug.e("chenee", (new StringBuilder()).append("get latest lua gson error!:").append(exception.getMessage()).toString());
    }
    return;
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:35,代码来源:i.java

示例2: doLuaAction

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void doLuaAction(String s)
{
    Debug.i("chenee", (new StringBuilder()).append("-------------\n").append(s).toString());
    Debug.i("chenee", "--------------------\n");
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = LuaManager.getInstance().getLuaState();
    luastate.LdoString(s);
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "doAction");
    luastate.pushJavaObject(context);
    luastate.pushJavaObject(__instance);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:13,代码来源:LuaAction.java

示例3: callLuaFunc

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void callLuaFunc(String s, EventGameUpdate eventgameupdate)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), s);
    eventgameupdate.getConfigInfo().setLuaAction(context);
    luastate.pushJavaObject(DaoManager.getInstance().getLuaListDao());
    luastate.pushJavaObject(eventgameupdate.getConfigInfo());
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:11,代码来源:LuaEvent.java

示例4: getGameInfo

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public String getGameInfo()
{
    setLocale(Locale.getDefault().toString());
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getGameInfo");
    luastate.pushJavaObject(cInfo);
    luamanager.callLua(1, 0);
    Debug.i("LuaEvent", (new StringBuilder()).append("get lua game info  =").append(cInfo.getGameInfo()).toString());
    return cInfo.getGameInfo();
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:12,代码来源:LuaEvent.java

示例5: getLuaVersion

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public String getLuaVersion()
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getLuaVersion");
    luastate.pushJavaObject(cInfo);
    luamanager.callLua(1, 0);
    String s = cInfo.getLuaVersion();
    Debug.i("LuaEvent", (new StringBuilder()).append("get lua version from local =").append(cInfo.getLuaVersion()).toString());
    return s;
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:12,代码来源:LuaEvent.java

示例6: setGoal

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void setGoal()
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    de.greenrobot.daobracelet.LuaListDao lualistdao = DaoManager.getInstance().getLuaListDao();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "dayComplete");
    luastate.pushJavaObject(lualistdao);
    luastate.pushJavaObject(cInfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:11,代码来源:LuaEvent.java

示例7: setLocale

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void setLocale(String s)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "setLocale");
    luastate.pushString(s);
    luamanager.callLua(1, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:9,代码来源:LuaEvent.java

示例8: setRecord

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void setRecord(ReportData reportdata)
{
    cInfo.setNewRecordReport(reportdata);
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    de.greenrobot.daobracelet.LuaListDao lualistdao = DaoManager.getInstance().getLuaListDao();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "newRecord");
    luastate.pushJavaObject(lualistdao);
    luastate.pushJavaObject(cInfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:12,代码来源:LuaEvent.java

示例9: testAction

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void testAction()
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    LuaAction luaaction = LuaAction.getInstance(context);
    de.greenrobot.daobracelet.LuaListDao lualistdao = DaoManager.getInstance().getLuaListDao();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "doAction2");
    luastate.pushJavaObject(context);
    luastate.pushJavaObject(luaaction);
    luastate.pushJavaObject(lualistdao);
    luamanager.callLua(3, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:13,代码来源:LuaEvent.java

示例10: luaEventAchievementMsg

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void luaEventAchievementMsg(ConfigDynamicDataInfo configdynamicdatainfo)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getAchievementMsgs");
    luastate.pushJavaObject(listDao);
    luastate.pushJavaObject(configdynamicdatainfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:10,代码来源:LuaEventMsgs.java

示例11: luaEventActivityMsg

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void luaEventActivityMsg(ConfigDynamicDataInfo configdynamicdatainfo)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getActivityMsgs");
    luastate.pushJavaObject(listDao);
    luastate.pushJavaObject(configdynamicdatainfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:10,代码来源:LuaEventMsgs.java

示例12: luaEventDefaultMsg

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void luaEventDefaultMsg(ConfigDynamicDataInfo configdynamicdatainfo)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getDefaultMsgs");
    luastate.pushJavaObject(listDao);
    luastate.pushJavaObject(configdynamicdatainfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:10,代码来源:LuaEventMsgs.java

示例13: luaEventSleepMsg

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void luaEventSleepMsg(ConfigDynamicDataInfo configdynamicdatainfo)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getSleepMsgs");
    luastate.pushJavaObject(listDao);
    luastate.pushJavaObject(configdynamicdatainfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:10,代码来源:LuaEventMsgs.java

示例14: luaEventSysInfoMsg

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void luaEventSysInfoMsg(ConfigDynamicDataInfo configdynamicdatainfo)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getSysInfoMsgs");
    luastate.pushJavaObject(listDao);
    luastate.pushJavaObject(configdynamicdatainfo);
    luamanager.callLua(2, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:10,代码来源:LuaEventMsgs.java

示例15: testLuaImp

import org.keplerproject.luajava.LuaState; //导入方法依赖的package包/类
public void testLuaImp(int i, ConfigDynamicDataInfo configdynamicdatainfo)
{
    LuaManager luamanager = LuaManager.getInstance();
    LuaState luastate = luamanager.getLuaState();
    luastate.getField(LuaState.LUA_GLOBALSINDEX.intValue(), "getEventMsgs");
    luastate.pushJavaObject(listDao);
    luastate.pushJavaObject(configdynamicdatainfo);
    luastate.pushInteger(i);
    luamanager.callLua(3, 0);
}
 
开发者ID:vishnudevk,项目名称:MiBandDecompiled,代码行数:11,代码来源:LuaEventMsgs.java


注:本文中的org.keplerproject.luajava.LuaState.getField方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。