You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2018/08/20 07:39:11 UTC
[12/19] jena git commit: Comments and internal rename.
Comments and internal rename.
Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/ae74347f
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/ae74347f
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/ae74347f
Branch: refs/heads/master
Commit: ae74347f3607427e88561c854f26903cc880f310
Parents: 99180e5
Author: Andy Seaborne <an...@apache.org>
Authored: Thu Aug 16 16:12:44 2018 +0100
Committer: Andy Seaborne <an...@apache.org>
Committed: Thu Aug 16 16:12:44 2018 +0100
----------------------------------------------------------------------
.../java/org/apache/jena/tdb2/solver/StageMatchTuple.java | 2 +-
.../src/main/java/org/apache/jena/tdb2/store/NodeId.java | 2 +-
.../main/java/org/apache/jena/tdb2/store/NodeIdFactory.java | 9 +++++----
3 files changed, 7 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/jena/blob/ae74347f/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/solver/StageMatchTuple.java
----------------------------------------------------------------------
diff --git a/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/solver/StageMatchTuple.java b/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/solver/StageMatchTuple.java
index 397a4d6..51d7981 100644
--- a/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/solver/StageMatchTuple.java
+++ b/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/solver/StageMatchTuple.java
@@ -85,7 +85,7 @@ public class StageMatchTuple extends RepeatApplyIterator<BindingNodeId>
{
// ---- Convert to NodeIds
NodeId ids[] = new NodeId[patternTuple.len()] ;
- // Variables for this tuple after subsitution
+ // Variables for this tuple after substitution
final Var[] var = new Var[patternTuple.len()] ;
boolean b = prepare(nodeTupleTable.getNodeTable(), patternTuple, input, ids, var) ;
http://git-wip-us.apache.org/repos/asf/jena/blob/ae74347f/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeId.java
----------------------------------------------------------------------
diff --git a/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeId.java b/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeId.java
index be6f6a0..e4932b9 100644
--- a/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeId.java
+++ b/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeId.java
@@ -39,7 +39,7 @@ public class NodeId implements Comparable<NodeId>
public static final NodeId NodeIdUndefined = makeSpecial(0xA6);
private static NodeId makeSpecial(long v) {
- // Careful of an initialzer loop (create(type, v1, v2) looks at specials).
+ // Careful of an initializer loop (create(type, v1, v2) looks at specials).
return NodeIdFactory.createValue(SPECIAL, v);
}
http://git-wip-us.apache.org/repos/asf/jena/blob/ae74347f/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeIdFactory.java
----------------------------------------------------------------------
diff --git a/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeIdFactory.java b/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeIdFactory.java
index 8273474..4c58f7f 100644
--- a/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeIdFactory.java
+++ b/jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/NodeIdFactory.java
@@ -38,6 +38,7 @@ public class NodeIdFactory
// In-memory - always int-long
// XXX Chance for a cache?
+ // See also TupleIndexRecord.
private static NodeId create(NodeIdType type, int v1, long v2) {
if ( isSpecial(type) ) {
@@ -56,12 +57,13 @@ public class NodeIdFactory
return createNew(type, v1, v2);
}
+ /** Make a NodeId of type and value - the value is assumed to be the right format for the type. */
public static NodeId createValue(NodeIdType type, long value) {
- // 64 bit.
return createNew(type, 0, value);
}
private static NodeId createNew(NodeIdType type, int v1, long v2) {
+ // Create general NodeId form.
return NodeId.createRaw(type, v1, v2);
}
@@ -76,7 +78,7 @@ public class NodeIdFactory
// ---- Create from binary.
// 64 bit create
- private static NodeId create(long value2) {
+ private static NodeId create64(long value2) {
if ( !BitsLong.isSet(value2, 63) )
return createPtr(value2);
// Inline.
@@ -94,7 +96,6 @@ public class NodeIdFactory
return NodeId.createRaw(type, v2);
}
- // Long create.
private static NodeId create(int v1, long v2) {
if ( !BitsInt.isSet(v1, 32) )
return createPtrLong(v1, v2);
@@ -130,7 +131,7 @@ public class NodeIdFactory
// 64 bit version
private static NodeId decode(long value2) {
- return NodeIdFactory.create(value2);
+ return NodeIdFactory.create64(value2);
}
/** Not relative - set at position zero */