Github user greghogan commented on a diff in the pull request:
https://github.com/apache/flink/pull/1901#discussion_r62325628
--- Diff: docs/apis/batch/libs/gelly.md ---
@@ -2067,7 +2067,92 @@ configuration.
<tbody>
<tr>
- <td><strong>TranslateGraphIds</strong></td>
+
<td>degree.annotate.directed.<br/><strong>VertexInDegree</strong></td>
+ <td>
+ <p>Annotate vertices of a directed graph with the in-degree
count.</p>
+{% highlight java %}
+DataSet<Vertex<K, LongValue>> inDegree = graph
+ .run(new VertexInDegree()
+ .setIncludeZeroDegreeVertices(true));
+{% endhighlight %}
+ </td>
+ </tr>
+
+ <tr>
+
<td>degree.annotate.directed.<br/><strong>VertexOutDegree</strong></td>
+ <td>
+ <p>Annotate vertices of a directed graph with the out-degree
count.</p>
+{% highlight java %}
+DataSet<Vertex<K, LongValue>> outDegree = graph
+ .run(new VertexOutDegree()
+ .setIncludeZeroDegreeVertices(true));
+{% endhighlight %}
+ </td>
+ </tr>
+
+ <tr>
+
<td>degree.annotate.directed.<br/><strong>VertexDegreePair</strong></td>
+ <td>
+ <p>Annotate vertices of a directed graph with both the out-degree
and in-degree count.</p>
+{% highlight java %}
+DataSet<Vertex<K, Tuple2<LongValue, LongValue>>> pairDegree = graph
+ .run(new VertexDegreePair()
+ .setIncludeZeroDegreeVertices(true));
+{% endhighlight %}
+ </td>
+ </tr>
+
+ <tr>
+
<td>degree.annotate.undirected.<br/><strong>VertexDegree</strong></td>
+ <td>
+ <p>Annotate vertices of an undirected graph with the degree
count.</p>
+{% highlight java %}
+DataSet<Vertex<K, LongValue>> degree = graph
+ .run(new VertexDegree()
+ .setIncludeZeroDegreeVertices(true)
+ .setReduceOnTargetId(true));
+{% endhighlight %}
+ </td>
+ </tr>
+
+ <tr>
+
<td>degree.annotate.undirected.<br/><strong>EdgeSourceDegree</strong></td>
+ <td>
+ <p>Annotate edges of an undirected graph with degree of the source
ID.</p>
--- End diff --
An `Edge` is always directed but a `Graph` may be undirected if it contains
a matching reverse of every edge.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---