public abstract class AbstractEntityView<T> extends SuspendableViewImpl implements FrameworkView, FrameworkPresenter, FormItemObserver
FormItemObserver.Action| Modifier and Type | Field and Description |
|---|---|
protected AddressBinding |
address |
protected Class<?> |
beanType |
protected EntityDetails<T> |
entityDetails |
protected EntityEditor<T> |
entityEditor |
protected FormMetaData |
formMetaData |
protected EnumSet<FrameworkButton> |
hideButtons |
widgetInstance| Constructor and Description |
|---|
AbstractEntityView(Class<?> beanType,
ApplicationMetaData propertyMetaData) |
AbstractEntityView(Class<?> beanType,
ApplicationMetaData propertyMetaData,
EnumSet<FrameworkButton> hideButtons) |
| Modifier and Type | Method and Description |
|---|---|
com.google.gwt.user.client.ui.Widget |
createEmbeddableWidget()
Creates a default widgets without the top most tab.
|
protected org.jboss.ballroom.client.widgets.tools.ToolStrip |
createToolStrip() |
protected org.jboss.ballroom.client.widgets.tools.ToolStrip |
createToolStrip(String resourceAddress) |
com.google.gwt.user.client.ui.Widget |
createWidget()
This is the default view assembly routine.
|
protected AddressBinding |
getAddress()
Get the DMR address for this entity.
|
abstract EntityToDmrBridge<T> |
getEntityBridge()
Get the EntityToDmrBridge for the Entity.
|
protected abstract String |
getEntityDisplayName()
Get the plural name of the Entity to be displayed.
|
protected FormMetaData |
getFormMetaData()
Get the FormMetaData for the Entity.
|
void |
initialLoad()
Call for Entities to be loaded into the view for the first time.
|
void |
initialLoad(ModelNode baseAddress) |
void |
itemAction(FormItemObserver.Action action,
ObservableFormItem item) |
protected abstract org.jboss.ballroom.client.widgets.forms.FormAdapter<T> |
makeAddEntityForm()
Create the form with fields used for creating a new Entity.
|
protected EntityPopupWindow<T> |
makeAddEntityPopup() |
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> |
makeEditEntityDetailsForm() |
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> |
makeEditEntityDetailsForm(String resourceAddress)
Creates an details for for the Entity.
|
protected EntityEditor<T> |
makeEntityEditor()
Create the EntityEditor with the following pieces:
- A title obtained from getPluralEntityName()
- A table obtained from makeEntityTable()
- An AddEntityWindow with a form from makeAddEntityForm()
- An EntityDetails with a form from makeEditEntityDetailsForm()
|
protected abstract org.jboss.ballroom.client.widgets.tables.DefaultCellTable<T> |
makeEntityTable()
Create the table with the desired columns for the Entity.
|
protected DataProviderFilter.Predicate<T> |
makeFilterPredicate() |
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> |
makeSimpleForm() |
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> |
makeSimpleForm(String resourceAddress) |
protected List<SingleEntityView<T>> |
provideAdditionalTabs(Class<?> beanType,
FormMetaData formMetaData,
FrameworkPresenter presenter)
In case a tabbed form layout is used, implementations
can provide additional custom tabs by overriding this method.
|
void |
refresh()
Called whenever there is a change to any Entity
|
void |
setDescription(String description) |
void |
setEditingEnabled(boolean isEnabled)
Called when the user requests details to be edited.
|
asWidget, onResumeaddToSlot, initWidget, removeFromSlot, setInSlotclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitasWidgetprotected Class<?> beanType
protected EnumSet<FrameworkButton> hideButtons
protected FormMetaData formMetaData
protected AddressBinding address
protected EntityEditor<T> entityEditor
protected EntityDetails<T> entityDetails
public AbstractEntityView(Class<?> beanType, ApplicationMetaData propertyMetaData)
public AbstractEntityView(Class<?> beanType, ApplicationMetaData propertyMetaData, EnumSet<FrameworkButton> hideButtons)
public void setDescription(String description)
protected FormMetaData getFormMetaData()
protected AddressBinding getAddress()
public abstract EntityToDmrBridge<T> getEntityBridge()
getEntityBridge in interface FrameworkPresenterprotected abstract org.jboss.ballroom.client.widgets.tables.DefaultCellTable<T> makeEntityTable()
protected abstract org.jboss.ballroom.client.widgets.forms.FormAdapter<T> makeAddEntityForm()
protected abstract String getEntityDisplayName()
public com.google.gwt.user.client.ui.Widget createWidget()
createWidget in interface SuspendableViewpublic com.google.gwt.user.client.ui.Widget createEmbeddableWidget()
protected org.jboss.ballroom.client.widgets.tools.ToolStrip createToolStrip()
protected org.jboss.ballroom.client.widgets.tools.ToolStrip createToolStrip(String resourceAddress)
protected EntityEditor<T> makeEntityEditor()
protected EntityPopupWindow<T> makeAddEntityPopup()
protected DataProviderFilter.Predicate<T> makeFilterPredicate()
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> makeEditEntityDetailsForm()
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> makeEditEntityDetailsForm(String resourceAddress)
protected List<SingleEntityView<T>> provideAdditionalTabs(Class<?> beanType, FormMetaData formMetaData, FrameworkPresenter presenter)
beanType - formMetaData - presenter - protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> makeSimpleForm()
protected org.jboss.ballroom.client.widgets.forms.FormAdapter<T> makeSimpleForm(String resourceAddress)
public void setEditingEnabled(boolean isEnabled)
setEditingEnabled in interface FrameworkViewisEnabled - public void initialLoad()
FrameworkViewinitialLoad in interface FrameworkViewpublic void initialLoad(ModelNode baseAddress)
public void refresh()
refresh in interface FrameworkViewpublic void itemAction(FormItemObserver.Action action, ObservableFormItem item)
itemAction in interface FormItemObserverCopyright © 2014 JBoss, a division of Red Hat. All rights reserved.