473,386 Members | 1,752 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,386 software developers and data experts.

Is tree structure the right concept?

Hi,

in my application I want to handle and store data in a hierarchic data
structure.
For example: persons who manage houses; houses have various numbers of
floors; floors have various numbers of rooms etc.

My first concept is to use a tree structure, to ideally save the whole
tree to file and load from file.

What do you suggest?
Would the TreeView-Component be appropriate?

Best wiches
googleo
Jul 22 '05 #1
1 1967

"googleo" <le********@netcologne.de> wrote in message
news:b5**************************@posting.google.c om...
Hi,

in my application I want to handle and store data in a hierarchic data
structure.
For example: persons who manage houses; houses have various numbers of
floors; floors have various numbers of rooms etc.

My first concept is to use a tree structure, to ideally save the whole
tree to file and load from file.
Well your data is a hierarchy, so a tree structure would seem reasonable.
But when computer people talk about trees they normally have something else
in mind. Namely a tree which can extend to infinite levels and where all the
data is the same type. For instance in a family tree, everyone is a person,
and you can have as many ancestors as you want. You data structure is
different in that you have a fixed number of levels and different data types
at each level. But if you want to call it a tree then that is fine by me.

What do you suggest?
Would the TreeView-Component be appropriate?


I have no idea what a TreeView-Component is, it has nothing to do with C++
(is it some sort of Windows thing, if so ask in a Windows programming
group). Nor has the rest of your question really but if you want to know how
to implement your chosen data structure that would be on topic in this
group.

john
Jul 22 '05 #2

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

Similar topics

3
by: Steve | last post by:
I'm looking for some advice on how to design a set of tables to represent a tree style table structure in MySQL. I have a table that stores a set of items, with each item having a type. The type...
7
by: Matt Kruse | last post by:
I've just put up a new script on my site: http://www.mattkruse.com/javascript/mktree/ This script combines javascript and some tricky CSS to create the easiest-to-implement...
4
by: Henry Jordon | last post by:
I have everything pretty much done but I need to fix something in my coding. I want to be able to enter strings such as "love", "hate", "the", etc. but am unable to figure how to do this. I have...
19
by: Christian Fowler | last post by:
I have a VERY LARGE pile of geographic data that I am importing into a database (db of choice is postgres, though may hop to oracle if necessary). The data is strictly hierarchical - each node has...
22
by: delraydog | last post by:
It's quite simple to walk to the DOM tree going forward however I can't figure out a nice clean way to walk the DOM tree in reverse. Checking previousSibling is not sufficient as the...
1
by: hn.ft.pris | last post by:
I have the following code: Tree.h defines a simple binary search tree node structure ########## FILE Tree.h ################ #ifndef TREE_H #define TREE_H //using namespace std; template...
2
by: aemado | last post by:
I am writing a program that will evaluate expressions using binary trees. Most of the code has been provided, I just have to write the code for the class functions as listed in the header file....
8
by: =?ISO-8859-1?Q?m=E9choui?= | last post by:
Problem: - You have tree structure (XML-like) that you don't want to create 100% in memory, because it just takes too long (for instance, you need a http request to request the information from...
6
by: Bart Kastermans | last post by:
I am playing with some trees. In one of the procedures I wrote for this I am trying to change self to a different tree. A tree here has four members (val/type/left/right). I found that self = SS...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
marktang
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,...
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,...

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.