You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
66 KiB

2 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. /*
  2. This file is part of Ext JS 3.4
  3. Copyright (c) 2011-2013 Sencha Inc
  4. Contact: http://www.sencha.com/contact
  5. GNU General Public License Usage
  6. This file may be used under the terms of the GNU General Public License version 3.0 as
  7. published by the Free Software Foundation and appearing in the file LICENSE included in the
  8. packaging of this file.
  9. Please review the following information to ensure the GNU General Public License version 3.0
  10. requirements will be met: http://www.gnu.org/copyleft/gpl.html.
  11. If you are unsure which license is appropriate for your use, please contact the sales department
  12. at http://www.sencha.com/contact.
  13. Build date: 2013-04-03 15:07:25
  14. */
  15. Ext.data.JsonP.Ext_direct_RemotingProvider({"alternateClassNames":[],"aliases":{},"enum":null,"parentMixins":[],"tagname":"class","subclasses":[],"extends":"Ext.direct.JsonProvider","uses":[],"html":"<div><pre class=\"hierarchy\"><h4>Hierarchy</h4><div class='subclass first-child'><a href='#!/api/Ext.util.Observable' rel='Ext.util.Observable' class='docClass'>Ext.util.Observable</a><div class='subclass '><a href='#!/api/Ext.direct.Provider' rel='Ext.direct.Provider' class='docClass'>Ext.direct.Provider</a><div class='subclass '><a href='#!/api/Ext.direct.JsonProvider' rel='Ext.direct.JsonProvider' class='docClass'>Ext.direct.JsonProvider</a><div class='subclass '><strong>Ext.direct.RemotingProvider</strong></div></div></div></div><h4>Files</h4><div class='dependency'><a href='source/RemotingProvider.html#Ext-direct-RemotingProvider' target='_blank'>RemotingProvider.js</a></div></pre><div class='doc-contents'><p>The <a href=\"#!/api/Ext.direct.RemotingProvider\" rel=\"Ext.direct.RemotingProvider\" class=\"docClass\">RemotingProvider</a> exposes access to\nserver side methods on the client (a remote procedure call (RPC) type of\nconnection where the client can initiate a procedure on the server).</p>\n\n\n\n\n<p>This allows for code to be organized in a fashion that is maintainable,\nwhile providing a clear path between client and server, something that is\nnot always apparent when using URLs.</p>\n\n\n\n\n<p>To accomplish this the server-side needs to describe what classes and methods\nare available on the client-side. This configuration will typically be\noutputted by the server-side <a href=\"#!/api/Ext.Direct\" rel=\"Ext.Direct\" class=\"docClass\">Ext.Direct</a> stack when the API description is built.</p>\n\n</div><div class='members'><div class='members-section'><div class='definedBy'>Defined By</div><h3 class='members-title icon-cfg'>Config options</h3><div class='subsection'><div id='cfg-actions' class='member first-child not-inherited'><a href='#' class='side expandable'><span>&nbsp;</span></a><div class='title'><div class='meta'><span class='defined-in' rel='Ext.direct.RemotingProvider'>Ext.direct.RemotingProvider</span><br/><a href='source/RemotingProvider.html#Ext-direct-RemotingProvider-cfg-actions' target='_blank' class='view-source'>view source</a></div><a href='#!/api/Ext.direct.RemotingProvider-cfg-actions' class='name expandable'>actions</a><span> : Object</span></div><div class='description'><div class='short'>Object literal defining the server side actions and methods. ...</div><div class='long'><p>Object literal defining the server side actions and methods. For example, if\nthe Provider is configured with:</p>\n\n<pre><code>\"actions\":{ // each property within the 'actions' object represents a server side Class \n \"TestAction\":[ // array of methods within each server side Class to be \n { // stubbed out on client\n \"name\":\"doEcho\", \n \"len\":1 \n },{\n \"name\":\"multiply\",// name of method\n \"len\":2 // The number of parameters that will be used to create an\n // array of data to send to the server side function.\n // Ensure the server sends back a Number, not a String. \n },{\n \"name\":\"doForm\",\n \"formHandler\":true, // direct the client to use specialized form handling method \n \"len\":1\n }]\n}\n</code></pre>\n\n\n<p>Note that a Store is not required, a server method can be called at any time.\nIn the following example a <b>client side</b> handler is used to call the\nserver side method \"multiply\" in the server-side \"TestAction\" Class:</p>\n\n\n<pre><code>TestAction.multiply(\n 2, 4, // pass two arguments to server, so specify len=2\n // callback function after the server is called\n // result: the result returned by the server\n // e: Ext.Direct.RemotingEvent object\n function(result, e){\n var t = e.getTransaction();\n var action = t.action; // server side Class called\n var method = t.m