Team A 3PB Project Final Progress Report. System Design User Interface Data Manager and 3PB Computer...
-
date post
20-Dec-2015 -
Category
Documents
-
view
213 -
download
0
Transcript of Team A 3PB Project Final Progress Report. System Design User Interface Data Manager and 3PB Computer...
Team A
3PB ProjectFinal Progress Report
System Design User Interface Data Manager and 3PB Computer Data Server and Listener Functionality of Final Prototype
Outline
System Design
System Design User Interface Data Manager and 3PB Computer Data Server and Listener Functionality of Final Prototype
Outline
User Interface
Instantiates other classes (DataManager, Listener, etc.)
Gets user authentication – sends to Listener
Gets stock symbol and time resolution from user
Sends stock symbol to Listener to request data from myGateway
User Interface
Sends time resolution to Data Manager Graphical User Interface displays:
o raw TOS datao statisticso activity indicatoro stock chart
Statistics include real-time trends of stock (short & long sequences)
User Interface
Alarm sounds when trend reversal occurs
Price points at Fibonacci numbers emphasized
User Interface
User Interface
System Design User Interface Data Manager and 3PB Computer Data Server and Listener Functionality of Final Prototype
Outline
Data Manager
Data Flow
Data Manager
3PB Computer
ParserUser Interfacetime resolution, stock
symbol
3PB output (event)
sampled TOS
(consumer-producer)
RawTOSWatcher
PriceChangeWatcherSeqLenCounter
new TOS
3PB output
sequence length stats
raw TOS (event)
price change (event)
Data Manager
Samples incoming TOS in 1 minute interval (using sample-and-hold)
Stores samples
3PB Computer
Runs in a separate thread Implements Producer-Consumer
interface with DataManager Reads TOS sample for next time interval
when available from DataManager. Computes trends and break prices using
3PB method Passes output (as events) to
UserInterface for display Passes output to SeqLenCounter
SeqLenCounter
Receives output from 3PBComputer and keeps track of the length of long and short sequences
Returns sequence length stats when requested
PriceChangeWatcher
Controls the activity indicator Receives new TOS directly from Parser Detects price changes Generates an event (to the
UserInterface) if there is a price change
RawTOSWatcher
Controls the raw TOS display Receives new TOS directly from Parser Redirects each new TOS to
UserInterface as an event
System Design User Interface Data Manager and 3PB Computer Data Server and Listener Functionality of Final Prototype
Outline
Server/Listener
Listener Implemented Two Data
Servers/Listeners Simulated Listener & Server Used in Early
Testing. Real Listener Connected to myGateway.
Used a common API for both Listeners. Used a Factory Pattern so that the
UserInterface can get the proper type.public class listenerFactory{ ... listenerBase getNewListener(DataManager dm, PriceChangeWatcher pcw, RawTOSWatcher rw, BadSymbolWatcher bsw, int type){
if (type == listenerBase.GATEWAY) return new gwListener(dm, pcw, rw, bsw);else return new listener1(dm, pcw, rw, bsw);}
}
Listener API Functions:
Opens and closes myGateway connection Handles username/password Sends Requests for Stock Trade Data Sends Requests for Stock Trade History
Receives myGateway data messages as events and sends them to the Parser.
Parser Packages server data into TOS objects Implements the Adapter Design Pattern
via Java Interfaces Sends data to the DataManager
System Design User Interface Data Manager and 3PB Computer Data Server and Listener Functionality of Final Prototype
Outline
Current Functionality User must enter name/password User can choose a stock symbol User can choose a time resolution Displayed:
Trend Current price Break price Fibonacci points
Current Functionality Activity Indicator – Updates whenever there is
a change in price Statistics can be displayed Adapter implemented which allows Parser to
be modified for other data stream formats Factory implemented to allow for different
data provider API’s
Current Functionality Bar Chart showing trend of data Window displaying raw TOS data Audible signal when trend reversal occurs
Iteration 1 and most of Iteration 2 complete