[jboss-cvs] JBossCache/src/org/jboss/cache ...

Manik Surtani manik at jboss.org
Fri Jul 27 11:39:28 EDT 2007


  User: msurtani
  Date: 07/07/27 11:39:28

  Modified:    src/org/jboss/cache   Node.java UnversionedNode.java
  Log:
  Added isValid()
  
  Revision  Changes    Path
  1.66      +8 -0      JBossCache/src/org/jboss/cache/Node.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Node.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Node.java,v
  retrieving revision 1.65
  retrieving revision 1.66
  diff -u -b -r1.65 -r1.66
  --- Node.java	9 Jul 2007 13:14:26 -0000	1.65
  +++ Node.java	27 Jul 2007 15:39:28 -0000	1.66
  @@ -269,4 +269,12 @@
       */
      boolean hasChild(Object o);
   
  +   /**
  +    * Tests if a node reference is still valid.  A node reference may become invalid if it has been evicted, for example,
  +    * in which case it should be looked up again from the cache.
  +    *
  +    * @return true if the node is valid.
  +    */
  +   boolean isValid();
  +
   }
  
  
  
  1.40      +7 -1      JBossCache/src/org/jboss/cache/UnversionedNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UnversionedNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/UnversionedNode.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -b -r1.39 -r1.40
  --- UnversionedNode.java	20 Jul 2007 09:52:09 -0000	1.39
  +++ UnversionedNode.java	27 Jul 2007 15:39:28 -0000	1.40
  @@ -732,4 +732,10 @@
      {
         this.dataLoaded = dataLoaded;
      }
  +
  +   public boolean isValid()
  +   {
  +      // TODO; implement this property, to detect if it has been evicted, removed by another thread, etc.  Method added for now as a dummy so it exists in the API
  +      return true;
  +   }
   }
  
  
  



More information about the jboss-cvs-commits mailing list