Animated Validation - AWT Java



The left applet demonstrates the input and "animated" validation of precisely defined parameters. The right applet demonstrates the amendment of existing data. Ony four characters are different in the respective source codes.

On-line data input is not easy in Java, particularly in giving feedback to a user - and requires an unexpected amount of effort to implement. This "Applet implements Runnable" and introduces a "thread" invoked by run ( ) to indicate any erroneous input. The code developed here was based on a technique used within a military command and control system, in which it was extremely important to indicate the precise data field that a user had input incorrectly. Such discipline is extremely important to ensure that internal computer processes always work with data within precisely defined limits. Also any resulting system "crash" is highly likely to introduce security risks. Input and validation classes and methods like this are necessary for secure applications within secure Java systems. The values input are output onto a canvas to confirm that only valid input parameters are accepted.

A UML class diagram of the applet is depicted below. These Java applets have been created using Sun Java 2 (i.e. JDK 1.2.2 and SDK 1.3.0). They are operable on:

This input/amendment validation applet has also been converted to Java Swing to improve "look and feel". Although set up for access by Microsoft and Netscape browsers by means of Java Plug-in software and HTML conversion - making it practicable in an intranet environment, it cannot easily be used on the Internet, without necessitating users to download the necessary Java plug-in software. The Swing Java versions are accessible on this site, provided the user's browser incorporates the essential Java Plug-in software.

Animated Validate Test Configurations

Program Version Java Swing Applet Displayed by Browser
Sun Appletviewer MS Explorer 5.0NS Communicator 4.73
InputValidate - Java 2 JDK 1.2.2. No YesYesYes
AmendValidate - Java 2 JDK 1.2.2. No YesYesYes
ValidateS - Java 2 SDK 1.3.0 & Java Plug-in 1.3.0_01. HTML Converter.YesYesYesNo

[UML Diagram]

Implemented by
John R. Oliver
Tel: +44 1494-488-409
E-Mail: john.r.oliver@btinternet.com

Java Class files updated
wef 7 February 2002.


[Return to Home Page] [Button JDA]