jena-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a...@apache.org
Subject svn commit: r1127974 - /incubator/jena/Experimental/TxTDB/trunk/src-dev/tx/base/BlockRef.java
Date Thu, 26 May 2011 15:56:22 GMT
Author: andy
Date: Thu May 26 15:56:21 2011
New Revision: 1127974

URL: http://svn.apache.org/viewvc?rev=1127974&view=rev
Log: (empty)

Modified:
    incubator/jena/Experimental/TxTDB/trunk/src-dev/tx/base/BlockRef.java

Modified: incubator/jena/Experimental/TxTDB/trunk/src-dev/tx/base/BlockRef.java
URL: http://svn.apache.org/viewvc/incubator/jena/Experimental/TxTDB/trunk/src-dev/tx/base/BlockRef.java?rev=1127974&r1=1127973&r2=1127974&view=diff
==============================================================================
--- incubator/jena/Experimental/TxTDB/trunk/src-dev/tx/base/BlockRef.java (original)
+++ incubator/jena/Experimental/TxTDB/trunk/src-dev/tx/base/BlockRef.java Thu May 26 15:56:21
2011
@@ -10,17 +10,17 @@ final
 public class BlockRef
 {
     private final FileRef file ;
-    private final int blockId ;
+    private final long blockId ;
     
-    static public BlockRef create(FileRef file, int blockId)    { return new BlockRef(file,
blockId) ; }
+    static public BlockRef create(FileRef file, long blockId)    { return new BlockRef(file,
blockId) ; }
     //static public BlockRef create(String file, Integer blockId)     { return new BlockRef(file,
blockId) ; }
 
-    private BlockRef(String file, int blockId)
+    private BlockRef(String file, long blockId)
     {
         this(FileRef.create(file), blockId) ;
     }
     
-    private BlockRef(FileRef file, int blockId)
+    private BlockRef(FileRef file, long blockId)
     {
         this.file = file ;
         this.blockId = blockId ;
@@ -30,14 +30,14 @@ public class BlockRef
 
     public int getFileId()          { return getFile().getId() ; }
 
-    public int getBlockId()         { return blockId ; }
+    public long getBlockId()         { return blockId ; }
 
     @Override
     public int hashCode()
     {
         final int prime = 31 ;
         int result = 1 ;
-        result = prime * result + blockId ;
+        result = prime * result + (int)(blockId ^ (blockId >>> 32)) ;
         result = prime * result + ((file == null) ? 0 : file.hashCode()) ;
         return result ;
     }



Mime
View raw message