473,586 Members | 2,639 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Collecting Groups of [3 Objects]

What are some reasonable options for storing collections of [3 related
object variables]. I see that there are plenty of options for storing
collections of individual items (e.g., string or int array) or for
name/value pairs (e.g., hash table). But I have a need to create some sort
of a collection that lets me collect groups of 3 object variables, like
this:

object_1a object_1b object_1c
object_2a object_2b object_2c
object_3a object_3b object_3c
object_4a object_4b object_4c
etc...

Each of these will be for instances of the MVP pattern - so for example
object_1a would be a Model instance, object_1b would be the associated
Presenter and object_1c would be the associated View object (custom Form).

Code then encapsulates this collection would need to be able to search this
collection for a specific Model instance and then be able to return its
associated Presenter or View.

Thanks for your time and consideration.

-Jeff
Feb 17 '06 #1
1 1078
If it were me, I would probably create a struct with an Array in it to
store object_1a, object_1b etc...

then add the structs to another arraylist, so then when you access one
struct, you get the object refs from the arraylist within the struct

Feb 17 '06 #2

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

Similar topics

10
1353
by: Robert Potthast | last post by:
Hi! I am trying to implement a safe garbage collecting system. I use reference counting combined with smart pointers and a garbage collector which keeps a list of all heap-allocated objects. Now I still have the problem to distinguish between stack and heap allocated objects ( see also "Determining if object has been allocated using operator...
3
1556
by: CSharpX | last post by:
Hello, can someone please give me a tip or two on the following problem: I have a system of linked objects which stores properties of on-screen drawn objects. When i select each object on the screen the application slowly over 10-20 seconds grows slower, and the computer runs out of memory so the disk starts spinning and the garbage collector...
1
3833
by: j.eckles | last post by:
I'm trying to determine if there is a way in VBScript, perhaps via ADO or DAO, to access what I'll term MS Access "object groups". What I mean by "object groups" are the folders that you see under the "Groups" pane on the left hand side of the Access 2003 application, just below the "Objects" pane. There's always one default Group called...
17
5057
by: romixnews | last post by:
Hi, I'm facing the problem of analyzing a memory allocation dynamic and object creation dynamics of a very big C++ application with a goal of optimizing its performance and eventually also identifying memory leaks. The application in question is the Mozilla Web Browser. I also have had similar tasks before in the compiler construction area....
0
7839
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8202
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8338
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7959
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...
0
6614
agi2029
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...
0
5390
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...
0
3837
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
2345
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
0
1180
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.