Upgrade to ExtJS 4.0.0 - Released 04/26/2011
[extjs.git] / docs / source / Transaction.html
1 <!DOCTYPE html><html><head><title>Sencha Documentation Project</title><link rel="stylesheet" href="../reset.css" type="text/css"><link rel="stylesheet" href="../prettify.css" type="text/css"><link rel="stylesheet" href="../prettify_sa.css" type="text/css"><script type="text/javascript" src="../prettify.js"></script></head><body onload="prettyPrint()"><pre class="prettyprint"><pre><span id='Ext-direct.Transaction-method-constructor'><span id='Ext-direct.Transaction'>/**
2 </span></span> * @class Ext.direct.Transaction
3  * @extends Object
4  * &lt;p&gt;Supporting Class for Ext.Direct (not intended to be used directly).&lt;/p&gt;
5  * @constructor
6  * @param {Object} config
7  */
8 Ext.define('Ext.direct.Transaction', {
9     
10     /* Begin Definitions */
11    
12     alias: 'direct.transaction',
13     alternateClassName: 'Ext.Direct.Transaction',
14    
15     statics: {
16         TRANSACTION_ID: 0
17     },
18    
19     /* End Definitions */
20    
21     constructor: function(config){
22         var me = this;
23         
24         Ext.apply(me, config);
25         me.id = ++me.self.TRANSACTION_ID;
26         me.retryCount = 0;
27     },
28    
29     send: function(){
30          this.provider.queueTransaction(this);
31     },
32
33     retry: function(){
34         this.retryCount++;
35         this.send();
36     },
37
38     getProvider: function(){
39         return this.provider;
40     }
41 });
42 </pre></pre></body></html>