|
GWT 2.7.0 | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ClientBundleFields
Allows ResourceGenerators to define fields within the implementation class
for a bundle type. An instance of this interface will be provided via the
ResourceGenerator.createFields(com.google.gwt.core.ext.TreeLogger, com.google.gwt.resources.ext.ResourceContext, com.google.gwt.resources.ext.ClientBundleFields)
method.
Because multiple, unrelated ResourceGenerators may be generating method implementations within a single bundle implementation, it is necessary to ensure that they do not attempt to declare multiple fields with the same name. The methods in this interface will provide a guaranteed-unique identifier to use when generating method implementations.
Multiple invocations of the define(com.google.gwt.core.ext.typeinfo.JType, java.lang.String)
method with the same inputs will
result in different identifiers being produced.
Method Summary | |
---|---|
java.lang.String |
define(JType type,
java.lang.String name)
Adds a field to the bundle. |
java.lang.String |
define(JType type,
java.lang.String name,
java.lang.String initializer,
boolean isStatic,
boolean isFinal)
Adds a field to the bundle. |
Method Detail |
---|
java.lang.String define(JType type, java.lang.String name)
defineField(type, name, null, true, false)
.
type
- the declared type of the fieldname
- a Java identifier to be used as the basis for the name of the
field
java.lang.String define(JType type, java.lang.String name, java.lang.String initializer, boolean isStatic, boolean isFinal)
type
- the declared type of the fieldname
- a Java identifier to be used as the basis for the name of the
fieldinitializer
- a Java expression that will be used as the field's
initializer, or null
if no initialization expression
is desiredisStatic
- if true
the field will be declared to be
staticisFinal
- if true
the fields will be declared as final
|
GWT 2.7.0 | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |