Results 1 to 2 of 2

Thread: RemotingProvider - actions Object question

  1. #1
    Sencha User
    Join Date
    Sep 2007
    Location
    Tulsa, Oklahoma
    Posts
    178
    Vote Rating
    1
      0  

    Question RemotingProvider - actions Object question

    Looking at the documentation for the RemotingProvider, the actions are an object literal.

    It goes one to state that "each property within the 'actions' object represents a server side Class".

    My question is, should the actions really be an array of server side classes? Therefore allowing a provider to have multiple server classes defined. I understand that I can create another property for actions that is a server class, but to me it would seem to be better if it were an array of server classes, not just another property. Have not looked at the source much here, so not sure how big of an impact that would be.

    It would also seem to be easier then to generate the JSON API for the provider. You build an API class that has an array of sub-classes which are then your actions (which in turn contain the actual methods/functions to be called).

    Code:
    $API = new someBaseAPI();
    
    $API->actions[] = new dbActionClass;     //contains related functions
    $API->actions[] = new loginActionClass;  //contains related functions
    $API->actions[] = new appActionClass;   //contains related functions
    ...
    Thanks!
    Chuck

  2. #2
    Sencha User
    Join Date
    Sep 2007
    Location
    Tulsa, Oklahoma
    Posts
    178
    Vote Rating
    1
      0  

    Default

    Hmm....
    I guess not?
    Thanks!
    Chuck

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •