]> git.gag.com Git - debian/openrocket/blobdiff - src/net/sf/openrocket/util/Monitorable.java
SafetyMutex and rocket optimization updates
[debian/openrocket] / src / net / sf / openrocket / util / Monitorable.java
index eb0b6c472a00568d0b648b30a858050c530fc15b..bff7480e80990c537966902e8643992e263b71c5 100644 (file)
@@ -1,7 +1,15 @@
 package net.sf.openrocket.util;
 
+/**
+ * Interface describing objects whose state changes can be monitored based on
+ * a modification ID number.  If a specific object has the same modification ID
+ * at two different points in time, the object state is guaranteed to be the same.
+ * This does not necessarily hold between two different instances of an object type.
+ * 
+ * @author Sampo Niskanen <sampo.niskanen@iki.fi>
+ */
 public interface Monitorable {
-
+       
        /**
         * Return a modification ID unique to the current state of this object and contained objects.
         * The general contract is that if a specific object has the same modification ID at two moments
@@ -17,7 +25,7 @@ public interface Monitorable {
         * increasing a modification counter or retrieving a new unique ID every time a value is set.
         * <p>
         * Objects that contain other objects with a mutable state may for example return the sum of the
-        * object's own modification ID, a modification ID counter (initially zero) and the modification ID
+        * object's own modification ID, a modification ID counter (initially zero) and the modification IDs
         * of the contained objects.  When a mutable object is set, the modification counter is increased by
         * the modification ID of the current object in order to preserve monotonicity.
         * <p>