Hello all,
I have written a hashtable class that holds a dyanically allocated array
of structs which holds data about a visualization model. This data is
parsed via xerces from XML into this hashtable. This method works well
for small < 100K files, but I'm looking to handle 3MB files. To speed
things up, I think it would be nice to dump the hashtable to a file so
that I may undump it into memory next time the program is run. I have
no clue how to do this other than writing it out via iostream which
would give me an equivilent of flat XML file and require a ton of
processing. I would like to do something simular to SGI's OpenGL
Performer PFB format. Any thoughts?
Thanks,
-Otto Barnes 1 3160
Otto Barnes <si**@verizon.n et> wrote in message
news:bg******** **@solaris.cc.v t.edu... Hello all,
I have written a hashtable class that holds a dyanically allocated array of structs which holds data about a visualization model. This data is parsed via xerces from XML into this hashtable. This method works well for small < 100K files, but I'm looking to handle 3MB files. To speed things up, I think it would be nice to dump the hashtable to a file so that I may undump it into memory next time the program is run. I have no clue how to do this other than writing it out via iostream which would give me an equivilent of flat XML file and require a ton of processing. I would like to do something simular to SGI's OpenGL Performer PFB format. Any thoughts?
If you want to serialize your data, the only facility
available for that in standard C++ is via iostreams.
You can write your data in any format you like (prefer
text if you want the data to be portable among platforms).
I don't see what the problem is. If you want to store the
data as text, create an inserter and an extractor for your
class. If you want to store the data 'raw', use
'std::ofstream: :write()', and read it back with
'std::ifstream: :read().'
-Mike This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Brij |
last post by:
Hi Guys, kinda hopin someone has an answer to this.
I have some user information that i need to dump into a cookie, but its not
a straightforward dump.
I have a collection of data in a hashtable, which needs to be serialized
into a cookie, and read at form_load
where the hashtable will be reconstructed. i can serialize to a normal txt
file, and can add and retrive info from
hashtable, but no clue as to how it would be done with a...
|
by: Matthias Kwiedor |
last post by:
Hi@all!
I have a app (c#) where i load up a external dll (managed code from c#)
with a small arraylist and hashtable in two routines (about 40000 objects
in each arraylist and hashtable).
If i load the dll everything is fine and when i load then the objects into
an Hashtable or Arraylist of the main program it freezes 5MB each which i
don't get free. The weird think is, when i reload the Tables a second time
on a new local variable...
|
by: Derrick |
last post by:
I'm seeing what looks like a leak with Hashtable, but guessing it is
something I'm doing -
void func1()
{
Hashtable hash = getHash();
//Loop thru assorted data, check to see if data exists as key in
hashtable.
|
by: JackRazz |
last post by:
Is it possible to create a hashtable that doesn't store the key? I have a very large
hashtable and I just want it to store the HashCode and the Value (two Int16s).
Thanks - JackRazz
|
by: MioTheGreat |
last post by:
I know how to take a single hashtable, and then use a binaryformatter
and a filestream to dump it to a file, but I need to serialize and
deserialize a hashtable inside a class. I've been trying this:
public Hashtable Directions;
public byte DirectionsSerialized
{
get
| |
by: Microsoft News Server |
last post by:
Hi,
I am currently having a problem with random, intermittent lock ups in my
ASP.net application on our production server (99% CPU usage by 3 threads,
indefinately). I currently use IIS Debug Tools to do a memory dump of the
app when the lock up occurs, however the stack information is not very
useful.
I have just put a new build of our system onto production, and this build is
a "Debug" build as opposed to a "Release" build. I am...
|
by: chrisben |
last post by:
Hi,
Here is the scenario. I have a list of IDs and there are multiple threads
trying to add/remove/read from this list. I can do in C#
1. create Hashtable hList = Hashtable.Synchronized(new Hashtable());
2. create ArrayList aList = ArrayList.Synchronized(new ArrayList());
3. create a string sList = "";
For 1 and 2, since the list is synced, many threads can directly
|
by: Hafiz |
last post by:
Hello,
do you have any idea which Hashtable takes more memory ...I mean if we
declare Hashtable in C# and in Delphi which one take more memorey? any
idea ?
regards,
|
by: raylopez99 |
last post by:
Hello all—
I’m trying to get the below to work and cannot get the format right.
It’s from this example: http://msdn.microsoft.com/en-us/library/8627sbea(VS.71).aspx
What it is: I’m trying to store multicast delegates in a hash table,
and then fire the delegates one of two ways (after registering/
creating the delegates, etc).
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |