Skip to content

Commit

Permalink
Show how to specify URDNA2015 algorithm.
Browse files Browse the repository at this point in the history
  • Loading branch information
dlongley committed Jan 5, 2016
1 parent b16d43a commit 1abb809
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.md
Expand Up @@ -94,10 +94,12 @@ $flattened = jsonld_flatten($doc);
$framed = jsonld_frame($doc, $frame); $framed = jsonld_frame($doc, $frame);
// document transformed into a particular tree structure per the given frame // document transformed into a particular tree structure per the given frame


// normalize a document // normalize a document using the RDF Dataset Normalization Algorithm
$normalized = jsonld_normalize($doc, array('format' => 'application/nquads')); // (URDNA2015), see: http://json-ld.github.io/normalization/spec/
$normalized = jsonld_normalize(
$doc, array('algorithm' => 'URDNA2015', 'format' => 'application/nquads'));
// normalized is a string that is a canonical representation of the document // normalized is a string that is a canonical representation of the document
// that can be used for hashing // that can be used for hashing, comparison, etc.


// force HTTPS-only context loading: // force HTTPS-only context loading:
// use built-in secure document loader // use built-in secure document loader
Expand Down

0 comments on commit 1abb809

Please sign in to comment.