Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.

public interface TerminalTransport.Callback

Methods

public abstract void onResponse(int status, String body)The server answered, with any status.
public abstract void onError(Throwable error)No answer: the connection failed or timed out.

Method details

onResponse

public abstract void onResponse(int status, String body)
The server answered, with any status.

Parameters

status int
the HTTP status code
body String
the response body as UTF-8, empty when there was none

onError

public abstract void onError(Throwable error)
No answer: the connection failed or timed out.

Parameters

error Throwable
what went wrong