public class Head implements Renderable { public void renderOn(HtmlCanvas html) throws IOException { html .head() .macros().stylesheet("htdocs/style-01.css")) ._head(); } }
public class Head implements Renderable { public void renderOn(HtmlCanvas html) throws IOException { html .head() .title().content(canvas.getPageContext().getString("title")) .meta(name("description").add("content","renderSnake doc",false)) .macros().stylesheet("htdocs/style-01.css")) .render(JQueryLibrary.core("1.4.3")) .render(JQueryLibrary.ui("1.8.6")) .render(JQueryLibrary.baseTheme("1.8")) ._head(); } }
void appendReportPageHead(HtmlCanvas reportPageHtml) throws IOException { HtmlCanvas reportPageHead = reportPageHtml.head(); reportPageHead.macros().javascript(GOOGLE_CHARTS_URL); reportPageHead.macros().javascript(CURRENT_DIRECTORY + RES + SLASH + PIECHART_JS); reportPageHead.macros().stylesheet(CURRENT_DIRECTORY + RES + SLASH + BASIC_REPORT_CSS); reportPageHead._head(); }
private String buildHtml() { HtmlCanvas html = new HtmlCanvas(); try { html .head() .title() .content("StreamPipes Connector Worker Container") ._head() .body() .h1().write("Worker Connector Container with ID: " + this.id)._h1() ._body(); } catch (IOException e) { e.printStackTrace(); } return html.toHtml(); } }
@Override public void renderOn(HtmlCanvas html) throws IOException { html .head() .meta(charset("utf8")) .meta(name("viewport").content("width=device-width, initial-scale=1.0")) .title().content("GumTree") .macros().stylesheet("/dist/bootstrap.min.css") .macros().stylesheet("/dist/gumtree.css") ._head(); }
@Override public void renderOn(HtmlCanvas html) throws IOException { html .head() .meta(charset("utf8")) .meta(name("viewport").content("width=device-width, initial-scale=1.0")) .title().content("GumTree") .macros().stylesheet("/dist/bootstrap.min.css") .macros().stylesheet("/dist/gumtree.css") ._head(); }
private String buildHtml() { HtmlCanvas html = new HtmlCanvas(); try { HtmlCanvas tmp = html .head() .title() .content("StreamPipes Connector Master Container") ._head() .body() .h1().write("Connector Master Container")._h1() .h2().write("All Running Adapters")._h2() .ol(); tmp = getAllRunningAdapters(tmp); html = tmp._ol() ._body(); } catch (IOException e) { logger.error("Error in SP Connect Master Container: ", e); } return html.toHtml(); }
@Override public void renderOn(HtmlCanvas html) throws IOException { html.render(DocType.HTML5) .html() .head() .render(new Head()) .title().content(templateDescriptor.getDefaultTitle()) ._head() .body() .render(new BodyStart()) .render(this.component) .render(new BodyEnd()) ._body() ._html(); }
@SuppressWarnings("unchecked") protected void generateHTMLReport() throws IOException, SecurityException { html = new HtmlCanvas(); html.html().head(); writeCss(); html.title().content(title + ": Test Cases Coverage Report")._head().body(); html.h1().content("W3C Linked Data Platform (" + title + ") Test Suite: Test Cases Coverage Report"); html.p().a(href("http://www.w3.org/2012/ldp/")).content("See also W3C Linked Data Platform WG")._p(); html.p().a(href(specUri)).content("Specification Requirements Page")._p(); final String commit = BuildProperties.getRevision(); if (commit != null) { html.div() .write("Test Suite Revision: ") .a(href("https://github.com/w3c/ldp-testsuite/commit/" + commit)).content(commit)._div(); } DateFormat dateFormat = DateFormat.getDateInstance(DateFormat.MEDIUM, Locale.ENGLISH); html.div().content("Updated: " + dateFormat.format(new Date())); // Generate the summary diagrams and information createSummaryReport(); toTop(); // Go through all the classes and generate details of each test case for (@SuppressWarnings("rawtypes") Class testcaseClass: testClasses) { writeTestCasesForClass(testcaseClass); } }
private void displayResultsOnCanvas(StateSpaceExplorer.StateSpaceExplorerResults results) throws IOException, StateSpaceLoaderException { HtmlCanvas html = new HtmlCanvas(); html.html().head(); html.style(type("text/css").media("screen")).content(HTML_STYLE); html._head(); html.body(); if (results.numberOfStates < MAX_DISPLAY_STATES) { StateSpaceLoader.Results stateSpace = stateSpaceLoader.loadStateSpace(); solveSteadyState(stateSpace.records, stateSpace.stateMappings, html); } else { html.write("State space is too large to show tabular results"); html.br(); html.write("Number of states: " + results.numberOfStates); html.br(); html.write("Number of transitions: " + results.processedTransitions); } html._body()._html(); resultsPane.setText(html.toHtml()); }
try { html .head() .meta(name("viewport").content("width=device-width, initial-scale=1")) .macros().javascript("https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/js/bootstrap.min.js")
for (ISuite suite : suites) { html = new HtmlCanvas(); html.html().head();
@Override public void renderOn(HtmlCanvas html) throws IOException { html .render(DocType.HTML5) .html(lang("en")) .head() .meta(charset("utf8")) .meta(name("viewport").content("width=device-width, initial-scale=1.0")) .title().content("GumTree") .macros().javascript("/dist/jquery.min.js") .macros().javascript("/dist/codemirror.min.js") .macros().stylesheet("/dist/codemirror.css") .macros().javascript("/dist/mergely.min.js") .macros().javascript("/dist/mergely_shortcuts.js") .macros().stylesheet("/dist/mergely.css") .macros().stylesheet("/dist/mergely_custom.css") ._head() .body() .div(id("compare")) ._div() .macros().script("lhs_url = \"/left/" + id + "\";") .macros().script("rhs_url = \"/right/" + id + "\";") .macros().javascript("/dist/mergely_ajax.js") ._body() ._html(); } }
@Override public void renderOn(HtmlCanvas html) throws IOException { html .render(DocType.HTML5) .html(lang("en")) .head() .meta(charset("utf8")) .meta(name("viewport").content("width=device-width, initial-scale=1.0")) .title().content("GumTree") .macros().javascript("/dist/jquery.min.js") .macros().javascript("/dist/codemirror.min.js") .macros().stylesheet("/dist/codemirror.css") .macros().javascript("/dist/mergely.min.js") .macros().javascript("/dist/mergely_shortcuts.js") .macros().stylesheet("/dist/mergely.css") .macros().stylesheet("/dist/mergely_custom.css") ._head() .body() .div(id("compare")) ._div() .macros().script("lhs_url = \"/left/" + id + "\";") .macros().script("rhs_url = \"/right/" + id + "\";") .macros().javascript("/dist/mergely_ajax.js") ._body() ._html(); } }