![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#11 |
|
Hobbyist Programmer
|
So.... your saying that I shouldent use xml? If you can come up with a good reason I'll consider the switch.
|
|
|
|
|
|
#12 |
|
Troll
Join Date: Apr 2005
Location: Texas
Posts: 732
Rep Power: 4
![]() |
It is entirely dependent on what you are trying to do...as with everything else.
__________________
MD5(sig) = bcef75433db02e9ad9bf81d6f7c5c270 |
|
|
|
|
|
#13 |
|
Newbie
Join Date: Oct 2005
Posts: 4
Rep Power: 0
![]() |
I myself think XML is great for only one reason. It has a standard that allows any OS or scripting language to access it. Other than that it is slow compared to other core functions found in any language I can think of. Example in PHP processing a complex structured XML file over and over again is on average 30X slower than converting that same XML file and storing it in a serialized array and accessing it from there! Other languages also have similar methods that are much faster in access and search time than processing the same XML file repeatedly. Yes XML is a great storage and transport method but in my opinion that is where it's benefits end!
IO streams, disk access can be very fast and safe as long as you allocate your file space, just like your system does, instead of writing line data, use offset to offset, right padding unused space so you can use fseek() to do random reads and writes without ever needing to lock your file. locking the offset is far better than trying to lock the file, which does not work 100% the same way on every system. But lock offset does! Sure it's more work to develop but you make a better over all service not always using core classes or functions that sometimes are not the best way to do what you are doing any ways! printf |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|