StocksMonitor is an example Swing application, intended for
Java programmers who wish to gain rapid experience with practical aspects
of Swing programming.
Summary of the services provided by StocksMonitor :
- fetch current stock prices periodically from the web (using Yahoo as data
source), and present the data in a table (this is the main service)
- save sets of stocks as a single portfolio
- edit portfolio contents
- filter and sort table rows
- present portfolio totals
- export and import portfolios
- change "theme", which affects the look-and-feel (especially useful for
low vision users)
- display system information (including object heap size) in the About dialog
- refresh logging configuration file
- set various preferences
Interesting aspects of the implementation of StocksMonitor are discussed
at javapractices.com.
Any comments
or suggestions for improvement are always welcome. All alterations
will be credited both in this javadoc, and in the About dialog,
if you include your name. These members of the Java community have contributed
suggestions for the improvement of this application :
This application may be launched using a Java Web Start launch
point. Clients require the following software :
Like Swing itself, most classes in this application are not designed for
multi-threaded environments. Classes which have special status regarding
threads will include the appropriate documentation.
The implementation uses the following coding style :
- classes are final by default ; the only non-final classes
are abstract base classes which are explicitly designed for subclassing
- a naming convention is used to distinguish fields (fBlah) and
arguments (aBlah) from local variables (blah)
- collections are highly preferred over arrays
- private members are placed last, not first (This allows the exported API,
which is much more important than the implementation, to appear at the
top.)
- all objects are non-null unless otherwise specified
- classes are package-private by default, and have their scope increased
to public only if necessary
Known Bugs : please see the application's Help->About dialog for
the list of known bugs.
Version History
- Version 1.7.0 - published September 2013. This version is mostly a port of the application to JDK 1.7.
- Version 1.5.0 - published July 2008. This version is mostly a port of the application to JDK 1.5.
- Version 1.0.1 - published May 2003.