class type t =Inheritsobject
..end
method afterRequest : Ext_data_Request.t Js.t -> bool Js.t -> unit Js.meth
Optional callback function which can be used to clean up after a request has been completed.
Parameters:
Ext_data_Request.t Js.t
The Request object
bool Js.t
True if the request was successful
method buildRequest : Ext_data_Operation.t Js.t -> Ext_data_Request.t Js.t Js.meth
Creates an Request object from Operation.
This gets called from doRequest methods in subclasses of Server proxy.
Parameters:
Ext_data_Operation.t Js.t
The operation to execute
Returns:
Ext_data_Request.t Js.t
The request object
method buildUrl : Ext_data_Request.t Js.t -> Js.js_string Js.t Js.meth
Generates a url based on a given Ext.data.Request object. By default, ServerProxy's buildUrl will add the cache-buster param to the end of the url. Subclasses may need to perform additional modifications to the url.
Parameters:
Ext_data_Request.t Js.t
The request object
Returns:
Js.js_string Js.t
The url
method create : 'a 'b. Ext_data_Operation.t Js.t -> 'a Js.callback -> 'b Js.t -> unit Js.meth
in a ServerProxy all four CRUD operations are executed in the same manner, so we delegate to doRequest in each case
Performs the given create operation.
Parameters:
Ext_data_Operation.t Js.t
The Operation to perform
_ Js.callback
Callback function to be called when the Operation has completed (whether successful or not)
_ Js.t
Scope to execute the callback function in
method destroy : 'c 'd. Ext_data_Operation.t Js.t -> 'c Js.callback -> 'd Js.t -> unit Js.meth
Performs the given destroy operation.
Parameters:
Ext_data_Operation.t Js.t
The Operation to perform
_ Js.callback
Callback function to be called when the Operation has completed (whether successful or not)
_ Js.t
Scope to execute the callback function in
method doRequest : 'e 'f. Ext_data_Operation.t Js.t -> 'e Js.callback -> 'f Js.t -> unit Js.meth
In ServerProxy subclasses, the create, read, update and destroy methods all pass through to doRequest. Each ServerProxy subclass must implement the doRequest method - see Ext.data.proxy.JsonP and Ext.data.proxy.Ajax for examples. This method carries the same signature as each of the methods that delegate to it.
Parameters:
Ext_data_Operation.t Js.t
The Ext.data.Operation object
_ Js.callback
The callback function to call when the Operation has completed
_ Js.t
The scope in which to execute the callback
method encodeFilters : Ext_util_Filter.t Js.js_array Js.t -> Js.js_string Js.t Js.meth
Encodes the array of Ext.util.Filter objects into a string to be sent in the request url. By default, this simply JSON-encodes the filter data
Parameters:
Ext_util_Filter.t Js.js_array Js.t
The array of Filter objects
Returns:
Js.js_string Js.t
The encoded filters
method encodeSorters : Ext_util_Sorter.t Js.js_array Js.t -> Js.js_string Js.t Js.meth
Encodes the array of Ext.util.Sorter objects into a string to be sent in the request url. By default, this simply JSON-encodes the sorter data
Parameters:
Ext_util_Sorter.t Js.js_array Js.t
The array of Sorter objects
Returns:
Js.js_string Js.t
The encoded sorters
method read : 'g 'h. Ext_data_Operation.t Js.t -> 'g Js.callback -> 'h Js.t -> unit Js.meth
Performs the given read operation.
Parameters:
Ext_data_Operation.t Js.t
The Operation to perform
_ Js.callback
Callback function to be called when the Operation has completed (whether successful or not)
_ Js.t
Scope to execute the callback function in
method setExtraParam : 'i. Js.js_string Js.t -> 'i Js.t -> unit Js.meth
Sets a value in the underlying extraParams.
Parameters:
Js.js_string Js.t
The key for the new value
_ Js.t
The value
method update : 'j 'k. Ext_data_Operation.t Js.t -> 'j Js.callback -> 'k Js.t -> unit Js.meth
Performs the given update operation.
Parameters:
Ext_data_Operation.t Js.t
The Operation to perform
_ Js.callback
Callback function to be called when the Operation has completed (whether successful or not)
_ Js.t
Scope to execute the callback function in