public static final class HTMLDialog.Builder extends Object
HTMLDialog
. The HTMLDialog
annotation
generates boilderplate code for you
and can do some compile times checks helping you to get warnings
as soon as possible.Modifier and Type | Method and Description |
---|---|
HTMLDialog.Builder |
addResources(String... res)
Registers resources to be available for the
HTMLDialog.url() page. |
HTMLDialog.Builder |
addTechIds(String... ids)
Requests some of provided technologies.
|
<C> C |
component(Class<C> type)
Obtains the component from the builder.
|
HTMLDialog.Builder |
loadFinished(Runnable run)
Registers a runnable to be executed when the page
becomes ready.
|
static HTMLDialog.Builder |
newDialog(String url)
Starts creation of a new HTML dialog.
|
void |
show(HTMLDialog.OnSubmit s)
Displays the dialog and returns immediately.
|
String |
showAndWait()
Displays the dialog and waits.
|
public static HTMLDialog.Builder newDialog(String url)
HTMLDialog
.url
- URL (usually using nbresloc
protocol)
of the page to display in the dialog.public HTMLDialog.Builder loadFinished(Runnable run)
run
- runnable to runpublic HTMLDialog.Builder addResources(String... res)
HTMLDialog.url()
page.
The rendering system shall make sure these resources are available when
the main page
is loaded and are at the same relative
locations like the page.res
- list of resources to add to the builderpublic HTMLDialog.Builder addTechIds(String... ids)
technology ids
. One can specify the preferred ones
to use in this NetBeans component by using calling this method.ids
- list of preferred technology ids to add to the builderpublic String showAndWait()
null
if the dialog was closed without selecting a buttonpublic void show(HTMLDialog.OnSubmit s)
s
- callback to call when a button is clicked and dialog
is about to be closedpublic <C> C component(Class<C> type)