Clarify that the Expansion Algorithm processes the optional context argument, or uses the initial context, if none is provided.
authorGregg Kellogg <gregg@kellogg-assoc.com>
Sun, 29 Apr 2012 22:50:17 -0700
changeset 591 e0c5f6ed2804
parent 590 530e1d7fc915
child 592 b922839a70b7
Clarify that the Expansion Algorithm processes the optional context argument, or uses the initial context, if none is provided.
spec/latest/json-ld-api/index.html
--- a/spec/latest/json-ld-api/index.html	Mon Apr 30 01:11:53 2012 -0400
+++ b/spec/latest/json-ld-api/index.html	Sun Apr 29 22:50:17 2012 -0700
@@ -495,6 +495,7 @@
           <dt>object or object[] or URL input</dt>
           <dd>The JSON-LD object or array of JSON-LD objects to perform the expansion upon or an
             <tref>IRI</tref> referencing the JSON-LD document to expand.</dd>
+          <dt>ObjectOrURL? context</dt>
           <dd>An optional external context to use additionally to the context embedded in
             <code>input</code> when expanding the <code>input</code>.</dd>
           <dt>JsonLdCallback callback</dt>
@@ -633,9 +634,6 @@
           <dt>object or object[] or URL input</dt>
           <dd>The JSON-LD object or array of JSON-LD objects to convert to RDF or an <tref>IRI</tref>
             referencing the JSON-LD document to convert to RDF.</dd>
-          <dt>ObjectOrURL? context</dt>
-          <dd>An external context to use additionally to the context embedded in
-            <code>input</code> when expanding the <code>input</code>.</dd>
           <dt>StatementCallback callback</dt>
           <dd>A callback that is called when a <a>Statement</a> is created from processing
             the given <code>input</code>.</dd>
@@ -1371,9 +1369,12 @@
 <section>
 <h3>Expansion Algorithm</h3>
 
-<p>The algorithm takes three input variables: an <tref>active context</tref>, an <tref>active property</tref>,
-  and an <em>element</em> to be expanded. To begin, the <tref>active context</tref> is set to the <tref>initial
-  context</tref>, <tref>active property</tref> is set to <tref>null</tref>, and <em>element</em> is set to the <tref>JSON-LD
+<p>The algorithm takes three input variables: an <tref>active context</tref>,  an <tref>active property</tref>, and an <em>element</em> to be expanded. To 
+  begin, the <tref>active context</tref> is set to the result of performing, <a 
+  href="#context-processing">Context Processing</a> on the passed 
+  <em>context</em>, or to the <tref>initial context</tref> if <em>context</em> 
+  is <tref>null</tref>, <tref>active property</tref> is set to 
+  <tref>null</tref>, and <em>element</em> is set to the <tref>JSON-LD 
   input</tref>.</p>
 <ol class="algorithm">
   <li>If <em>element</em> is an <tref>array</tref>, process each entry in <em>element</em> recursively