public class WriteSocket extends AbstractSocket
socket
Constructor and Description |
---|
WriteSocket(Socket socket,
int nbBytes)
Creates a write socket action.
|
Modifier and Type | Method and Description |
---|---|
int |
getNbBytes()
Gets the number of bytes to be written.
|
void |
onEnd(boolean endWithSuccess)
Called when the execution of the action is finished.
|
void |
onStart()
Called when the execution of the action is about to start.
|
getSocket
public WriteSocket(Socket socket, int nbBytes)
socket
- the socket of the write action.nbBytes
- the number of written bytes.public int getNbBytes()
public void onEnd(boolean endWithSuccess)
endWithSuccess
- true if the execution of the action was ended with success; false otherwise.public void onStart() throws SecurityException
SecurityException
- if the action is not allowed to be performed.