Skip to content

Commit

Permalink
Improve Observer Javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
iluwatar committed Oct 3, 2015
1 parent ca6bb7a commit 4d1aae2
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions observer/src/main/java/com/iluwatar/observer/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,17 @@

/**
*
* Observer pattern defines one-to-many relationship between objects. The target
* object sends change notifications to its registered observers.
* The Observer pattern is a software design pattern in which an object, called
* the subject, maintains a list of its dependents, called observers, and notifies
* them automatically of any state changes, usually by calling one of their methods.
* It is mainly used to implement distributed event handling systems. The Observer
* pattern is also a key part in the familiar model–view–controller (MVC) architectural
* pattern. The Observer pattern is implemented in numerous programming libraries and
* systems, including almost all GUI toolkits.
* <p>
* In this example {@link Weather} has a state that can be observed. The {@link Orcs}
* and {@link Hobbits} register as observers and receive notifications when the
* {@link Weather} changes.
*
*/
public class App {
Expand Down

0 comments on commit 4d1aae2

Please sign in to comment.