🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #11198

Re: MatrixModel or DataSet?

#11198
From: Paul Furbacher
Date: Fri, 25 Jun 1999 00:00
29 lines
1660 bytes
Miki Moore wrote:
> 
> My application will be editing 2d data
> in a variety of ways..GridControl & an interactive chart.
> The data will come from 1) ascii file, 2)gui, 3)database table.
> 
> I have developed a java class for this 2d data..initially
> reading it from a file.
> Should I implement a MatrixModel to be used by the
> gridcontrol or can I somehow make a DataSet from my java object?

I could be wrong on this, but I would suggest going with
a DataSet as the data source for your grid.  Two of the three
possible data sources (ASCII file and database table) fit
very nicely into this scheme.  

Read your ASCII file into a TextDataFile and use it
to load a TableDataSet which you can bind to the 
grid control.

The third source -- creating the 2-d data in a grid control
or from the interactive chart -- can also be routed through
a TableDataSet.  Just programmatically create the dataset,
define the two columns, and add new rows for each pair of
data points.  Save it to either a text file via TextDataFile, 
or to the database.


Paul Furbacher (TeamB)
Technical Details
Message-ID: <3773AA2C.E5FD1504@bilbo.bio.purdue.edu>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <37710291.A258D05D@llnl.gov>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,786421b211ee4daa
X-Google-Attributes: gid111d45,public
From: Paul Furbacher <pf@bilbo.bio.purdue.edu>
Subject: Re: MatrixModel or DataSet?
Date: 1999/06/25
Message-ID: <3773AA2C.E5FD1504@bilbo.bio.purdue.edu>
X-Deja-AN: 493814190
Content-Transfer-Encoding: 7bit
References: <37710291.A258D05D@llnl.gov>
Content-Type: text/plain; charset=us-ascii
Organization: Reverse Alchemy, Inc.
Mime-Version: 1.0
Reply-To: pf@bilbo.bio.purdue.edu
Newsgroups: borland.public.jbuilder.java.swing