
Noah Sloan
CSI 5342
23 August 2006
Project Report: Final Version
Summary
Assignment
Æ PC Java implementation
Accomplishments
Rabbit Board GUI Interface.
PC State Implementation.
Testing.
Protocol Modifications.
Testing
Documentation.
Process
Overview
The following are the broad strokes. For an example of implementing and
running an application using the framework, please refer to the Walkthrough
and Install-Build documents.
1. The key to implementing a protocol using the framework is the
ApplicationContext interface. All interaction between the framework and your
code is done through the application context. If you successfully implement
an application context (and context factory) then you have satisfied the
framework. See the walkthrough document for more details.
2. In order to implement the ApplicationContext interface, you will also need to
implement a MessageDecoder, which takes an array of bytes and converts it
into a Message object.
3. This means you will have to implement a Message class. To help you, there is
the AbstractMessage class. By sub-classing it, you only need to implement
the application specific parts of a Message such as the data you wish to pass
from MC to PC or vice-versa.
4. You will also need a MessageHandler implementation. Often, the message
handler is also implemented in the ApplicationContext. This may not be
desirable is the amount of code required to handle messages becomes very
large. The message handler simply defines the method by which the
framework hands your application incoming messages.
5. Finally, a ContextFactory must be implemented and specified in the
application.properties file. It is responsible for returning a new instance of the
MC/PC application context.
6. To run your application, you can construct an executable jar files as described
in the Install-Build Guide, or simply type java –cp .:swing-layout-
1.0.jar common.Run in the directory where your compiled class files
and the swing layout jar are located.