Thank you for the addition.
I will test both scenarios and compare the result.

Harbs <harbs.li...@gmail.com> escreveu no dia sexta, 18/11/2022 à(s) 12:51:

> I always use URLBinaryLoader for network requests.
>
> It generally looks something like this:
>
> var request:URLRequest = RequestUtil.getRequest(myEndpoint);
> request.data = appendParams(params);
> var loader:URLBinaryLoader = new URLBinaryLoader();
>
> loader.onComplete = function (l:URLBinaryLoader):void{
>         // do something
> }
> loader.onError = function (l:URLBinaryLoader):void{
>         // do something
> }
> loader.load(request);
>
> The advantage of URLBinaryLoader is that you get much more information
> about the requests including header, etc.
>
> HTH,
> Harbs
>
> > On Nov 18, 2022, at 1:17 PM, Hugo Ferreira <hferreira...@gmail.com>
> wrote:
> >
> > Hi Piotr,
> >
> > Thank you.
> > Was just to confirm if is the right tool for the job.
> >
> > I was asked to the create a small demo web app (but with specific
> > requirements) and this is one of them.
> > I will reuse my effort to share the source code  in github and serve as
> one
> > more resource for new users.
> > It will be a full package: frontend, backend (.NET), database (with
> > instrunctions to recreate via SQL) and documentation.
> >
> >
> > Piotr Zarzycki <piotrzarzyck...@gmail.com> escreveu no dia sexta,
> > 18/11/2022 à(s) 11:05:
> >
> >> Hi Hugo,
> >>
> >> We are using org.apache.royale.net.HTTPService; in our production
> >> application for years now and there is no problem with that at all. :)
> >>
> >> Thanks,
> >> Piotr
> >>
> >> pt., 18 lis 2022 o 11:40 Hugo Ferreira <hferreira...@gmail.com>
> >> napisał(a):
> >>
> >>> Hi,
> >>>
> >>> I'm going to create a showcase for a very simple App (list + details)
> >> with
> >>> connection with a backend and publish in a github public repo (I'm
> doing
> >>> this for a particuar need however this can also serve as one more
> >> resource
> >>> for future Royale developers).
> >>> One of the requirements is to use a web api (REST) and not a RPC (like
> >>> AMF).
> >>>
> >>> For Royale, the HTTPService class is the the way to go or do you guys
> >>> recommend other options ?
> >>>
> >>> // add the variables to send var urlVars:URLVariables = new
> >> URLVariables();
> >>> urlVars.set("variable", key); // create the httpservice instance var
> >>> service:HTTPService = new HTTPService(); service.url = "
> >> http://domain.foo
> >>> ";
> >>> service.method = HTTPConstants.POST;
> service.addEventListener("complete",
> >>> resultCallback); service.addEventListener("ioError", faultCallback); //
> >> add
> >>> the variables service.contentData = urlVars; // trigger the service
> >>> service.send();
> >>>
> >>
> >>
> >> --
> >>
> >> Piotr Zarzycki
> >>
>
>

Reply via email to