/** * Creates an empty {@link Button} element. * * @return The new element. */ public static final Button button() { return new Button(); }
/** * {@doc HTML5.forms#attr-fs-menu menu} attribute. * * <p> * Specifies the element's designated pop-up menu. * * @param menu The new value for this attribute. * @return This object (for method chaining). */ public final Button menu(String menu) { attr("menu", menu); return this; }
/** * {@doc HTML5.forms#attr-fs-formaction formaction} attribute. * * <p> * URL to use for form submission. * * <p> * The value can be of any of the following types: {@link URI}, {@link URL}, {@link String}. * Strings must be valid URIs. * * <p> * URIs defined by {@link UriResolver} can be used for values. * * @param formaction The new value for this attribute. * @return This object (for method chaining). */ public final Button formaction(String formaction) { attrUri("formaction", formaction); return this; }
/** * {@doc HTML5.forms#attr-fe-disabled disabled} attribute. * * <p> * Whether the form control is disabled. * * @param disabled * The new value for this attribute. * Typically a {@link Boolean} or {@link String}. * @return This object (for method chaining). */ public final Button disabled(Object disabled) { attr("disabled", deminimize(disabled, "disabled")); return this; }
td().colspan(3).style("text-align:right").children( types.length == 0 ? null : button("reset", "Reset"), button("button","Cancel").onclick("window.location.href='/'"), button("submit", "Submit")
/** * Creates a {@link Button} element with the specified {@link Button#type(String)} attribute and * {@link Button#children(Object[])} nodes. * * @param type The {@link Button#type(String)} attribute. * @param children The {@link Button#children(Object[])} nodes. * @return The new element. */ public static final Button button(String type, Object...children) { return button().type(type).children(children); }
@RestMethod( summary="Initialize database form entry page" ) public Div getInit() { return div( form("servlet:/init").method(POST).target("buf").children( table( tr( th("Initialize petstore database:"), td(input("radio").name("init-method").value("direct").checked(true), "direct", input("radio").name("init-method").value("rest"), "rest"), td(button("submit", "Submit").style("float:right").onclick("scrolling=true")) ) ) ), br(), iframe().id("buf").name("buf").style("width:800px;height:600px;").onload("window.parent.scrolling=false;"), script("text/javascript", "var scrolling = false;", "function scroll() { if (scrolling) { document.getElementById('buf').contentWindow.scrollBy(0,50); } setTimeout('scroll()',200); } ", "scroll();" ) ); }
/** * Creates a {@link Button} element with the specified {@link Button#type(String)} attribute. * * @param type The {@link Button#type(String)} attribute. * @return The new element. */ public static final Button button(String type) { return button().type(type); }
td().colspan(3).style("text-align:right").children( types.length == 0 ? null : button("reset", "Reset"), button("button","Cancel").onclick("window.location.href='/'"), button("submit", "Submit")
/** * Creates a {@link Button} element with the specified {@link Button#type(String)} attribute and * {@link Button#children(Object[])} nodes. * * @param type The {@link Button#type(String)} attribute. * @param children The {@link Button#children(Object[])} nodes. * @return The new element. */ public static final Button button(String type, Object...children) { return button().type(type).children(children); }
/** * {@doc HTML5.forms#attr-fe-disabled disabled} attribute. * * <p> * Whether the form control is disabled. * * @param disabled * The new value for this attribute. * Typically a {@link Boolean} or {@link String}. * @return This object (for method chaining). */ public final Button disabled(Object disabled) { attr("disabled", deminimize(disabled, "disabled")); return this; }
@RestMethod( summary="Initialize database form entry page" ) public Div getInit() { return div( form("servlet:/init").method(POST).target("buf").children( table( tr( th("Initialize petstore database:"), td(input("radio").name("init-method").value("direct").checked(true), "direct", input("radio").name("init-method").value("rest"), "rest"), td(button("submit", "Submit").style("float:right").onclick("scrolling=true")) ) ) ), br(), iframe().id("buf").name("buf").style("width:800px;height:600px;").onload("window.parent.scrolling=false;"), script("text/javascript", "var scrolling = false;", "function scroll() { if (scrolling) { document.getElementById('buf').contentWindow.scrollBy(0,50); } setTimeout('scroll()',200); } ", "scroll();" ) ); }
/** * Creates a {@link Button} element with the specified {@link Button#type(String)} attribute. * * @param type The {@link Button#type(String)} attribute. * @return The new element. */ public static final Button button(String type) { return button().type(type); }
/** * {@doc HTML5.forms#attr-fs-formtarget formtarget} attribute. * * <p> * Browsing context for form submission. * * @param formtarget The new value for this attribute. * @return This object (for method chaining). */ public final Button formtarget(String formtarget) { attr("formtarget", formtarget); return this; }
td().colspan(3).style("text-align:right").children( types.length == 0 ? null : button("reset", "Reset"), button("button","Cancel").onclick("window.location.href='/'"), button("submit", "Submit")
/** * Creates a {@link Button} element with the specified {@link Button#type(String)} attribute and * {@link Button#children(Object[])} nodes. * * @param type The {@link Button#type(String)} attribute. * @param children The {@link Button#children(Object[])} nodes. * @return The new element. */ public static final Button button(String type, Object...children) { return button().type(type).children(children); }
/** * {@doc HTML5.forms#attr-fe-disabled disabled} attribute. * * <p> * Whether the form control is disabled. * * @param disabled * The new value for this attribute. * Typically a {@link Boolean} or {@link String}. * @return This object (for method chaining). */ public final Button disabled(Object disabled) { attr("disabled", deminimize(disabled, "disabled")); return this; }
/** * Creates an empty {@link Button} element. * * @return The new element. */ public static final Button button() { return new Button(); }
/** * Creates a {@link Button} element with the specified {@link Button#type(String)} attribute. * * @param type The {@link Button#type(String)} attribute. * @return The new element. */ public static final Button button(String type) { return button().type(type); }
/** * {@doc HTML5.forms#attr-fs-formaction formaction} attribute. * * <p> * URL to use for form submission. * * <p> * The value can be of any of the following types: {@link URI}, {@link URL}, {@link String}. * Strings must be valid URIs. * * <p> * URIs defined by {@link UriResolver} can be used for values. * * @param formaction The new value for this attribute. * @return This object (for method chaining). */ public final Button formaction(String formaction) { attrUri("formaction", formaction); return this; }