473,413 Members | 1,875 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,413 software developers and data experts.

passing the ball

Hi,

I have a program that creates some data, this data needs to be parsed but
depending on the data created, it'll need to be parsed in a different
method. I need the facility to add different parsing methods at will without
the need to recompile. The only way I could think to do this (apart from
writing a parsing script language ;o) was to create separate programs to
manage the data. Maybe diagram would explain this better.
main program (test.exe)
--------------
if (datatype == 1) data > parse1.exe
results < parse1.exe
if (datatype == 2) data > parse2.exe
results < parse2.exe

I think that explains it?

My question is, how can I pass a large string (about 3k) to and from the
parser programs? For speed, I'd like to avoid writing to a file and keep
everything in RAM of at all possible.

Thanks in advance.

Treefrog
Nov 15 '05 #1
1 1213
Treefrog <tr******@nospamspamnohatespam.mountainbikes.co.uk > wrote:
I have a program that creates some data, this data needs to be parsed but
depending on the data created, it'll need to be parsed in a different
method. I need the facility to add different parsing methods at will without
the need to recompile. The only way I could think to do this (apart from
writing a parsing script language ;o) was to create separate programs to
manage the data. Maybe diagram would explain this better.


No - a better way of doing this is to create a plugin architecture
which provides an interface used for parsing, and which can load
specified assemblies which contain types which implement the interface.

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 15 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

40
by: Sonia | last post by:
Hi, Please look at the following code. This is a simple program for a game of craps - very basic. I have declared the gameStatus as global variable. I was wondering if there is a better way of...
5
by: carl bloc | last post by:
Has any body got any code for this brief that a friend has to do, its for the uk version of the lottery i.e 6 balls and a bouns ball. 1. a control loop is required to determine the operation...
3
by: John C | last post by:
Hi, I am a little uncertain about the concept of passing a reference to a class to another instance of a class. for instance I thought that the following was ok: Network network = Network();...
1
ilikepython
by: ilikepython | last post by:
Hi, I made a pong game with pygame. It works pretty good but I want the ball to bounce realistically. Just like in real pong when it bounces off the right edge it goes to the right and when it...
6
by: djjohnst | last post by:
I am creating a program that will list program times for people who visit our website. Users can login create, edit, delete a program. These dump into a database. The ASP webpage then reads from...
1
by: sake | last post by:
Dear All, I'm working on a 3d breakout game in C++, and I'm having a little trouble with the collision. It will detect that the ball has hit the paddle just fine, but after that, how do I determine...
2
by: SilentCodingOne | last post by:
I have a application where each time you click the add ball button a new randomly colored ball is added to the jpanel. It works fine except that the balls suddenly stop at the same spot. I want them...
0
by: Adrienne Boswell | last post by:
Gazing into my crystal ball I observed doctor@doctor.nl2k.ab.ca (The Doctor) writing in news:ge58o7$9em$1@gallifrey.nk.ca: <snip> Please understand that 1. For users with javascript...
0
by: andreachilam | last post by:
I am doing a project of creating a playing pool and 2 balls bouncing within the pool. I have tried to use "while loop" and "if statement" to set restriction limiting the ball not to bounce out of the...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
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...
0
isladogs
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...
0
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.