java.lang.Object | |
↳ | com.google.gwt.editor.client.adapters.OptionalFieldEditor<T, E extends com.google.gwt.editor.client.Editor<T>> |
This adapter can be used when a type being edited has an optional field that
may be nullified or reassigned as part of the editing process. This consumer
of this adapter will typically expose it via the
IsEditor
interface:
class FooSelector extends Composite implements IsEditor<OptionalFieldEditor<Foo, FooEditor>> { private OptionalFieldEditor<Foo, FooEditor> editor = OptionalFieldEditor.of(new FooEditor()); public OptionalFieldEditor<Foo, FooEditor> asEditor() { return editor; } }
Protected Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Construct an OptionalFieldEditor backed by the given sub-Editor.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the sub-Editor that the OptionalFieldEditor was constructed
with.
| |||||||||||
Indicates that the Editor cycle is finished.
| |||||||||||
Returns an empty string because there is only ever one sub-editor used.
| |||||||||||
Returns the current value.
| |||||||||||
Construct an OptionalFieldEditor backed by the given sub-Editor.
| |||||||||||
Notifies the Editor that one or more value properties have changed.
| |||||||||||
Called by the EditorDriver to provide access to the EditorDelegate the
Editor is peered with.
| |||||||||||
Called by the EditorDriver to set the object the Editor is peered with
ValueAwareEditors should preferentially use sub-editors to alter the properties of the object being edited. |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
com.google.gwt.editor.client.CompositeEditor
| |||||||||||
From interface
com.google.gwt.editor.client.HasEditorDelegate
| |||||||||||
From interface
com.google.gwt.editor.client.ValueAwareEditor
| |||||||||||
From interface
com.google.gwt.user.client.TakesValue
|
Construct an OptionalFieldEditor backed by the given sub-Editor.
subEditor | the sub-Editor that will be attached to the Editor hierarchy |
---|
Returns the sub-Editor that the OptionalFieldEditor was constructed with.
Editor
of type E
Indicates that the Editor cycle is finished. This method will be called in a depth-first order by the EditorDriver, so Editors do not generally need to flush their sub-editors.
Returns an empty string because there is only ever one sub-editor used.
subEditor | an instance of the Editor type previously passed into EditorChain#attach |
---|
Returns the current value.
Construct an OptionalFieldEditor backed by the given sub-Editor.
subEditor | the sub-Editor that will be attached to the Editor hierarchy |
---|
Notifies the Editor that one or more value properties have changed. Not all backing services support property-based notifications.
paths | a list of String paths |
---|
Called by the EditorDriver to provide access to the EditorDelegate the Editor is peered with.
delegate | an EditorDelegate of type T
|
---|
Called by the EditorDriver to set the object the Editor is peered with
ValueAwareEditors should preferentially use sub-editors to alter the properties of the object being edited.
value | a value of type T |
---|