Hi Serkan,

After looking at the XMLDocument/XMLNode API, it might be a manageable amount 
of work to map it to e4x.

On the other hand, if your response from the server is a string in XML format, 
you can create an e4x XML object by doing:

    Var xml:XML = new XML(stringFromServer);

It will parse the string in the constructor.

Then instead of accessing a childNodes array, you get an XMLList that has an 
array-like API by calling:

    Var xmlChildren:XMLList = xml.children();

Then instead of an XMLNode you get an XML node:

    Var xmlChildNode:XML = xmlChildren[i];

HTH,
-Alex

From: Serkan Taş <serkan....@likyateknoloji.com>
Reply-To: "users@royale.apache.org" <users@royale.apache.org>
Date: Tuesday, October 16, 2018 at 10:15 AM
To: "users@royale.apache.org" <users@royale.apache.org>
Subject: Re: Work on Emulation

I am using xml for communicating with a Java application over http (POST/GET) 
with rest way.  Send/Receive xml.

I need to replace this messsaging infrastructure with a lightweight approach 
but not now.

Reproducing all XML staff may need too much time for sure and i am not sure how 
to go with XML/XMLList and e4x how much time it may take.

Let me go step by step, discuss and see what can i do.

Serkan.
16.10.2018 19:58 tarihinde Alex Harui yazdı:
I suppose you could try to reproduce XMLDocument.  The only reason it doesn’t 
exist is because nobody has needed it so far, but creating that could be a lot 
of work.  Is there a reason you don’t want to use XML/XMLList and e4x?  Does 
your app decode SOAP responses or are you using SimpleXMLDecoder/Encoder for 
some other network/server communication?

-Alex

From: Serkan Taş 
<serkan....@likyateknoloji.com><mailto:serkan....@likyateknoloji.com>
Reply-To: "users@royale.apache.org"<mailto:users@royale.apache.org> 
<users@royale.apache.org><mailto:users@royale.apache.org>
Date: Tuesday, October 16, 2018 at 9:40 AM
To: "users@royale.apache.org"<mailto:users@royale.apache.org> 
<users@royale.apache.org><mailto:users@royale.apache.org>
Subject: Work on Emulation

Hi,

When i have to use xml classes like SimpleXMLDecoder, SimpleXMLEncoder, etc. I 
need some class implentations like XMLNode, XMLType,XMLDocument. I created the 
emulations of Encode and Decoder and  created classes XMLNode, 
XMLType,XMLDocument with empty methods and some variables.

What will be the Royale approach for XML operations or will there be ?

Thanks
Serkan




Reply via email to