程序包 web_tools
接口 TransmissionListener<T extends Serializable>
- 类型参数:
T
- The class type of the message you want to receive.
public interface TransmissionListener<T extends Serializable>
A listener that can be used to listen to the transmission of the proxy class
TransmissionController
.
Use template to make the class more flexible, and easy to use.- 版本:
- beta1.1
-
嵌套类概要
修饰符和类型接口说明static enum
The error type of the proxy classTransmissionController
. -
方法概要
修饰符和类型方法说明void
alertError
(String error) 已过时。void
If the message has been sent successfully, the method will be called.void
onTransmissionError
(String message, TransmissionListener.ErrorType errorType) When an error happens in the proxy classTransmissionController
, this method will be called.void
onTransmissionProgress
(T messages) The most important method in the interfaceTransmissionListener
.void
If the message begin to send, this method will be called.
-
方法详细资料
-
onTransmissionStart
void onTransmissionStart()If the message begin to send, this method will be called. -
onTransmissionEnd
void onTransmissionEnd()If the message has been sent successfully, the method will be called. -
onTransmissionError
When an error happens in the proxy classTransmissionController
, this method will be called.- 参数:
message
- The message from the proxy.errorType
- ErrorType.
-
onTransmissionProgress
The most important method in the interfaceTransmissionListener
. When the proxy classTransmissionController
receives a message, this method will be called.- 参数:
messages
- The messages from the proxy. Should be serialised!- 另请参阅:
-
alertError
已过时。A temp method similar toonTransmissionError
.- 参数:
error
- A string that contains the error message.
-