Examples of LuaTable


Examples of org.luaj.vm2.LuaTable

        return "mw.message";
    }

    @Override
    public LuaTable getInterface() {
        LuaTable iface = new LuaTable();
        iface.set("plain", messagePlain());
        iface.set("check", messageCheck());
        return iface;
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        };
    }

    @Override
    public LuaValue getSetupOptions() {
        LuaTable options = new LuaTable();

        options.set("lang", "en");
        return options;
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        final LuaString rawMessage;

        Message(LuaValue data) {
            useDB  = data.get("useDB").optboolean(false);
            lang   = data.get("lang").optjstring("en");
            keys   = data.get("keys").opttable(new LuaTable());
            params = data.get("params").opttable(new LuaTable());
            rawMessage = data.get("rawMessage").checkstring();
        }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        return "mw.html";
    }

    @Override
    public LuaTable getInterface() {
        LuaTable iface = new LuaTable();
        return iface;

    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        return "mw.title";
    }

    @Override
    public LuaTable getInterface() {
        LuaTable table = new LuaTable();
        table.set("newTitle", newTitle());
        table.set("makeTitle", makeTitle());
        table.set("getUrl", getUrl());
        table.set("getContent", getContent());
        table.set("fileExists", fileExists());
        table.set("protectionLevels", defaultFunction());
        return table;
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        };
    }

    @Override
    public LuaValue getSetupOptions() {
        LuaTable table = new LuaTable();
        table.set("thisTitle", title());
        table.set("NS_MEDIA", MEDIA_NAMESPACE_KEY.code);
        return table;
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

            LuaValue.valueOf("fragment"),
            LuaValue.valueOf("interwiki"));
    }

    private LuaValue title(LuaValue ns, LuaValue title, LuaValue fragment, LuaValue interwiki) {
        LuaTable table = new LuaTable();
        table.set("isLocal", "");
        table.set("isRedirect", "");
        table.set("subjectNsText", "");
        table.set("interwiki", interwiki);
        table.set("namespace", LuaValue.valueOf(MAIN_NAMESPACE_KEY.code));
        table.set("nsText", "");
        table.set("text", "");
        table.set("id", title);
        table.set("fragment", fragment);
        table.set("contentModel", "");
        table.set("thePartialUrl", "");
        return table;
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        return "mw.ustring";
    }

    @Override
    public LuaTable getInterface() {
        return new LuaTable();
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        return new LuaTable();
    }

    @Override
    public LuaValue getSetupOptions() {
        LuaTable table = new LuaTable();
        // https://www.mediawiki.org/wiki/Manual:$wgMaxArticleSize
        // stringLengthLimit = $wgMaxArticleSize * 1024;
        table.set("stringLengthLimit"2048 * 1024);
        table.set("patternLengthLimit", 10000);
        return table;
    }
View Full Code Here

Examples of org.luaj.vm2.LuaTable

        return "mw.site";
    }

    @Override
    public LuaTable getInterface() {
        LuaTable table = new LuaTable();
        table.set("getNsIndex", getNsIndex());
        table.set("pagesInCategory", pagesInCategory());
        table.set("pagesInNamespace", pagesInNamespace());
        table.set("usersInGroup", usersInGroup());
        return table;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.