Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1095081
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T00:04:07+00:00 2026-05-17T00:04:07+00:00

What way of reading and storing data is fastest for AS3. For debugging right

  • 0

What way of reading and storing data is fastest for AS3. For debugging right now it is just reading the raw XML, but I suspect it would be faster if I made them into nested arrays.

Would parsing the XML into nested arrays to be read later be the most efficient method?, or is there a better way to read lots of data?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T00:04:07+00:00Added an answer on May 17, 2026 at 12:04 am

    Well pasring an xml into Array has various advantage as mentioned in above comments..
    How you will get Nested Array for the sample XML

    <mynode4    swf="node4.swf" htmlpage="">
    <subheading1    swf="L4_s1.swf"     htmlpage="L4_1.htm">Work Hard</subheading1>
    <subheading2    swf="L4_s2.swf"     htmlpage="L4_2.htm">karachi</subheading2> 
    <subheading3    swf="L4_s3.swf"     htmlpage="L4_3.htm">Newyork City.</subheading3> 
    </mynode4>      
    <mynode5 swf="five.swf" htmlpage="">Here is the Test for node 5</mynode5>
    <mynode6  swf="six.swf" htmlpage="">Last node accessed</mynode6>
    

    var uLoader:URLLoader = new URLLoader()
    uLoader.addEventListener(Event.COMPLETE,onXMLLoaded)
    uLoader.load(new URLRequest(“xmldata.xml”))

    public function onXMLLoaded(event:Event):void {

        var loader:URLLoader = URLLoader(event.target);
        var root1:XML = new XML(loader.data);
        var showChilds:XMLList = root1.children();
        var nodes_names2            :Array  =   new Array();
        var nodes_swf2              :Array  =   new Array();
        var nodes_values2           :Array  =   new Array();
        var nodes_pages2            :Array  =   new Array();
    
    
        var  take_items:Array   =   recursiveXML(showChilds,nodes_names2,nodes_swf2,nodes_values2,nodes_pages2,0);
        this.nodes_names2       =   take_items[0];
        this.nodes_swf2         =   take_items[1];
        this.nodes_values2      =   take_items[2];
        this.nodes_pages2       =   take_items[3];
    
        trace( nodes_names2);
        trace( nodes_swf2);
        trace( nodes_values2);
        trace( nodes_pages2);
    

    }

    public function recursiveXML(showChilds:XMLList,nodes_names:Array,nodes_swf:Array,nodes_values:Array,nodes_pages:Array, count:int):Array
    {

            for each (var eachChild:XML in showChilds) 
            {
                if(eachChild.hasComplexContent())
                {
                    nodes_names[count]          =   new Array((eachChild.children().length()))
                    nodes_swf[count]            =   new Array((eachChild.children().length()))
                    nodes_values[count]         =   new Array((eachChild.children().length()))
                    nodes_pages[count]          =   new Array((eachChild.children().length()))
    
                    nodes_names[count][0]       =   eachChild.name()
                    nodes_swf[count][0]         =   eachChild.attribute("swf");
                    nodes_values[count][0]      =   "";
                    nodes_pages[count][0]       =   "";
                    var showChilds:XMLList      =   eachChild.children();
                    var take_items:Array        =   recursiveXML(showChilds,nodes_names[count],nodes_swf[count],nodes_values[count],nodes_pages[count] , 1);
                    nodes_names[count]          =   take_items[0];
                    nodes_swf[count]            =   take_items[1];
                    nodes_values[count]         =   take_items[2];
                    nodes_pages[count]          =   take_items[3];
                    count++;
                }
                else
                {
                    nodes_names[count]          =   eachChild.name();   
                    nodes_swf[count]            =   eachChild.attribute("swf");
                    nodes_pages[count]          =   eachChild.attribute("htmlpage");    
                    nodes_values[count]         =   eachChild.text();   
                    count++;
                }
            }
                var _items:Array    = new Array( nodes_names, nodes_swf,nodes_values,nodes_pages);
                return _items;
        }   
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I was reading a article on javascript debugging session, where author needed a way
What would you consider the proper way of storing a simple username string in
After reading What is the best way to implement nested dictionaries? why is it
I'm working my way through some ASP.NET MVC reading and I have a web
I was curious what is considered the better way to manage the reading and
I've been trying to figure out an efficient way to work without reading twice
In Java, reading environment variables is done with System.getenv() . Is there a way
Any way to make a OS X Finder like but valid XHTML/CSS search textfield
I have a question about storing site configuration data. We have a platform for
MSCRM 4.0 Problem: I'm currently storing xml files in the ISV directory along with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.