Data structure for dynamic two-dimensional array

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

is there a recommendable data structure for dynamic two-dimensional arrays?

The data structure should meet the following requirements:

- The number of rows is unknown on initialization.
- The same applies to the column count.
- The data type of the various columns is not known beforehand.
- It should be easy to bind the data items to data grids.
- Performance should be satisfactory even with thousands of rows.

Any ideas?

Thanks a lot,
P.
 
You might find a DataTable will be easier to work with than, say, an
ArrayList of ArrayList objects, particularly if you want the columns
to have an associated data type.

Performance is relative to your application and environment, but if
the result is something you could cache for later requests, you'd be
much better off.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top