1 | <div class="body-wrap"> |
---|
2 | <div class="top-tools"> |
---|
3 | <a class="inner-link" href="#Ext.state.Provider-props"><img src="../resources/images/default/s.gif" class="item-icon icon-prop">Properties</a> |
---|
4 | <a class="inner-link" href="#Ext.state.Provider-methods"><img src="../resources/images/default/s.gif" class="item-icon icon-method">Methods</a> |
---|
5 | <a class="inner-link" href="#Ext.state.Provider-events"><img src="../resources/images/default/s.gif" class="item-icon icon-event">Events</a> |
---|
6 | <a class="bookmark" href="../docs/?class=Ext.state.Provider"><img src="../resources/images/default/s.gif" class="item-icon icon-fav">Direct Link</a> |
---|
7 | </div> |
---|
8 | <h1>Class Ext.state.Provider</h1> |
---|
9 | <table cellspacing="0"> |
---|
10 | <tr><td class="label">Package:</td><td class="hd-info">Ext.state</td></tr> |
---|
11 | <tr><td class="label">Defined In:</td><td class="hd-info"><a href="../src/Provider.js" target="_blank">Provider.js</a></td></tr> |
---|
12 | <tr><td class="label">Class:</td><td class="hd-info">Provider</td></tr> |
---|
13 | <tr><td class="label">Subclasses:</td><td class="hd-info"><a ext:cls="Ext.air.FileProvider" href="output/Ext.air.FileProvider.html">FileProvider</a>, <a ext:cls="Ext.state.CookieProvider" href="output/Ext.state.CookieProvider.html">CookieProvider</a></td></tr> |
---|
14 | <tr><td class="label">Extends:</td><td class="hd-info">Object</td></tr> |
---|
15 | </table> |
---|
16 | <div class="description"> |
---|
17 | * |
---|
18 | Abstract base class for state provider implementations. This class provides methods |
---|
19 | for encoding and decoding <b>typed</b> variables including dates and defines the |
---|
20 | Provider interface. </div> |
---|
21 | |
---|
22 | <div class="hr"></div> |
---|
23 | <a id="Ext.state.Provider-props"></a> |
---|
24 | <h2>Public Properties</h2> |
---|
25 | <div class="no-members">This class has no public properties.</div> <a id="Ext.state.Provider-methods"></a> |
---|
26 | <h2>Public Methods</h2> |
---|
27 | <table cellspacing="0" class="member-table"> |
---|
28 | <tr> |
---|
29 | <th class="sig-header" colspan="2">Method</th> |
---|
30 | <th class="msource-header">Defined By</th> |
---|
31 | </tr> |
---|
32 | <tr class="method-row expandable"> |
---|
33 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
34 | <td class="sig"> |
---|
35 | <a id="Ext.state.Provider-clear"></a> |
---|
36 | <b>clear</b>( <code>String name</code> ) : void <div class="mdesc"> |
---|
37 | <div class="short">Clears a value from the state</div> |
---|
38 | <div class="long"> |
---|
39 | Clears a value from the state <div class="mdetail-params"> |
---|
40 | <strong>Parameters:</strong> |
---|
41 | <ul><li><code>name</code> : String<div class="sub-desc">The key name</div></li> </ul> |
---|
42 | <strong>Returns:</strong> |
---|
43 | <ul> |
---|
44 | <li><code>void</code></li> |
---|
45 | </ul> |
---|
46 | </div> |
---|
47 | </div> |
---|
48 | </div> |
---|
49 | </td> |
---|
50 | <td class="msource">Provider</td> |
---|
51 | </tr> |
---|
52 | <tr class="method-row alt expandable"> |
---|
53 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
54 | <td class="sig"> |
---|
55 | <a id="Ext.state.Provider-decodeValue"></a> |
---|
56 | <b>decodeValue</b>( <code>String value</code> ) : Mixed <div class="mdesc"> |
---|
57 | <div class="short">Decodes a string previously encoded with <a ext:cls="Ext.state.Provider" ext:member="encodeValue" href="output/Ext.state.Provider.html#encodeValue">encodeValue</a>.</div> |
---|
58 | <div class="long"> |
---|
59 | Decodes a string previously encoded with <a ext:cls="Ext.state.Provider" ext:member="encodeValue" href="output/Ext.state.Provider.html#encodeValue">encodeValue</a>. <div class="mdetail-params"> |
---|
60 | <strong>Parameters:</strong> |
---|
61 | <ul><li><code>value</code> : String<div class="sub-desc">The value to decode</div></li> </ul> |
---|
62 | <strong>Returns:</strong> |
---|
63 | <ul> |
---|
64 | <li><code>Mixed</code><div class="sub-desc">The decoded value</div></li> |
---|
65 | </ul> |
---|
66 | </div> |
---|
67 | </div> |
---|
68 | </div> |
---|
69 | </td> |
---|
70 | <td class="msource">Provider</td> |
---|
71 | </tr> |
---|
72 | <tr class="method-row expandable"> |
---|
73 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
74 | <td class="sig"> |
---|
75 | <a id="Ext.state.Provider-encodeValue"></a> |
---|
76 | <b>encodeValue</b>( <code>Mixed value</code> ) : String <div class="mdesc"> |
---|
77 | <div class="short">Encodes a value including type information. Decode with <a ext:cls="Ext.state.Provider" ext:member="decodeValue" href="output/Ext.state.Provider.html#decodeValue">decodeValue</a>.</div> |
---|
78 | <div class="long"> |
---|
79 | Encodes a value including type information. Decode with <a ext:cls="Ext.state.Provider" ext:member="decodeValue" href="output/Ext.state.Provider.html#decodeValue">decodeValue</a>. <div class="mdetail-params"> |
---|
80 | <strong>Parameters:</strong> |
---|
81 | <ul><li><code>value</code> : Mixed<div class="sub-desc">The value to encode</div></li> </ul> |
---|
82 | <strong>Returns:</strong> |
---|
83 | <ul> |
---|
84 | <li><code>String</code><div class="sub-desc">The encoded value</div></li> |
---|
85 | </ul> |
---|
86 | </div> |
---|
87 | </div> |
---|
88 | </div> |
---|
89 | </td> |
---|
90 | <td class="msource">Provider</td> |
---|
91 | </tr> |
---|
92 | <tr class="method-row alt expandable"> |
---|
93 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
94 | <td class="sig"> |
---|
95 | <a id="Ext.state.Provider-get"></a> |
---|
96 | <b>get</b>( <code>String name</code>, <code>Mixed defaultValue</code> ) : Mixed <div class="mdesc"> |
---|
97 | <div class="short">Returns the current value for a key</div> |
---|
98 | <div class="long"> |
---|
99 | Returns the current value for a key <div class="mdetail-params"> |
---|
100 | <strong>Parameters:</strong> |
---|
101 | <ul><li><code>name</code> : String<div class="sub-desc">The key name</div></li><li><code>defaultValue</code> : Mixed<div class="sub-desc">A default value to return if the key's value is not found</div></li> </ul> |
---|
102 | <strong>Returns:</strong> |
---|
103 | <ul> |
---|
104 | <li><code>Mixed</code><div class="sub-desc">The state data</div></li> |
---|
105 | </ul> |
---|
106 | </div> |
---|
107 | </div> |
---|
108 | </div> |
---|
109 | </td> |
---|
110 | <td class="msource">Provider</td> |
---|
111 | </tr> |
---|
112 | <tr class="method-row expandable"> |
---|
113 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
114 | <td class="sig"> |
---|
115 | <a id="Ext.state.Provider-set"></a> |
---|
116 | <b>set</b>( <code>String name</code>, <code>Mixed value</code> ) : void <div class="mdesc"> |
---|
117 | <div class="short">Sets the value for a key</div> |
---|
118 | <div class="long"> |
---|
119 | Sets the value for a key <div class="mdetail-params"> |
---|
120 | <strong>Parameters:</strong> |
---|
121 | <ul><li><code>name</code> : String<div class="sub-desc">The key name</div></li><li><code>value</code> : Mixed<div class="sub-desc">The value to set</div></li> </ul> |
---|
122 | <strong>Returns:</strong> |
---|
123 | <ul> |
---|
124 | <li><code>void</code></li> |
---|
125 | </ul> |
---|
126 | </div> |
---|
127 | </div> |
---|
128 | </div> |
---|
129 | </td> |
---|
130 | <td class="msource">Provider</td> |
---|
131 | </tr> |
---|
132 | </table> |
---|
133 | <a id="Ext.state.Provider-events"></a> |
---|
134 | <h2>Public Events</h2> |
---|
135 | <table cellspacing="0" class="member-table"> |
---|
136 | <tr> |
---|
137 | <th class="sig-header" colspan="2">Event</th> |
---|
138 | <th class="msource-header">Defined By</th> |
---|
139 | </tr> |
---|
140 | <tr class="event-row expandable"> |
---|
141 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
142 | <td class="sig"> |
---|
143 | <a id="Ext.state.Provider-statechange"></a> |
---|
144 | <b>statechange</b> : ( <code>Provider this</code>, <code>String key</code>, <code>String value</code> ) <div class="mdesc"> |
---|
145 | <div class="short">Fires when a state change occurs.</div> |
---|
146 | <div class="long"> |
---|
147 | Fires when a state change occurs. <div class="mdetail-params"> |
---|
148 | <strong style="font-weight:normal;">Listeners will be called with the following arguments:</strong> |
---|
149 | <ul><li><code>this</code> : Provider<div class="sub-desc">This state provider</div></li><li><code>key</code> : String<div class="sub-desc">The state key which was changed</div></li><li><code>value</code> : String<div class="sub-desc">The encoded value for the state</div></li> </ul> |
---|
150 | </div> |
---|
151 | </div> |
---|
152 | </div> |
---|
153 | </td> |
---|
154 | <td class="msource">Provider</td> |
---|
155 | </tr> |
---|
156 | </table> |
---|
157 | |
---|
158 | </div> |
---|