Hello João,

I assume you're using PHP ? If so, I'd go with AMFPHP. However, I'm pretty
much interested on other flash/flex developers who used weborb for rails as
I plan on using it for some of my websites. Currently I'm using AMFPHP
together with CakePHP (through the CakeAMFPHP plug-in). The VO handling is
done on the client-side through a class that maps cake associative arrays to
their correspondend AS2 classes. It is possible in theory to use the amfphp
vo features with cake 1.1 but I haven't tried yet and that's also not the
question of the topic really.

Cheers,

Marcelo.

On 12/11/06, Evert | Rooftop <[EMAIL PROTECTED]> wrote:

Hi João,

The roles feature in sabreamf isn't as easily done as with amfphp, for
example. The idea is that you can catch authentication (both amf0/amf3)
and implement your own roles-system. The added benefit is that you can
for example implement an acl list, backed with a database...

Any development with sabreamf starts with making your own
'serviceinvoker' class which handles the business logic of an amf0/3
call..

You'll find a pretty good one on
http://www.adobe.com/devnet/flex/articles/remoteobject_sabreamf.html,
which also handles VO-mappings..

This is a really basic invoker which handles authentication and access
control (10% pseudo code)

Service-invoker :

class MyServiceInvoker {

  protected $username;
  protected $loggedIn = false;

  function exec() {

     $s = new SabreAMF_CallbackServer();
     $s->onAuthenticate = array($this,'authenticate');
     $s->onInvokeService = array($this,'invokeService');

  }

  function authenticate($username,$password) {

    // do a login operation here.. throw an exception if you want to
make this fail
    $this->username = $username;
    $this->loggedIn = true;

  }

  function invokeService($service,$method,$arguments) {

      // first check if the current user has the correct permissions to
invoke the method
      // if not, throw an exception

      // Most likely you want to load a class after that, and call its
method with
      // return call_user_func_array(array($object,$method),$arguments);

  }

}

João Saleiro wrote:
> I already know AMFPHP very well, so i'll try sabreAMF to make a
> comparison. I'll leave WebORB out of my choices for now. :)
> How does SabreAMF handle the roles feature?
>
> Thank you Arnoud :)
>
> João Saleiro
>
> Arnoud Bos wrote:
>
>> Hey Jao,
>>
>> I'm using amfphp at the moment. Also because it's php 4 compatible...
Also
>> you can easily make a backend for a flash 8 site in flex 2 and use the
same
>> webservices for data retrieval. So AMF0 is in fact desirable then.
Works
>> great and a nice thing is the service browser which can generate client
side
>> code. For example you can modify
>> The arp templates to support cairngorm as well.
>>
>> Also I like the way it work with value objects (easy as can be :))
>>
>> Have a look at the remote object on renaun.com It's great.
>> http://www.renaun.com/blog/index.php?s=remote+object
>>
>> There is also an example that gives you the structure to make the
backend
>> transparent in the client-side code so that it's exactly the same way
>> structured as It's using a coldfusion backend.
>>
>> There's also an example of sableamf from which I understood is quite
stable.
>>
>> But if you are using setCredentials with the remote object of renaun
check
>> jesse wardens blog to find a solution to make it work.
>>
>> Hope this helps a bit.
>> Arnoud
>>
>>
>>
>> -----Oorspronkelijk bericht-----
>> Van: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Namens
>> João Saleiro
>> Verzonden: maandag 11 december 2006 1:41
>> Aan: Open Source Flash Mailing List
>> Onderwerp: [osflash] AMFPHP vs SabreAMF vs WebORB
>>
>> Hello,
>>
>> which one do you prefer: AMFPHP, SabreAMF or WebORB, considering the
>> intention is to provide services for Flex 2?
>> All of them support roles (.setCredentials) ?
>> SabreAMF seems to be the only one supporting AMF3... is it stable
enough
>> for production purposes?
>>
>> BTW, is there already any alternative to Adobe Flex Data Services 2,
>> supporting the Data Synchronization/Data push? (just dreaming a bit...
:) )
>>
>> Thank you :)
>>
>> João Saleiro
>>
>>
>>
>>
>> _______________________________________________
>> osflash mailing list
>> [email protected]
>> http://osflash.org/mailman/listinfo/osflash_osflash.org
>>
>>
>> _______________________________________________
>> osflash mailing list
>> [email protected]
>> http://osflash.org/mailman/listinfo/osflash_osflash.org
>>
>>
>>
>
> _______________________________________________
> osflash mailing list
> [email protected]
> http://osflash.org/mailman/listinfo/osflash_osflash.org
>
>


_______________________________________________
osflash mailing list
[email protected]
http://osflash.org/mailman/listinfo/osflash_osflash.org

_______________________________________________
osflash mailing list
[email protected]
http://osflash.org/mailman/listinfo/osflash_osflash.org

Reply via email to