Class PasswordDialog
java.lang.Object
com.levigo.jadice.web.demo.common.client.ui.PasswordDialog
Dialog which can be shown if a password is needed to open a document.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionPasswordDialog
(PageView pageView, PasswordContainingSource source) Creates a newPasswordDialog
which can then be displayed in the givenPageView
and which will set the password to the givenPasswordContainingSource
-
Method Summary
Modifier and TypeMethodDescriptionvoid
abort()
Abort the password dialog.void
Adds the password given as parameter to thisPasswordDialog
s source, appends the source to aReader
and callsReader.read(com.levigo.jadice.web.shared.model.Source, AsyncCallback)
.void
setAsyncCallback
(AsyncCallback<Document> callback) set theAsyncCallback
to be triggered when the password has been entered.void
show()
Shows thePasswordDialog
in the pageView which has been defined in the constructor and sets the focus to the PasswordDialog.
-
Constructor Details
-
Method Details
-
setAsyncCallback
set theAsyncCallback
to be triggered when the password has been entered.- Parameters:
callback
- theAsyncCallback
to be called once the password has been entered and confirmed.
-
execute
Adds the password given as parameter to thisPasswordDialog
s source, appends the source to aReader
and callsReader.read(com.levigo.jadice.web.shared.model.Source, AsyncCallback)
.- Parameters:
password
- the password to be used in the source the Reader shall use.
-
abort
public void abort()Abort the password dialog. This will call theAsyncCallback
s onFailure()-method passing on aThrowable
with a text indicating that the password dialog has been aborted. -
show
public void show()Shows thePasswordDialog
in the pageView which has been defined in the constructor and sets the focus to the PasswordDialog.
-