| api : ObjectSpecific urls to call on CRUD action methods "read", "create", "update" and "destroy".
-Defaults to:api: {
+the Content-Type header in the HTTP response to "text/xml". Config Options|
| api : ObjectSpecific urls to call on CRUD action methods "read", "create", "update" and "destroy".
+Defaults to:api: {
read ... Specific urls to call on CRUD action methods "read", "create", "update" and "destroy".
Defaults to: api: {
read : undefined,
@@ -65,7 +65,7 @@ myStore.on({
});
| DataProxy | | doRequest : FunctionAbstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers.
... | DataProxy | | listeners : Object | DataProxy | | listeners : ObjectA config object containing one or more event handlers to be added to this
object during initialization. This should ... A config object containing one or more event handlers to be added to this
object during initialization. This should be a valid listeners config object as specified in the
addListener example for attaching multiple handlers at once.
@@ -120,7 +120,7 @@ Ext.DomObserver = Ext.extend(Object, {
typeAhead: true,
mode: 'local',
triggerAction: 'all'
-}); | Observable | | onRead : FunctionAbstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. ... Abstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. Callback for read action. | DataProxy | | onWrite : FunctionAbstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. ... Abstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. Callback for create, update and destroy actions. | DataProxy | | restful : BooleanDefaults to false. Set to true to operate in a RESTful manner.
+}); | Observable | | onRead : FunctionAbstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. ... Abstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. Callback for read action. | DataProxy | | onWrite : FunctionAbstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. ... Abstract method that should be implemented in all subclasses. Note: Should only be used by custom-proxy developers. Callback for create, update and destroy actions. | DataProxy | | restful : BooleanDefaults to false. Set to true to operate in a RESTful manner.
Note: this parameter will automatically be set to t... Defaults to false. Set to true to operate in a RESTful manner.
Note: this parameter will automatically be set to true if the
Ext.data.Store it is plugged into is set to restful: true . If the
@@ -151,10 +151,10 @@ Where the segments in the url are typically:
- The second segment : represents the class function, or method, that should be called.
- The third segment : represents the ID (a variable typically passed to the method).
- Refer to Ext.data.DataProxy.api for additional information. | DataProxy |
Public PropertiesPublic Properties|
| conn : ObjectThe Connection object (Or options parameter to Ext.Ajax.request) which this HttpProxy
uses to make requests to the s... The Connection object (Or options parameter to Ext.Ajax.request) which this HttpProxy
uses to make requests to the server. Properties of this object may be changed dynamically to
-change the way data is requested. | HttpProxy |
Public Methods|
| HttpProxy( Object conn )
+change the way data is requested. | HttpProxy |
Public Methods|
| HttpProxy( Object conn )
Parameters:conn : ObjectAn Ext.data.Connection object, or options parameter to Ext.Ajax.request.
Note that if this HttpProxy is being used by a Store, then the
Store's call to load will override any specified callback and params
@@ -162,12 +162,12 @@ options. In this case, use the Store's baseParams may also be
used to pass parameters known at instantiation time.
If an options parameter is passed, the singleton Ext.Ajax object will be used to make
-the request. Returns: | HttpProxy | | addEvents( Object|String o , string Optional. )
- :
+the request.Returns: | HttpProxy | | addEvents( Object|String o , string Optional. )
+ :
voidAdds the specified events to the list of events which this Observable may fire. Adds the specified events to the list of events which this Observable may fire. | Observable | | addListener( String eventName , Function handler , [Object scope ], [Object options ] )
- :
+Usage:this.addEvents('storeloaded', 'storecleared'); Returns: | Observable | | addListener( String eventName , Function handler , [Object scope ], [Object options ] )
+ :
voidAppends an event handler to this object. Appends an event handler to this object. Parameters:eventName : StringThe name of the event to listen for. handler : FunctionThe method the event invokes. scope : Object(optional) The scope (this reference) in which the handler function is executed.
If omitted, defaults to the object which fired the event. options : Object(optional) An object containing handler configuration.
properties. This may contain any of the following properties:
@@ -217,19 +217,19 @@ Or a shorthand syntax:
'mouseover' : this.onMouseOver,
'mouseout' : this.onMouseOut,
scope: this
-}); Returns: | Observable | | destroy()
- :
- voidDestroys the proxy by purging any event listeners and cancelling any active requests. Destroys the proxy by purging any event listeners and cancelling any active requests. | DataProxy | | doRequest( String action , Ext.data.Record/Ext.data.Record[] rs , Object params , Ext.data.DataReader reader , Function callback , Object scope , Object arg )
- :
+});Returns: | Observable | | destroy()
+ :
+ voidDestroys the proxy by purging any event listeners and cancelling any active requests. Destroys the proxy by purging any event listeners and cancelling any active requests. | DataProxy | | doRequest( String action , Ext.data.Record/Ext.data.Record[] rs , Object params , Ext.data.DataReader reader , Function callback , Object scope , Object arg )
+ :
voidHttpProxy implementation of DataProxy#doRequest HttpProxy implementation of DataProxy#doRequest Parameters:action : StringThe crud action type (create, read, update, destroy) rs : Ext.data.Record/Ext.data.Record[]If action is load, rs will be null params : ObjectAn object containing properties which are to be used as HTTP parameters
for the request to the remote server. reader : Ext.data.DataReaderThe Reader object which converts the data
object into a block of Ext.data.Records. callback : FunctionA function to be called after the request.
The callback is passed the following arguments:
- r : Ext.data.Record[] The block of Ext.data.Records.
- options: Options object from the action request
-- success: Boolean success indicator
scope : ObjectThe scope (this reference) in which the callback function is executed. Defaults to the browser window. arg : ObjectAn optional argument which is passed to the callback as its second parameter. Returns: | HttpProxy | | enableBubble( String/Array events )
- :
- voidEnables events fired by this Observable to bubble up an owner hierarchy by calling
+ success: Boolean success indicatorscope : ObjectThe scope (this reference) in which the callback function is executed. Defaults to the browser window. arg : ObjectAn optional argument which is passed to the callback as its second parameter. Returns: | HttpProxy | | enableBubble( String/Array events )
+ :
+ voidEnables events fired by this Observable to bubble up an owner hierarchy by calling
this.getBubbleTarget() if present... Enables events fired by this Observable to bubble up an owner hierarchy by calling
this.getBubbleTarget() if present. There is no implementation in the Observable base class.
This is commonly used by Ext.Components to bubble events to owner Containers. See Ext.Component.getBubbleTarget. The default
@@ -261,48 +261,48 @@ access the required target more quickly.
myForm.header.setStyle( 'color', 'red');
}
}
-}); | Observable | | fireEvent( String eventName , Object... args )
- :
- BooleanFires the specified event with the passed parameters (minus the event name).
+}); | Observable | | fireEvent( String eventName , Object... args )
+ :
+ BooleanFires the specified event with the passed parameters (minus the event name).
An event may be set to bubble up an Obse... | Observable | | getConnection()
- :
- ConnectionReturn the Ext.data.Connection object being used by this Proxy. | HttpProxy | | hasListener( String eventName )
- :
- BooleanChecks to see if this object has any listeners for a specified event Checks to see if this object has any listeners for a specified event | Observable | | isApiAction( String [Ext.data.Api.CREATE|READ|UPDATE|DESTROY]} )
- :
- BooleanReturns true if the specified action is defined as a unique action in the api-config.
+by calling enableBubble. | Observable | | getConnection()
+ :
+ ConnectionReturn the Ext.data.Connection object being used by this Proxy. | HttpProxy | | hasListener( String eventName )
+ :
+ BooleanChecks to see if this object has any listeners for a specified event Checks to see if this object has any listeners for a specified event | Observable | | isApiAction( String [Ext.data.Api.CREATE|READ|UPDATE|DESTROY]} )
+ :
+ BooleanReturns true if the specified action is defined as a unique action in the api-config.
request. If all API-actions a... Returns true if the specified action is defined as a unique action in the api-config.
request. If all API-actions are routed to unique urls, the xaction parameter is unecessary. However, if no api is defined
and all Proxy actions are routed to DataProxy#url, the server-side will require the xaction parameter to perform a switch to
-the corresponding code for CRUD action. Parameters:[Ext.data.Api.CREATE|READ|UPDATE|DESTROY]} : Stringaction Returns: | DataProxy | | load( Object params , Object reader , Object callback , Object scope , Object arg )
- :
- voidDeprecated load method using old method signature. See {@doRequest} for preferred method. Deprecated load method using old method signature. See {@doRequest} for preferred method. Parameters:params : Objectreader : Objectcallback : Objectscope : Objectarg : Object Returns: | DataProxy | | on( String eventName , Function handler , [Object scope ], [Object options ] )
- :
+the corresponding code for CRUD action.Parameters:[Ext.data.Api.CREATE|READ|UPDATE|DESTROY]} : Stringaction Returns: | DataProxy | | load( Object params , Object reader , Object callback , Object scope , Object arg )
+ :
+ voidDeprecated load method using old method signature. See {@doRequest} for preferred method. Deprecated load method using old method signature. See {@doRequest} for preferred method. Parameters:params : Objectreader : Objectcallback : Objectscope : Objectarg : Object Returns: | DataProxy | | on( String eventName , Function handler , [Object scope ], [Object options ] )
+ :
voidAppends an event handler to this object (shorthand for addListener.) Appends an event handler to this object (shorthand for addListener.) Parameters:eventName : StringThe type of event to listen for handler : FunctionThe method the event invokes scope : Object(optional) The scope (this reference) in which the handler function is executed.
-If omitted, defaults to the object which fired the event. options : Object(optional) An object containing handler configuration. Returns: | Observable | | onRead( String action , Object o , Object res )
- :
- void | HttpProxy | | onWrite( String action , Object trans , Object res )
- :
- voidCallback for write actions Callback for write actions | HttpProxy | | purgeListeners()
- :
- voidRemoves all listeners for this object Removes all listeners for this object | Observable | | relayEvents( Object o , Array events )
- :
- voidRelays selected events from the specified Observable as if the events were fired by this. Relays selected events from the specified Observable as if the events were fired by this. | Observable | | removeListener( String eventName , Function handler , [Object scope ] )
- :
- voidRemoves an event handler. Removes an event handler. | Observable | | request( String action , Ext.data.Record/Ext.data.Record[]/null rs , Object params , Ext.data.DataReader reader , Function callback , Object scope , Object options )
- :
- voidAll proxy actions are executed through this method. Automatically fires the "before" + action event All proxy actions are executed through this method. Automatically fires the "before" + action event | DataProxy | | resumeEvents()
- :
- voidResume firing events. (see suspendEvents)
-If events were suspended using the queueSuspended parameter, then all
+If omitted, defaults to the object which fired the event. options : Object(optional) An object containing handler configuration. Returns: | Observable | | onRead( String action , Object o , Object res )
+ :
+ void | HttpProxy | | onWrite( String action , Object trans , Object res )
+ :
+ voidCallback for write actions Callback for write actions | HttpProxy | | purgeListeners()
+ :
+ voidRemoves all listeners for this object Removes all listeners for this object | Observable | | relayEvents( Object o , Array events )
+ :
+ voidRelays selected events from the specified Observable as if the events were fired by this. Relays selected events from the specified Observable as if the events were fired by this. | Observable | | removeListener( String eventName , Function handler , [Object scope ] )
+ :
+ voidRemoves an event handler. Removes an event handler. | Observable | | request( String action , Ext.data.Record/Ext.data.Record[]/null rs , Object params , Ext.data.DataReader reader , Function callback , Object scope , Object options )
+ :
+ voidAll proxy actions are executed through this method. Automatically fires the "before" + action event All proxy actions are executed through this method. Automatically fires the "before" + action event | DataProxy | | resumeEvents()
+ :
+ voidResume firing events. (see suspendEvents)
+If events were suspended using the queueSuspended parameter, then all
event... Resume firing events. (see suspendEvents)
If events were suspended using the queueSuspended parameter, then all
-events fired during event suspension will be sent to any listeners now. | Observable | | setApi( String/Object api , String/Function url )
- :
- voidRedefines the Proxy's API or a single action of an API. Can be called with two method signatures.
+events fired during event suspension will be sent to any listeners now. | Observable | | setApi( String/Object api , String/Function url )
+ :
+ voidRedefines the Proxy's API or a single action of an API. Can be called with two method signatures.
If called with an ... Redefines the Proxy's API or a single action of an API. Can be called with two method signatures.
If called with an object as the only parameter, the object should redefine the entire API, e.g.: proxy.setApi({
read : '/users/read',
@@ -311,28 +311,28 @@ If called with an ...
Redefines the Proxy's API or a s
destroy : '/users/destroy'
});
If called with two parameters, the first parameter should be a string specifying the API action to
-redefine and the second parameter should be the URL (or function if using DirectProxy) to call for that action, e.g.: proxy.setApi(Ext.data.Api.actions.read, '/users/new_load_url');
Parameters:api : String/ObjectAn API specification object, or the name of an action. url : String/FunctionThe URL (or function if using DirectProxy) to call for the action. Returns: | DataProxy | | setUrl( String url , [Boolean makePermanent ] )
- :
+redefine and the second parameter should be the URL (or function if using DirectProxy) to call for that action, e.g.:proxy.setApi(Ext.data.Api.actions.read, '/users/new_load_url');
Parameters:api : String/ObjectAn API specification object, or the name of an action. url : String/FunctionThe URL (or function if using DirectProxy) to call for the action. Returns: | DataProxy | | setUrl( String url , [Boolean makePermanent ] )
+ :
voidUsed for overriding the url used for a single request. Designed to be called during a beforeaction event. Calling s... Used for overriding the url used for a single request. Designed to be called during a beforeaction event. Calling setUrl
will override any urls set via the api configuration parameter. Set the optional parameter makePermanent to set the url for
all subsequent requests. If not set to makePermanent, the next request will use the same url or api configuration defined
in the initial proxy configuration. | HttpProxy | | suspendEvents( Boolean queueSuspended )
- :
+(e.g.: beforeload, beforesave, etc).Returns: | HttpProxy | | suspendEvents( Boolean queueSuspended )
+ :
voidSuspend the firing of all events. (see resumeEvents) Suspend the firing of all events. (see resumeEvents) Parameters:queueSuspended : BooleanPass as true to queue up suspended events to be fired
-after the resumeEvents call instead of discarding all suspended events; Returns: | Observable | | un( String eventName , Function handler , [Object scope ] )
- :
- voidRemoves an event handler (shorthand for removeListener.) | Observable |
Public Events|
| beforeload :
- ( DataProxy this , Object params )
- Fires before a request to retrieve a data object. Fires before a request to retrieve a data object. Listeners will be called with the following arguments: | DataProxy | | beforewrite :
- ( DataProxy this , String action , Record/Array[Record] rs , Object params )
- Fires before a request is generated for one of the actions Ext.data.Api.actions.create|update|destroy
+after the resumeEvents call instead of discarding all suspended events; Returns: | Observable | | un( String eventName , Function handler , [Object scope ] )
+ :
+ voidRemoves an event handler (shorthand for removeListener.) | Observable |
Public Events|
| beforeload :
+ ( DataProxy this , Object params )
+ Fires before a request to retrieve a data object. Fires before a request to retrieve a data object. Listeners will be called with the following arguments: | DataProxy | | beforewrite :
+ ( DataProxy this , String action , Record/Array[Record] rs , Object params )
+ Fires before a request is generated for one of the actions Ext.data.Api.actions.create|update|destroy
In addition to... Fires before a request is generated for one of the actions Ext.data.Api.actions.create|update|destroy
In addition to being fired through the DataProxy instance that raised the event, this event is also fired
through the Ext.data.DataProxy class to allow for centralized processing of beforewrite events from all
-DataProxies by attaching a listener to the Ext.data.Proxy class itself. Listeners will be called with the following arguments:this : DataProxyThe proxy for the request action : String[Ext.data.Api.actions.create|update|destroy] rs : Record/Array[Record]The Record(s) to create|update|destroy. params : ObjectThe request params object. Edit params to add parameters to the request.
| DataProxy | | exception :
- ( DataProxy this , String type , String action , Object options , Object response , Mixed arg )
- Fires if an exception occurs in the Proxy during a remote request. This event is relayed
+DataProxies by attaching a listener to the Ext.data.Proxy class itself. Listeners will be called with the following arguments:this : DataProxyThe proxy for the request action : String[Ext.data.Api.actions.create|update|destroy] rs : Record/Array[Record]The Record(s) to create|update|destroy. params : ObjectThe request params object. Edit params to add parameters to the request.
| DataProxy | | exception :
+ ( DataProxy this , String type , String action , Object options , Object response , Mixed arg )
+ Fires if an exception occurs in the Proxy during a remote request. This event is relayed
through a corresponding Ext... Fires if an exception occurs in the Proxy during a remote request. This event is relayed
through a corresponding Ext.data.Store.exception,
so any Store instance may observe this event.
@@ -385,16 +385,16 @@ If the remote request returns success===false, this parameter will be null.
This parameter will only exist if the action was a write action
(Ext.data.Api.actions.create|update|destroy).
- | DataProxy | | load :
- ( DataProxy this , Object o , Object options )
- Fires before the load method's callback is called. Fires before the load method's callback is called. Listeners will be called with the following arguments: | DataProxy | | loadexception :
- ( misc misc )
- This event is deprecated. The signature of the loadexception event
+ | DataProxy | | load :
+ ( DataProxy this , Object o , Object options )
+ Fires before the load method's callback is called. Fires before the load method's callback is called. Listeners will be called with the following arguments: | DataProxy | | loadexception :
+ ( misc misc )
+ This event is deprecated. The signature of the loadexception event
varies depending on the proxy, use the catch-all... This event is deprecated. The signature of the loadexception event
varies depending on the proxy, use the catch-all exception event instead.
-This event will fire in addition to the exception event. Listeners will be called with the following arguments: | DataProxy | | write :
- ( DataProxy this , String action , Object data , Object response , Record/Record{} rs , Object options )
- Fires before the request-callback is called
+This event will fire in addition to the exception event. Listeners will be called with the following arguments: | DataProxy | | write :
+ ( DataProxy this , String action , Object data , Object response , Record/Record{} rs , Object options )
+ Fires before the request-callback is called
In addition to being fired through the DataProxy instance that raised th... Fires before the request-callback is called
In addition to being fired through the DataProxy instance that raised the event, this event is also fired
through the Ext.data.DataProxy class to allow for centralized processing of write events from all
|
|