Author: spmallette
Date: Fri Oct 14 17:07:31 2016
New Revision: 1764946

URL: http://svn.apache.org/viewvc?rev=1764946&view=rev
Log:
Deploy docs for TinkerPop 3.2.3-SNAPSHOT

Modified:
    tinkerpop/site/docs/3.2.3-SNAPSHOT/recipes/index.html

Modified: tinkerpop/site/docs/3.2.3-SNAPSHOT/recipes/index.html
URL: 
http://svn.apache.org/viewvc/tinkerpop/site/docs/3.2.3-SNAPSHOT/recipes/index.html?rev=1764946&r1=1764945&r2=1764946&view=diff
==============================================================================
--- tinkerpop/site/docs/3.2.3-SNAPSHOT/recipes/index.html (original)
+++ tinkerpop/site/docs/3.2.3-SNAPSHOT/recipes/index.html Fri Oct 14 17:07:31 
2016
@@ -2064,13 +2064,13 @@ shading, is the lowest common ancestor.<
 </div>
 <div class="listingblock">
 <div class="content">
-<pre class="CodeRay"><code class="groovy language-groovy">gremlin&gt; 
g.addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">A</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">a</span><span class="delimiter">'</span></span>).
-           addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">B</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">b</span><span class="delimiter">'</span></span>).
-           addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">C</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">c</span><span class="delimiter">'</span></span>).
-           addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">D</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">d</span><span class="delimiter">'</span></span>).
-           addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">E</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">e</span><span class="delimiter">'</span></span>).
-           addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">F</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">f</span><span class="delimiter">'</span></span>).
-           addV(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, <span 
class="string"><span class="delimiter">'</span><span 
class="content">G</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">g</span><span class="delimiter">'</span></span>).
+<pre class="CodeRay"><code class="groovy language-groovy">gremlin&gt; 
g.addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">A</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">a</span><span class="delimiter">'</span></span>).
+           addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">B</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">b</span><span class="delimiter">'</span></span>).
+           addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">C</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">c</span><span class="delimiter">'</span></span>).
+           addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">D</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">d</span><span class="delimiter">'</span></span>).
+           addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">E</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">e</span><span class="delimiter">'</span></span>).
+           addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">F</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">f</span><span class="delimiter">'</span></span>).
+           addV(id, <span class="string"><span class="delimiter">'</span><span 
class="content">G</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">g</span><span class="delimiter">'</span></span>).
            addE(<span class="string"><span class="delimiter">'</span><span 
class="content">hasParent</span><span 
class="delimiter">'</span></span>).from(<span class="string"><span 
class="delimiter">'</span><span class="content">a</span><span 
class="delimiter">'</span></span>).to(<span class="string"><span 
class="delimiter">'</span><span class="content">b</span><span 
class="delimiter">'</span></span>).
            addE(<span class="string"><span class="delimiter">'</span><span 
class="content">hasParent</span><span 
class="delimiter">'</span></span>).from(<span class="string"><span 
class="delimiter">'</span><span class="content">b</span><span 
class="delimiter">'</span></span>).to(<span class="string"><span 
class="delimiter">'</span><span class="content">c</span><span 
class="delimiter">'</span></span>).
            addE(<span class="string"><span class="delimiter">'</span><span 
class="content">hasParent</span><span 
class="delimiter">'</span></span>).from(<span class="string"><span 
class="delimiter">'</span><span class="content">d</span><span 
class="delimiter">'</span></span>).to(<span class="string"><span 
class="delimiter">'</span><span class="content">c</span><span 
class="delimiter">'</span></span>).
@@ -2084,11 +2084,10 @@ shading, is the lowest common ancestor.<
 </div>
 <div class="listingblock">
 <div class="content">
-<pre class="CodeRay"><code class="groovy language-groovy">gremlin&gt; 
g.V().has(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>,<span 
class="string"><span class="delimiter">'</span><span 
class="content">A</span><span class="delimiter">'</span></span>).
+<pre class="CodeRay"><code class="groovy language-groovy">gremlin&gt; 
g.V(<span class="string"><span class="delimiter">'</span><span 
class="content">A</span><span class="delimiter">'</span></span>).
            repeat(out(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit().as(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>).
-           repeat(__.in(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit(has(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>,<span class="string"><span 
class="delimiter">'</span><span class="content">D</span><span 
class="delimiter">'</span></span>)).
-           select(<span class="string"><span class="delimiter">'</span><span 
class="content">x</span><span class="delimiter">'</span></span>).limit(<span 
class="integer">1</span>).values(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>)
-==&gt;C</code></pre>
+           repeat(__.in(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit(hasId(<span class="string"><span 
class="delimiter">'</span><span class="content">D</span><span 
class="delimiter">'</span></span>)).
+           select(<span class="string"><span class="delimiter">'</span><span 
class="content">x</span><span class="delimiter">'</span></span>).limit(<span 
class="integer">1</span>).values(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>)</code></pre>
 </div>
 </div>
 <div class="paragraph">
@@ -2106,15 +2105,18 @@ vertices.</p>
 ==&gt;A
 ==&gt;B
 ==&gt;D
-gremlin&gt; g.V().has(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>, input.head()).
+gremlin&gt; g.V(input.head()).
            repeat(out(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit().as(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>). <span class="comment">//</span><b>(1)</b>
-           V().has(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, 
within(input.tail())). <span class="comment">//</span><b>(2)</b>
+           V().has(id, within(input.tail())). <span 
class="comment">//</span><b>(2)</b>
            repeat(out(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit(where(eq(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>))). <span class="comment">//</span><b>(3)</b>
-           group().by(select(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>)).by(path().count(local).fold()). <span 
class="comment">//</span><b>(4)</b>
+           group().
+             by(select(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>)).
+             by(path().count(local).fold()). <span 
class="comment">//</span><b>(4)</b>
            
unfold().filter(select(values).count(local).is(input.tail().size())). <span 
class="comment">//</span><b>(5)</b>
-           order().by(select(values).unfold().sum()). <span 
class="comment">//</span><b>(6)</b>
-           select(keys).limit(<span class="integer">1</span>).valueMap(<span 
class="predefined-constant">true</span>) <span 
class="comment">//</span><b>(7)</b>
-==&gt;[<span class="key">label</span>:vertex,<span 
class="key">name</span>:[C],<span class="key">id</span>:<span 
class="integer">4</span>]</code></pre>
+           order().by(select(values).
+           unfold().sum()). <span class="comment">//</span><b>(6)</b>
+           select(keys).limit(<span class="integer">1</span>) <span 
class="comment">//</span><b>(7)</b>
+==&gt;v[C]</code></pre>
 </div>
 </div>
 <div class="colist arabic">
@@ -2149,16 +2151,28 @@ were given to the mid-traversal <code>V(
 </div>
 <div class="listingblock">
 <div class="content">
-<pre class="CodeRay"><code class="groovy language-groovy">gremlin&gt; 
g.withComputer().V().has(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>, within(input)).aggregate(<span 
class="string"><span class="delimiter">'</span><span 
class="content">input</span><span class="delimiter">'</span></span>).
-           has(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>, 
input.head()).repeat(out(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit().as(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>).
-           select(<span class="string"><span class="delimiter">'</span><span 
class="content">input</span><span 
class="delimiter">'</span></span>).unfold().has(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>, within(input.tail())).
+<pre class="CodeRay"><code class="groovy language-groovy">gremlin&gt; 
g.withComputer().
+           V().has(id, within(input)).
+           aggregate(<span class="string"><span 
class="delimiter">'</span><span class="content">input</span><span 
class="delimiter">'</span></span>).hasId(input.head()). <span 
class="comment">//</span><b>(1)</b>
+           repeat(out(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit().as(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>).
+           select(<span class="string"><span class="delimiter">'</span><span 
class="content">input</span><span 
class="delimiter">'</span></span>).unfold().has(id, within(input.tail())).
            repeat(out(<span class="string"><span 
class="delimiter">'</span><span class="content">hasParent</span><span 
class="delimiter">'</span></span>)).emit(where(eq(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>))).
-           group().by(select(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>)).by(path().count(local).fold()).
+           group().
+             by(select(<span class="string"><span 
class="delimiter">'</span><span class="content">x</span><span 
class="delimiter">'</span></span>)).
+             by(path().count(local).fold()).
            
unfold().filter(select(values).count(local).is(input.tail().size())).
-           order().by(select(values).unfold().sum()).
-           select(keys).limit(<span class="integer">1</span>).valueMap(<span 
class="predefined-constant">true</span>)
-==&gt;[<span class="key">label</span>:,<span class="key">id</span>:<span 
class="integer">4</span>]</code></pre>
+           order().
+             by(select(values).unfold().sum()).
+           select(keys).limit(<span class="integer">1</span>)
+==&gt;v[C]</code></pre>
+</div>
 </div>
+<div class="colist arabic">
+<ol>
+<li>
+<p>The main difference for OLAP is the use of <code>aggregate()</code> over 
the mid-traversal`V()`.</p>
+</li>
+</ol>
 </div>
 </div>
 <div class="sect2">
@@ -2294,7 +2308,8 @@ gremlin&gt; g.V().has(<span class="strin
 gremlin&gt; g.V().has(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>,<span class="string"><span 
class="delimiter">'</span><span class="content">2016</span><span 
class="delimiter">'</span></span>).out(<span class="string"><span 
class="delimiter">'</span><span class="content">may</span><span 
class="delimiter">'</span></span>).out(<span class="string"><span 
class="delimiter">'</span><span class="content">day31</span><span 
class="delimiter">'</span></span>).as(<span class="string"><span 
class="delimiter">'</span><span class="content">start</span><span 
class="delimiter">'</span></span>).
            V().has(<span class="string"><span class="delimiter">'</span><span 
class="content">name</span><span class="delimiter">'</span></span>,<span 
class="string"><span class="delimiter">'</span><span 
class="content">2016</span><span class="delimiter">'</span></span>).out(<span 
class="string"><span class="delimiter">'</span><span 
class="content">june</span><span class="delimiter">'</span></span>).out(<span 
class="string"><span class="delimiter">'</span><span 
class="content">day01</span><span class="delimiter">'</span></span>).as(<span 
class="string"><span class="delimiter">'</span><span 
class="content">end</span><span class="delimiter">'</span></span>).
            emit().repeat(__.in(<span class="string"><span 
class="delimiter">'</span><span class="content">next</span><span 
class="delimiter">'</span></span>)).until(where(eq(<span class="string"><span 
class="delimiter">'</span><span class="content">start</span><span 
class="delimiter">'</span></span>))).
-           out(<span class="string"><span class="delimiter">'</span><span 
class="content">has</span><span 
class="delimiter">'</span></span>).order().by(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>).values(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>) <span class="comment">//</span><b>(4)</b>
+           out(<span class="string"><span class="delimiter">'</span><span 
class="content">has</span><span class="delimiter">'</span></span>).
+           order().by(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>).values(<span class="string"><span 
class="delimiter">'</span><span class="content">name</span><span 
class="delimiter">'</span></span>) <span class="comment">//</span><b>(4)</b>
 ==&gt;C
 ==&gt;D
 ==&gt;E</code></pre>
@@ -2633,7 +2648,7 @@ submissions!</p>
 </div>
 <div id="footer">
 <div id="footer-text">
-Last updated 2016-10-14 11:59:00 -04:00
+Last updated 2016-10-14 13:05:16 -04:00
 </div>
 </div>
 </body>


Reply via email to