HasWidgets (GWT Javadoc)

Overview | Package | Class | Use | Deprecated | Help
| GWT 2.7.0
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.google.gwt.user.client.ui
Interface HasWidgets

All Superinterfaces:
  java.lang.Iterable<Widget>

All Known Subinterfaces:
  HasWidgets.ForIsWidget

All Known Implementing Classes:
  AbsolutePanel, CaptionPanel, CellGridImpl, CellPanel, ComplexPanel, CustomScrollPanel, DeckLayoutPanel, DeckPanel, DecoratedPopupPanel, DecoratedStackPanel, DecoratedTabPanel, DecoratorPanel, DefaultCalendarView.CellGrid, DialogBox, DisclosurePanel, DockLayoutPanel, DockPanel, FlexTable, FlowPanel, FocusPanel, FormPanel, Grid, HeaderPanel, HorizontalPanel, HorizontalSplitPanel, HTMLPanel, HTMLTable, LayoutPanel, LazyPanel, LoggingPopup, Panel, PopupPanel, RenderablePanel, ResizeLayoutPanel, RootLayoutPanel, RootPanel, ScrollPanel, SimpleLayoutPanel, SimplePanel, SplitLayoutPanel, SplitPanel, StackLayoutPanel, StackPanel, TabLayoutPanel, TabPanel, Tree, VerticalPanel, VerticalSplitPanel

    public interface HasWidgets

extends java.lang.Iterable<Widget>

A widget that implements this interface contains `widgets` and can enumerate them.

Nested Class Summary
`static interface` | `HasWidgets.ForIsWidget` Extends this interface with convenience methods to handle `IsWidget`.

Method Summary
`void` | `add(Widget w)` Adds a child widget.
`void` | `clear()` Removes all child widgets.
`java.util.Iterator<Widget>` | `iterator()` Gets an iterator for the contained widgets.
`boolean` | `remove(Widget w)` Removes a child widget.

Method Detail

### add

    void add(Widget w)

  Adds a child widget.

  Parameters:
    `w` - the widget to be added
  Throws:
    `java.lang.UnsupportedOperationException` - if this method is not supported (most often this means that a specific overload must be called)

### clear

    void clear()

  Removes all child widgets.

### iterator

    java.util.Iterator<Widget> iterator()

  Gets an iterator for the contained widgets. This iterator is required to implement `Iterator.remove()`.

  Specified by:
    `iterator` in interface `java.lang.Iterable<Widget>`

### remove

    boolean remove(Widget w)

  Removes a child widget.

  Parameters:
    `w` - the widget to be removed
  Returns:
    `true` if the widget was present

Overview | Package | Class | Use | Deprecated | Help
| GWT 2.7.0
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD