--- old/src/java.base/share/classes/java/util/Observable.java 2015-08-07 21:15:15.894584163 +0400 +++ new/src/java.base/share/classes/java/util/Observable.java 2015-08-07 21:15:15.686584172 +0400 @@ -31,11 +31,11 @@ * object that the application wants to have observed. *

* An observable object can have one or more observers. An observer - * may be any object that implements interface Observer. After an + * may be any object that implements interface {@code Observer}. After an * observable instance changes, an application calling the - * Observable's notifyObservers method + * {@code Observable}'s {@code notifyObservers} method * causes all of its observers to be notified of the change by a call - * to their update method. + * to their {@code update} method. *

* The order in which notifications will be delivered is unspecified. * The default implementation provided in the Observable class will @@ -45,12 +45,12 @@ * subclass follows this order, as they choose. *

* Note that this notification mechanism has nothing to do with threads - * and is completely separate from the wait and notify - * mechanism of class Object. + * and is completely separate from the {@code wait} and {@code notify} + * mechanism of class {@code Object}. *

* When an observable object is newly created, its set of observers is * empty. Two observers are considered the same if and only if the - * equals method returns true for them. + * {@code equals} method returns true for them. * * @author Chris Warth * @see java.util.Observable#notifyObservers() @@ -88,7 +88,7 @@ /** * Deletes an observer from the set of observers of this object. - * Passing null to this method will have no effect. + * Passing {@code null} to this method will have no effect. * @param o the observer to be deleted. */ public synchronized void deleteObserver(Observer o) { @@ -97,15 +97,15 @@ /** * If this object has changed, as indicated by the - * hasChanged method, then notify all of its observers - * and then call the clearChanged method to + * {@code hasChanged} method, then notify all of its observers + * and then call the {@code clearChanged} method to * indicate that this object has no longer changed. *

- * Each observer has its update method called with two - * arguments: this observable object and null. In other + * Each observer has its {@code update} method called with two + * arguments: this observable object and {@code null}. In other * words, this method is equivalent to: - *

- * notifyObservers(null)
+ *
{@code + * notifyObservers(null)}
* * @see java.util.Observable#clearChanged() * @see java.util.Observable#hasChanged() @@ -117,12 +117,12 @@ /** * If this object has changed, as indicated by the - * hasChanged method, then notify all of its observers - * and then call the clearChanged method to indicate + * {@code hasChanged} method, then notify all of its observers + * and then call the {@code clearChanged} method to indicate * that this object has no longer changed. *

- * Each observer has its update method called with two - * arguments: this observable object and the arg argument. + * Each observer has its {@code update} method called with two + * arguments: this observable object and the {@code arg} argument. * * @param arg any object. * @see java.util.Observable#clearChanged() @@ -167,8 +167,8 @@ } /** - * Marks this Observable object as having been changed; the - * hasChanged method will now return true. + * Marks this {@code Observable} object as having been changed; the + * {@code hasChanged} method will now return {@code true}. */ protected synchronized void setChanged() { changed = true; @@ -177,9 +177,9 @@ /** * Indicates that this object has no longer changed, or that it has * already notified all of its observers of its most recent change, - * so that the hasChanged method will now return false. + * so that the {@code hasChanged} method will now return {@code false}. * This method is called automatically by the - * notifyObservers methods. + * {@code notifyObservers} methods. * * @see java.util.Observable#notifyObservers() * @see java.util.Observable#notifyObservers(java.lang.Object) @@ -191,10 +191,10 @@ /** * Tests if this object has changed. * - * @return true if and only if the setChanged + * @return {@code true} if and only if the {@code setChanged} * method has been called more recently than the - * clearChanged method on this object; - * false otherwise. + * {@code clearChanged} method on this object; + * {@code false} otherwise. * @see java.util.Observable#clearChanged() * @see java.util.Observable#setChanged() */ @@ -203,7 +203,7 @@ } /** - * Returns the number of observers of this Observable object. + * Returns the number of observers of this {@code Observable} object. * * @return the number of observers of this object. */