diff --git a/src/main/java/Model/ExchangeObserver.java b/src/main/java/Model/ExchangeObserver.java new file mode 100644 index 0000000..ad3f6a5 --- /dev/null +++ b/src/main/java/Model/ExchangeObserver.java @@ -0,0 +1,16 @@ +package Model; + +/** + * Observer interface for the Exchange subject. + * Implement this interface to receive notifications whenever the exchange + * state changes (week advances, a trade is committed). + */ +public interface ExchangeObserver { + + /** + * Called by the Exchange after its state has changed. + * + * @param exchange the Exchange that triggered the notification + */ + void onExchangeUpdated(Exchange exchange); +} diff --git a/target/maven-status/maven-compiler-plugin/compile/default-compile/inputFiles.lst b/target/maven-status/maven-compiler-plugin/compile/default-compile/inputFiles.lst index fc20747..f40803d 100644 --- a/target/maven-status/maven-compiler-plugin/compile/default-compile/inputFiles.lst +++ b/target/maven-status/maven-compiler-plugin/compile/default-compile/inputFiles.lst @@ -1,5 +1,6 @@ C:\Users\elisa\Downloads\progdel1\Programmering2_mappe_v26\src\main\java\Controller\StockFileHandler.java C:\Users\elisa\Downloads\progdel1\Programmering2_mappe_v26\src\main\java\Model\Exchange.java +C:\Users\elisa\Downloads\progdel1\Programmering2_mappe_v26\src\main\java\Model\ExchangeObserver.java C:\Users\elisa\Downloads\progdel1\Programmering2_mappe_v26\src\main\java\Model\Player.java C:\Users\elisa\Downloads\progdel1\Programmering2_mappe_v26\src\main\java\Model\Portfolio.java C:\Users\elisa\Downloads\progdel1\Programmering2_mappe_v26\src\main\java\Model\Purchase.java