Information Technology Reference
In-Depth Information
The workbench components
In this section, we will learn how to configure our own visual components inside an
UberFire-based application. In order to understand how to build them, we need to under-
stand which types are available, and what are they used for. In the following subsections,
we will discuss four of UberFire's most used components for defining user interfaces:
• Workbench screens
• Workbench pop ups
• Workbench editors
• Workbench perspectives
Once we get to know how they work and what they do, we will learn how to build our own
user interfaces. Each visual representation in our demonstration will be based on the MVP
pattern, and will be marked by annotations added to the Presenter class. All the components
we will describe here are going to be implemented in the code files of this topic in the ap-
pendix/uberfire-demo folder.
Workbench screens
Workbench screens are pieces of visual representation that are fitted in a particular window.
From a UI point of view, they are nonfloating components that fit in the display window of
the web application. They are simple UI containers, so they can define virtually anything
inside them. Classes that should be used as workbench screens in the UberFire framework
are marked with a class-level annotation and a couple of method-level annotations, as
shown in the following code fragment:
@Dependent
@WorkbenchScreen(identifier = "myParticularScreenID")
public class MyParticularScreenPresenter {
@WorkbenchPartTitle
public String getTitle() {
return "My Particular Screen";
}
@WorkbenchPartView
public IsWidget getView() {
Search WWH ::




Custom Search