⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme.txt

📁 This a JavaBean application, which contains 4 beans. In this package, there are 4 files: cexchange
💻 TXT
字号:
This package includes four Beans as required, two Customizers and four custom Events with its corresponding listeners. 

Beans: CurrencyExchange, QuoteProducer, Summarizer and Displayer.

Customizers: QuoteProducerCustomizer and SummaryChoiceCustomizer.

Custom Events: CurrencyEvent, QuoteEvent, ThresholdEvent and SummaryEvent. 

Custom Event Listeners: CurrencyEventListener, QuoteEventListener, ThresholdEventListener and SummaryEventListener.


Working Principle:

1.CurrencyExchange reads the currency data file into a vector(currencylist) regularly, which is controled by a timer; then, fires a CurrencyEvent that contains the vector(currencylist);

2.QuoteProducer receives the CurrencyEvent from CurrencyExchange and deal with the currency data; the QuoteProducerCustomizer helps users to choose their interested currency and set its threshold in QuoteProducer bean; once currency price reaching the threshold, this bean fires ThresholdEvent; aslo, it fires QuoteEvent once for each CurrencyEvent it received;

3.Summarizer receives CurrencyEvent from CurrencyExchange and QuoteEvent from QuoteProducer; then it calculate these data as user required (default type is average), such as for maximum, minimum and average, the SummaryChoiceCustomizer gives users a interface to do so; after that, it sends out a SummaryEvent to Displayer;

4.Displayer receives two customized events: QuoteEvent from QuoteProducer for displaying particular currency that user is interested, and SummaryEvent from Summarizer for showing the calculate result that has been done in last step.


User Instruction:
please read the screenshot for details.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -