Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.
public interface CloudHttp.Reauthenticator
What
#retryOn401(CloudHttpTransport.Handler, Reauthenticator) does
when a request is refused with 401: refresh the credentials, then send
the same request again without another retry.Methods
public abstract AsyncResource<?> refresh() | Starts refreshing the credentials. |
public abstract void resend() | Sends the original request again with the fresh credentials, to the original handler, without retrying a second time. |
Method details
refresh
public abstract AsyncResource<?> refresh()Starts refreshing the credentials.
Returns
a resource that completes when fresh credentials are in place
resend
public abstract void resend()Sends the original request again with the fresh credentials, to
the original handler, without retrying a second time.