You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by jk...@apache.org on 2017/04/08 00:34:51 UTC
[3/4] beam git commit: Clarifies doc of ProcessElement re:
HasDefaultTracker
Clarifies doc of ProcessElement re: HasDefaultTracker
Project: http://git-wip-us.apache.org/repos/asf/beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/beam/commit/19f407c9
Tree: http://git-wip-us.apache.org/repos/asf/beam/tree/19f407c9
Diff: http://git-wip-us.apache.org/repos/asf/beam/diff/19f407c9
Branch: refs/heads/master
Commit: 19f407c9497c911ca3cb61d989aa5a78c84896cf
Parents: 4a694ce
Author: Eugene Kirpichov <ki...@google.com>
Authored: Fri Apr 7 17:00:39 2017 -0700
Committer: Eugene Kirpichov <ki...@google.com>
Committed: Fri Apr 7 17:06:13 2017 -0700
----------------------------------------------------------------------
.../src/main/java/org/apache/beam/sdk/transforms/DoFn.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/beam/blob/19f407c9/sdks/java/core/src/main/java/org/apache/beam/sdk/transforms/DoFn.java
----------------------------------------------------------------------
diff --git a/sdks/java/core/src/main/java/org/apache/beam/sdk/transforms/DoFn.java b/sdks/java/core/src/main/java/org/apache/beam/sdk/transforms/DoFn.java
index de33612..5139290 100644
--- a/sdks/java/core/src/main/java/org/apache/beam/sdk/transforms/DoFn.java
+++ b/sdks/java/core/src/main/java/org/apache/beam/sdk/transforms/DoFn.java
@@ -40,6 +40,7 @@ import org.apache.beam.sdk.options.PipelineOptions;
import org.apache.beam.sdk.transforms.Combine.CombineFn;
import org.apache.beam.sdk.transforms.display.DisplayData;
import org.apache.beam.sdk.transforms.display.HasDisplayData;
+import org.apache.beam.sdk.transforms.splittabledofn.HasDefaultTracker;
import org.apache.beam.sdk.transforms.splittabledofn.RestrictionTracker;
import org.apache.beam.sdk.transforms.windowing.BoundedWindow;
import org.apache.beam.sdk.transforms.windowing.PaneInfo;
@@ -548,10 +549,11 @@ public abstract class DoFn<InputT, OutputT> implements Serializable, HasDisplayD
* <ul>
* <li>It <i>must</i> define a {@link GetInitialRestriction} method.
* <li>It <i>may</i> define a {@link SplitRestriction} method.
- * <li>It <i>must</i> define a {@link NewTracker} method returning the same type as the type of
+ * <li>It <i>may</i> define a {@link NewTracker} method returning the same type as the type of
* the {@link RestrictionTracker} argument of {@link ProcessElement}, which in turn must be a
* subtype of {@code RestrictionTracker<R>} where {@code R} is the restriction type returned
- * by {@link GetInitialRestriction}.
+ * by {@link GetInitialRestriction}. This method is optional in case the restriction type
+ * returned by {@link GetInitialRestriction} implements {@link HasDefaultTracker}.
* <li>It <i>may</i> define a {@link GetRestrictionCoder} method.
* <li>The type of restrictions used by all of these methods must be the same.
* <li>Its {@link ProcessElement} method <i>may</i> return a {@link ProcessContinuation} to