com.upek.android.ptapi.callback
Interface PtGuiStateCallback
- All Known Implementing Classes:
- PtStdGuiStateCallback
public interface PtGuiStateCallback
Interface with callback function that an application supplies to allow the FM
API to display GUI state information to the user, and to receive
responses back.
It is guaranteed, that if an operation displays GUI, the first GUI message will be
"Begin GUI" and the last one "End GUI". At least one more call with message
"End GUI" will be sent even in the case when the application used
guiStateCallbackInvoke
byte guiStateCallbackInvoke(int guiState,
int message,
byte progress,
PtGuiSampleImage sampleBuffer,
byte[] data)
throws PtException
- Invoke callback function of this interface.
- Parameters:
guiState
- A bitmask indicating the current GUI state plus an indication
of what others parameters are available. It can be combined from values
PT_SAMPLE_AVAILABLE, PT_MESSAGE_PROVIDED and PT_PROGRESS_PROVIDED.
In the current implementation only PT_MESSAGE_PROVIDED is used.message
- The number of a message to display to the user. For message numbers
see PT_GUIMSG_XXXX. GuiState indicates if a Message is provided; if not
the parameter is 0.progress
- A Value that indicates (as a percentage) the amount of progress
in the development of a Sample/BIR. The value may be used to display a progress
bar. GuiState indicates if a sample Progress value is provided in the call;
if not the parameter is 0. This parameter is reserved for future use,
currently it is always 0.sampleBuffer
- The current sample buffer for the application to display.
GuiState indicates if a sample Buffer is provided; if not the parameter is
NULL. This parameter is reserved for future use, currently it is always NULL.data
- Optional data, which may be available for some GUI message codes.
If no data is provided the parameter is NULL.
- Returns:
- The response from the application back to the PerfectTrust Proxy
API on return from the callback. Can be one of values PT_CANCEL or PT_CONTINUE.
Other values are reserved for future use. (Corresponds with parameter pbyResponse in original function)
- Throws:
PtException
- Error code of fail, if any was occurred.
RemoteException
- Can be thrown during remote method invocation only.