Upgrade to ExtJS 4.0.7 - Released 10/19/2011
[extjs.git] / src / data / Request.js
1 /*
2
3 This file is part of Ext JS 4
4
5 Copyright (c) 2011 Sencha Inc
6
7 Contact:  http://www.sencha.com/contact
8
9 GNU General Public License Usage
10 This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE included in the packaging of this file.  Please review the following information to ensure the GNU General Public License version 3.0 requirements will be met: http://www.gnu.org/copyleft/gpl.html.
11
12 If you are unsure which license is appropriate for your use, please contact the sales department at http://www.sencha.com/contact.
13
14 */
15 /**
16  * @author Ed Spencer
17  * 
18  * Simple class that represents a Request that will be made by any {@link Ext.data.proxy.Server} subclass.
19  * All this class does is standardize the representation of a Request as used by any ServerProxy subclass,
20  * it does not contain any actual logic or perform the request itself.
21  */
22 Ext.define('Ext.data.Request', {
23     /**
24      * @cfg {String} action
25      * The name of the action this Request represents. Usually one of 'create', 'read', 'update' or 'destroy'.
26      */
27     action: undefined,
28     
29     /**
30      * @cfg {Object} params
31      * HTTP request params. The Proxy and its Writer have access to and can modify this object.
32      */
33     params: undefined,
34     
35     /**
36      * @cfg {String} method
37      * The HTTP method to use on this Request. Should be one of 'GET', 'POST', 'PUT' or 'DELETE'.
38      */
39     method: 'GET',
40     
41     /**
42      * @cfg {String} url
43      * The url to access on this Request
44      */
45     url: undefined,
46
47     /**
48      * Creates the Request object.
49      * @param {Object} [config] Config object.
50      */
51     constructor: function(config) {
52         Ext.apply(this, config);
53     }
54 });