Behavioral Patterns  «Prev  Next»

Time Observer Interface - Exercise

The Observer Pattern

Objective: Write a TimeObserver interface.
Define an interface (Java) or abstract class (C++) called TimeObserver that has the following structure:
TimeObserver class with a timeChanged method
TimeObserver class with a timeChanged method

In the text area below, type your answer and click the Submit button.