Skip to content

Commit

Permalink
[docs][hotfix] Fix wrong window definitions in the docs
Browse files Browse the repository at this point in the history
This closes apache#1407
  • Loading branch information
rmetzger authored and fhueske committed Nov 25, 2015
1 parent 804611c commit dcce6de
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions docs/apis/streaming_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -2519,7 +2519,7 @@ implementing the `Evictor` interface.
until end-value are retained (the resulting window size is 1 second).
</p>
{% highlight java %}
triggeredStream.evict(TimeEvictor.of(Time.of(1, TimeUnit.SECONDS)));
triggeredStream.evictor(TimeEvictor.of(Time.of(1, TimeUnit.SECONDS)));
{% endhighlight %}
</td>
</tr>
Expand All @@ -2530,7 +2530,7 @@ triggeredStream.evict(TimeEvictor.of(Time.of(1, TimeUnit.SECONDS)));
Retain 1000 elements from the end of the window backwards, evicting all others.
</p>
{% highlight java %}
triggeredStream.evict(CountEvictor.of(1000));
triggeredStream.evictor(CountEvictor.of(1000));
{% endhighlight %}
</td>
</tr>
Expand All @@ -2543,7 +2543,7 @@ triggeredStream.evict(CountEvictor.of(1000));
DeltaFunction).
</p>
{% highlight java %}
triggeredStream.evict(DeltaEvictor.of(5000, new DeltaFunction<Double>() {
triggeredStream.evictor(DeltaEvictor.of(5000, new DeltaFunction<Double>() {
public double (Double oldValue, Double newValue) {
return newValue - oldValue;
}
Expand Down Expand Up @@ -2572,7 +2572,7 @@ triggeredStream.evict(DeltaEvictor.of(5000, new DeltaFunction<Double>() {
until end-value are retained (the resulting window size is 1 second).
</p>
{% highlight scala %}
triggeredStream.evict(TimeEvictor.of(Time.of(1, TimeUnit.SECONDS)));
triggeredStream.evictor(TimeEvictor.of(Time.of(1, TimeUnit.SECONDS)));
{% endhighlight %}
</td>
</tr>
Expand All @@ -2583,7 +2583,7 @@ triggeredStream.evict(TimeEvictor.of(Time.of(1, TimeUnit.SECONDS)));
Retain 1000 elements from the end of the window backwards, evicting all others.
</p>
{% highlight scala %}
triggeredStream.evict(CountEvictor.of(1000));
triggeredStream.evictor(CountEvictor.of(1000));
{% endhighlight %}
</td>
</tr>
Expand All @@ -2596,7 +2596,7 @@ triggeredStream.evict(CountEvictor.of(1000));
DeltaFunction).
</p>
{% highlight scala %}
windowedStream.evict(DeltaEvictor.of(5000.0, { (old,new) => new - old > 0.01 }))
windowedStream.evictor(DeltaEvictor.of(5000.0, { (old,new) => new - old > 0.01 }))
{% endhighlight %}
</td>
</tr>
Expand Down Expand Up @@ -2632,7 +2632,7 @@ stream.countWindow(1000)
{% highlight java %}
stream.window(GlobalWindows.create())
.trigger(CountTrigger.of(1000)
.evict(CountEvictor.of(1000)))
.evictor(CountEvictor.of(1000)))
{% endhighlight %}
</td>
</tr>
Expand All @@ -2646,8 +2646,8 @@ stream.countWindow(1000, 100)
<td>
{% highlight java %}
stream.window(GlobalWindows.create())
.trigger(CountTrigger.of(1000)
.evict(CountEvictor.of(100)))
.evictor(CountEvictor.of(1000))
.trigger(CountTrigger.of(100))
{% endhighlight %}
</td>
</tr>
Expand Down

0 comments on commit dcce6de

Please sign in to comment.