🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: JTable with variable length

#11428
From: Max Polk
Date: Fri, 28 May 1999 00:00
16 lines
1277 bytes
In article <374D3B54.C0BC5DB7@mgm-edv.de>, Stephan.Grimm@mgm-edv.de 
says...
> To a JTable I want to associate a TableModel that gets the Data from a
> XML-file.
> The problem is, that the number of rows is unknown. Only a small part of
> the data in the file shall be buffered in Memory. More data (in both
> directions) shall be retrieved from the file on demand, depending on the
> table's scrollbar.
> I don't know how to implement the methods that need fixed coordinates
> and those like getRowCount();

Return the rows you currently have in getRowCount.  When you get to the 
last row, make it a "magic" row.  As soon as the data is requested from 
the last row (indicating that they scrolled to the very bottom), make the 
table update itself with more data.  Then fire a table update and you are 
all set!
Technical Details
Message-ID: <MPG.11b92433eb4237db9896e9@forums.borland.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <374D3B54.C0BC5DB7@mgm-edv.de>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,d3946681fec03433
X-Google-Attributes: gid111d45,public
From: none@none.invalid (Max Polk)
Subject: Re: JTable with variable length
Date: 1999/05/28
Message-ID: <MPG.11b92433eb4237db9896e9@forums.borland.com>
X-Deja-AN: 483341846
References: <374D3B54.C0BC5DB7@mgm-edv.de>
Organization: Another Netscape Collabra Server User
Newsgroups: borland.public.jbuilder.java.swing