public class

FailingRequestBuilder

extends RequestBuilder
java.lang.Object
   ↳ com.google.gwt.http.client.RequestBuilder
     ↳ com.google.gwt.user.client.rpc.impl.FailingRequestBuilder

Class Overview

A RequestBuilder that always immediately fails.

Summary

[Expand]
Inherited Fields
From class com.google.gwt.http.client.RequestBuilder
Public Constructors
FailingRequestBuilder(Throwable cause, AsyncCallback<?> rpcCallback)
Public Methods
Request send()
Sends an HTTP request based on the current builder configuration.
Request sendRequest(String requestData, RequestCallback callback)
Sends an HTTP request based on the current builder configuration with the specified data and callback.
[Expand]
Inherited Methods
From class com.google.gwt.http.client.RequestBuilder
From class java.lang.Object

Public Constructors

public FailingRequestBuilder (Throwable cause, AsyncCallback<?> rpcCallback)

Public Methods

public Request send ()

Sends an HTTP request based on the current builder configuration. If no request headers have been set, the header "Content-Type" will be used with a value of "text/plain; charset=utf-8". You must call setRequestData(String) and setCallback(RequestCallback) before calling this method.

Returns
  • a Request object that can be used to track the request

public Request sendRequest (String requestData, RequestCallback callback)

Sends an HTTP request based on the current builder configuration with the specified data and callback. If no request headers have been set, the header "Content-Type" will be used with a value of "text/plain; charset=utf-8". This method does not cache requestData or callback.

Parameters
requestData the data to send as part of the request
callback the response handler to be notified when the request fails or completes
Returns
  • a Request object that can be used to track the request