jena-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a...@apache.org
Subject [3/3] jena git commit: Add "AsGiven" functions. Add more javadoc.
Date Wed, 01 Nov 2017 16:56:30 GMT
Add "AsGiven" functions. Add more javadoc.

Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/12a2f800
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/12a2f800
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/12a2f800

Branch: refs/heads/master
Commit: 12a2f800d0c3010d0927fe18b97954c54d9f9028
Parents: ff20db7
Author: Andy Seaborne <andy@apache.org>
Authored: Wed Nov 1 15:57:52 2017 +0000
Committer: Andy Seaborne <andy@apache.org>
Committed: Wed Nov 1 15:57:52 2017 +0000

----------------------------------------------------------------------
 .../apache/jena/riot/system/SyntaxLabels.java   | 21 +++++++++++++++++++-
 1 file changed, 20 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jena/blob/12a2f800/jena-arq/src/main/java/org/apache/jena/riot/system/SyntaxLabels.java
----------------------------------------------------------------------
diff --git a/jena-arq/src/main/java/org/apache/jena/riot/system/SyntaxLabels.java b/jena-arq/src/main/java/org/apache/jena/riot/system/SyntaxLabels.java
index e028b2a..5e900a6 100644
--- a/jena-arq/src/main/java/org/apache/jena/riot/system/SyntaxLabels.java
+++ b/jena-arq/src/main/java/org/apache/jena/riot/system/SyntaxLabels.java
@@ -23,17 +23,36 @@ import org.apache.jena.riot.out.NodeToLabel ;
 
 /** Factory for default policies for syntax labels to and from nodes
  * For label to node (parsing) we use a scalable hashing scheme (MD5 of a seed and the label)
- * 
+ * <p>
  * For node to label (pretty labels output), we use a unique tracking scheme. 
  * Fully scalable writers use different polices and don't have short, pretty bNode labels.
+ * <p>
+ * These should be used pairs:<pre>
+ *     createNodeToLabel , createLabelToNode
+ *     createNodeToLabelRT , createLabelToNodeRT
+ *     createNodeToLabelAsGiven , createLabelToNodeAsGiven
+ * </pre>
+ * "AsGiven" assumes that he label is valid syntax for the usage, no checking.
+ * <br/>
+ * "RT" encodes the label into characters 0-9,A-Z.
+ * 
+ * @see NodeToLabel
+ * @see LabelToNode
  */  
 public class SyntaxLabels
 {
     /** Default setup - scope by document, relabel BNodes ids to short forms */
     static public NodeToLabel createNodeToLabel() { return NodeToLabel.createScopeByDocument()
; }
+    /** Default setup - scope by document, relabel BNodes ids to short forms */
     static public LabelToNode createLabelToNode() { return LabelToNode.createScopeByDocumentHash()
; }
     
     /** Round-trip setup */
     static public NodeToLabel createNodeToLabelRT() { return NodeToLabel.createBNodeByLabelEncoded()
; }
+    /** Round-trip setup */
     static public LabelToNode createLabelToNodeRT() { return LabelToNode.createUseLabelEncoded()
; }
+    
+    /** Raw string label setup */
+    static public NodeToLabel createNodeToLabelAsGiven() { return NodeToLabel.createBNodeByLabelAsGiven();
} 
+    /** Raw string label setup */
+    static public LabelToNode createLabelToNodeAsGiven() { return LabelToNode.createUseLabelAsGiven();
}
 }


Mime
View raw message