• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

Data File Schema

 
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am working on UrlyBird(1.2.3) and I have a question about data file schema. I read few posts saying that it is ok to hard code the header information.
I was able to read the header information from my file using the RandomAccess file object.
I am not sure how can I make schema reading dyanmic so when i create JTable later, I can read them dynamically. Is there a way?
 
Ranch Hand
Posts: 759
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Paul, welcome to JavaRanch.

To use JTable dynamically, you have to implements MVC pattern. It is covered on book titled "SCJD Exam with J2SE" by Apress.

You have to extend AbstractTableModel and implement all the abstract methods specifics to your needs.


Hope that will help you

Jeffry Kristianto Yanuar (Java Instructor)
SCJP 5.0, SCJA, SCJD (UrlyBird 1.3.2)
 
Payal Shah
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for your reply.

one more question, the schema section of the exam, I am using hardcoded static final fields for size ( private static final int location = 64 .

Is there a way to make that dynamic..?
 
It is an experimental device that will make my mind that most powerful force on earth! More powerful than this tiny ad!
ScroogeXHTML 9.0 - RTF to HTML5 and XHTML converter
https://coderanch.com/t/731949/ScroogeXHTML-RTF-HTML-XHTML-converter
    Bookmark Topic Watch Topic
  • New Topic