public class WidgetBuilder extends Object
| Modifier and Type | Field and Description |
|---|---|
protected PrimeConfiguration |
configuration |
protected javax.faces.context.FacesContext |
context |
protected boolean |
endFunction |
| Constructor and Description |
|---|
WidgetBuilder(javax.faces.context.FacesContext context,
PrimeConfiguration configuration) |
| Modifier and Type | Method and Description |
|---|---|
WidgetBuilder |
append(char chr) |
WidgetBuilder |
append(Number number) |
WidgetBuilder |
append(String str) |
WidgetBuilder |
attr(String name,
Boolean value) |
WidgetBuilder |
attr(String name,
boolean value,
boolean defaultValue) |
WidgetBuilder |
attr(String name,
double value,
double defaultValue) |
WidgetBuilder |
attr(String name,
int value,
int defaultValue) |
WidgetBuilder |
attr(String name,
Number value) |
WidgetBuilder |
attr(String name,
String value) |
WidgetBuilder |
attr(String name,
String value,
String defaultValue) |
WidgetBuilder |
callback(String name,
String callback) |
WidgetBuilder |
callback(String name,
String signature,
String callback) |
void |
finish() |
WidgetBuilder |
init(String widgetClass,
String widgetVar,
String id) |
protected WidgetBuilder |
init(String widgetClass,
String widgetVar,
String id,
boolean endFunction) |
WidgetBuilder |
initWithComponentLoad(String widgetClass,
String widgetVar,
String id,
String targetId) |
WidgetBuilder |
initWithDomReady(String widgetClass,
String widgetVar,
String id) |
WidgetBuilder |
initWithWindowLoad(String widgetClass,
String widgetVar,
String id) |
WidgetBuilder |
nativeAttr(String name,
String value) |
WidgetBuilder |
nativeAttr(String name,
String value,
String defaultValue) |
WidgetBuilder |
returnCallback(String name,
String signature,
String callback) |
WidgetBuilder |
selectorAttr(String name,
String value)
This should only be used internally if the selector is directly used by jQuery on the client.
|
protected boolean endFunction
protected javax.faces.context.FacesContext context
protected PrimeConfiguration configuration
public WidgetBuilder(javax.faces.context.FacesContext context,
PrimeConfiguration configuration)
protected WidgetBuilder init(String widgetClass, String widgetVar, String id, boolean endFunction) throws IOException
widgetClass - Constructor name of the widgetwidgetVar - Name of the client side widgetid - Client id of the componentendFunction - If the init script is wrapped by a method and if the endFunction parentheses should be rendered.IOExceptionpublic WidgetBuilder init(String widgetClass, String widgetVar, String id) throws IOException
IOExceptionpublic WidgetBuilder initWithDomReady(String widgetClass, String widgetVar, String id) throws IOException
IOExceptionpublic WidgetBuilder initWithWindowLoad(String widgetClass, String widgetVar, String id) throws IOException
IOExceptionpublic WidgetBuilder initWithComponentLoad(String widgetClass, String widgetVar, String id, String targetId) throws IOException
IOExceptionpublic WidgetBuilder selectorAttr(String name, String value) throws IOException
attr(java.lang.String, java.lang.String) should be used
as the users have to escape colons like @(myForm\:myId).name - value - IOExceptionpublic WidgetBuilder attr(String name, String value) throws IOException
IOExceptionpublic WidgetBuilder nativeAttr(String name, String value) throws IOException
IOExceptionpublic WidgetBuilder nativeAttr(String name, String value, String defaultValue) throws IOException
IOExceptionpublic WidgetBuilder attr(String name, Boolean value) throws IOException
IOExceptionpublic WidgetBuilder attr(String name, Number value) throws IOException
IOExceptionpublic WidgetBuilder attr(String name, String value, String defaultValue) throws IOException
IOExceptionpublic WidgetBuilder attr(String name, double value, double defaultValue) throws IOException
IOExceptionpublic WidgetBuilder attr(String name, int value, int defaultValue) throws IOException
IOExceptionpublic WidgetBuilder attr(String name, boolean value, boolean defaultValue) throws IOException
IOExceptionpublic WidgetBuilder callback(String name, String signature, String callback) throws IOException
IOExceptionpublic WidgetBuilder returnCallback(String name, String signature, String callback) throws IOException
IOExceptionpublic WidgetBuilder callback(String name, String callback) throws IOException
IOExceptionpublic WidgetBuilder append(String str) throws IOException
IOExceptionpublic WidgetBuilder append(char chr) throws IOException
IOExceptionpublic WidgetBuilder append(Number number) throws IOException
IOExceptionpublic void finish()
throws IOException
IOExceptionCopyright © 2018. All rights reserved.