Package com.adobe.xfa.formcalc
Interface DisplayHost
-
public interface DisplayHost
Class DisplayHost defines the interface by which theCalcParser
(FormCalc scripting engine) can display message boxes in some display host, in response to a MessageBox calc.In environments where this is possible and desired, applications will need to inform the FormCalc script engine that they are capable of supporting the DisplayHost interface by invoking the
CalcParser.setDisplayHost(DisplayHost)
method.Environments that are not able to display message boxes need not define nor install a DisplayHost objects. Any MessageBox calc encountered by the FormCalc script engine will automatically return -1.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description int
messageBox(int nValue, java.lang.String sMessage, java.lang.String sTitle)
Abstract method to display a modal message box dialog on some display host.
-
-
-
Method Detail
-
messageBox
int messageBox(int nValue, java.lang.String sMessage, java.lang.String sTitle)
Abstract method to display a modal message box dialog on some display host.- Parameters:
nValue
- - the kind of message box command buttons to display in the message box. Possible values are:- 0
- OK button only.
- 1
- OK and Cancel buttons.
- 2
- Abort, Retry, and Ignore buttons.
- 3
- Yes, No, and Cancel buttons.
- 4
- Yes, and No buttons.
- 5
- Retry, and Cancel buttons.
sMessage
- the text to display in the message box.sTitle
- the title to display on the message box. If empty, some system derived title will be used instead.- Returns:
- one of the following numeric values corresponding
to the command button selected in the message box, or, -1 if the
message box could be displayed:
- 1
- for ok responses.
- 2
- for cancel responses.
- 3
- for abort responses.
- 4
- for retry responses.
- 5
- for ignore responses.
- 6
- for yes responses.
- 7
- for no responses.
-
-