Package info.bliki.extensions.scribunto.template

Examples of info.bliki.extensions.scribunto.template.Frame


        if (executor == null) {
            throw new AssertionError("no ModuleExecutor defined");
        }
        String module = parts.get(0).trim();
        String method = parts.get(1).trim();
        Frame parent = model.getFrame();
        try {
            Map<String, String> map = getParameters(parts, model);
            return executor.run(model, module, method, new Frame(map, parent));
        } finally {
            model.setFrame(parent);
        }
    }
View Full Code Here


    }

    private LuaValue preprocess() {
        return new TwoArgFunction() {
            @Override public LuaValue call(LuaValue frameId, LuaValue text) {
                Frame frame = getFrameById(frameId);

                return valueOf(model.render(text.checkjstring()));
            }
        };
    }
View Full Code Here

            }
        };
    }

    private Frame getFrameById(LuaValue frameId) {
        Frame frame;
        if (frameId.tojstring().equals("parent")) {
            frame = currentFrame.getParent();
        } else {
            frame = currentFrame;
        }
View Full Code Here

        if (isTemplate || isModule) {
            String content = null;
            String fullPageName = parsedPagename.namespace.makeFullPagename(parsedPagename.pagename);

            if (isTemplate) {
                setFrame(new Frame(templateParameters, getFrame()));
            }

            try {
                TopicData topicData = fWikiDB.selectTopic(fullPageName);
                if (topicData != null) {
View Full Code Here

TOP

Related Classes of info.bliki.extensions.scribunto.template.Frame

Copyright © 2018 www.massapicom. 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.