Examples of JsProgram


Examples of org.hisrc.jscm.codemodel.JSProgram

  private final JSCodeModel codeModel = new CodeModelImpl();

  @Test
  public void programsPrototype() throws IOException {
    JSProgram program = codeModel.program();

    JSGlobalVariable $Object = codeModel.globalVariable("Object");
    JSGlobalVariable $navigator = codeModel.globalVariable("navigator");
    JSGlobalVariable $window = codeModel.globalVariable("window");
    JSGlobalVariable $document = codeModel.globalVariable("document");

    JSObjectLiteral _Prototype = codeModel.object();
    program.var("Prototype", _Prototype);

    {
      _Prototype.append("Version", codeModel.string("1.6.1"));
    }
    {
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.