java left logo
java middle logo
java right logo
 

Home arrow Other API Tips arrow NetBeans arrow How does the declarative XML API for the window system work
 
 
Main Menu
Home
Java Tutorials
Book Reviews
Java SE Tips
Java ME Tips
Java EE Tips
Other API Tips
Java Applications
Java Libraries
Java Games
Java Network
Java Forums
Java Blog




Most Visited Tips
Java SE Tips
Java ME Tips
Java EE Tips
Other API Tips
Java Applications
Java Libraries
Java Games
Book Reviews
Top Rated Tips
Java SE Tips
Java ME Tips
Java EE Tips
Other API Tips
Java Applications
Java Libraries
Java Games
Book Reviews


Statistics
Registered Users: 3911
Java SE Tips: 614
Java ME Tips: 202
Java EE Tips: 183
Other API Tips: 779
Java Applications: 298
Java Libraries: 209
Java Games: 16
Book Reviews:
 
 
 
How does the declarative XML API for the window system work E-mail
User Rating: / 0
PoorBest 

The API is not hard, just a bit baroque.

On startup, the window system needs to know some things to construct the main window, and possibly restore the state it was in before shutdown:

  • The window system needs know what components it will be displaying
  • It needs to know where to display individual components
  • And it has a way to define places where components can be displayed, and needs to know what places have been defined

It would be a disaster for performance if all possible components in the system had to be instantiated/deserialized during startup just to figure out if they actually need to be on screen. The XML definitions for window system components allow a module to completely declaratively provide all the information described above.

There are three main file types to be concerned with - these are put in the System Filesystem by declaring them in your module's layer file:

  • .settings files - representing TopComponents that will be on screen - these go in Windows2/Components
  • .wsmode files - representing docking modes - places where TopComponents can be put - think of them as tabbed containers - these go in Windows2/Modes. For each Mode, you will also create a folder in Windows2/Modes where the .wstcref files that indicate what components are present can go TopComponents can live (essentially tabbed containers)
  • .wstcrf files - a pseudo symbolic-link that contains some configuration data and points to the appropriate .settings file via its ID - put these in the folder you created in Windows2/Modes

See also:

Source: NetBeans FAQ


 Related Tips

 
< Prev   Next >

Page 1 of 0 ( 0 comments )

You can share your information about this topic using the form below!

Please do not post your questions with this form! Thanks.


Name (required)


E-Mail (required)

Your email will not be displayed on the site - only to our administrator
Homepage(optional)



Comment Enable HTML code : Yes No



 
       
         
     
 
 
 
   
 
 
java bottom left
java bottom middle
java bottom right
RSS 0.91 FeedRSS 1.0 FeedRSS 2.0 FeedATOM FeedOPML Feed

Home - About Us - Privacy Policy
Copyright 2005 - 2008 www.java-tips.org
Java is a trademark of Sun Microsystems, Inc.