Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: XML Java Text
I don't care how fast it will take to make it, but I want to know which is faster to be read from.
 
For example I am reading in points from a file and put into an array, which would be faster? Which class would read that particular data fast?
 
The importance of how fast it needs to be is not a problem. It is just for my own theoretical knowledge.
Posted 19-Sep-11 20:23pm
Comments
Prerak Patel at 20-Sep-11 1:25am
   
Depends on what data you have.
Philippe Mori at 20-Sep-11 19:02pm
   
Except if you have a very large number of points (a few millions), then the actual reading should not be an issue if you read the data sequentially once.

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

XML and text files are both text files.
 
The speed of reading them is the same.
 
What changes the overall time to finish is how you intend to process and store in memory the data read.
 
Obviously XML has more structure to process than a plain text file. So for pure bulk data transfer use CSV text files.
  Permalink  
Comments
Uday P.Singh at 20-Sep-11 1:30am
   
Agree 5!
TorstenH. at 20-Sep-11 2:11am
   
+5!
 
And to add in: XML is a common file format on which data is dispatched by a lot of systems.
It's useless to send data when it has no structure!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 230
1 PIEBALDconsult 150
2 DamithSL 125
3 Andreas Gieriet 90
4 Jochen Arndt 90
0 OriginalGriff 5,790
1 DamithSL 4,601
2 Maciej Los 4,012
3 Kornfeld Eliyahu Peter 3,480
4 Sergey Alexandrovich Kryukov 3,195


Advertise | Privacy | Mobile
Web04 | 2.8.141220.1 | Last Updated 20 Sep 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100