jtulach@87: /** jtulach@87: * The MIT License (MIT) jtulach@87: * jtulach@87: * Copyright (C) 2013 Jaroslav Tulach jtulach@87: * jtulach@87: * Permission is hereby granted, free of charge, to any person obtaining a copy jtulach@87: * of this software and associated documentation files (the "Software"), to deal jtulach@87: * in the Software without restriction, including without limitation the rights jtulach@87: * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell jtulach@87: * copies of the Software, and to permit persons to whom the Software is jtulach@87: * furnished to do so, subject to the following conditions: jtulach@87: * jtulach@87: * The above copyright notice and this permission notice shall be included in jtulach@87: * all copies or substantial portions of the Software. jtulach@87: * jtulach@87: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR jtulach@87: * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, jtulach@87: * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE jtulach@87: * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER jtulach@87: * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, jtulach@87: * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN jtulach@87: * THE SOFTWARE. jtulach@87: */ jtulach@87: package dew.demo.histogram; jtulach@87: jtulach@87: import net.java.html.boot.BrowserBuilder; jtulach@87: jtulach@87: jtulach@87: /** Bootstrap and initialization. */ jtulach@87: public final class Main { jtulach@87: private Main() { jtulach@87: } jtulach@87: jtulach@87: /** Launches the browser */ jtulach@87: public static void main(String... args) throws Exception { jtulach@87: BrowserBuilder.newBrowser(). jtulach@87: loadPage("pages/index.html"). jtulach@87: loadClass(Main.class). jtulach@87: invoke("onPageLoad", args). jtulach@87: showAndWait(); jtulach@87: System.exit(0); jtulach@87: } jtulach@87: jtulach@87: /** Called when page is ready */ jtulach@87: public static void onPageLoad(String... args) throws Exception { jtulach@87: Data d = new Data(); jtulach@87: d.setNumbers("15 35 55 75 95"); jtulach@87: d.applyBindings(); jtulach@87: } jtulach@87: }