[ 
https://issues.apache.org/jira/browse/FLINK-9550?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16513835#comment-16513835
 ] 

ASF GitHub Bot commented on FLINK-9550:
---------------------------------------

Github user dawidwys commented on a diff in the pull request:

    https://github.com/apache/flink/pull/6138#discussion_r195736943
  
    --- Diff: docs/dev/libs/cep.md ---
    @@ -275,36 +275,38 @@ with "foo", and if the sum of the prices of the 
previously accepted events for t
     <div class="codetabs" markdown="1">
     <div data-lang="java" markdown="1">
     {% highlight java %}
    -middle.oneOrMore().where(new IterativeCondition<SubEvent>() {
    -    @Override
    -    public boolean filter(SubEvent value, Context<SubEvent> ctx) throws 
Exception {
    -        if (!value.getName().startsWith("foo")) {
    -            return false;
    -        }
    -
    -        double sum = value.getPrice();
    -        for (Event event : ctx.getEventsForPattern("middle")) {
    -            sum += event.getPrice();
    +middle.oneOrMore()
    +    .subtype(SubEvent.class)
    --- End diff --
    
    Either don't add the `subtype` clause or add it also in the scala example.


> FlinkCEP snippet example has some syntax errors
> -----------------------------------------------
>
>                 Key: FLINK-9550
>                 URL: https://issues.apache.org/jira/browse/FLINK-9550
>             Project: Flink
>          Issue Type: Improvement
>            Reporter: Yazdan Shirvany
>            Assignee: Yazdan Shirvany
>            Priority: Minor
>
> I tried to work with FlinckCEP documentarians and my assumption was the 
> snippet example should work but I got some syntax errors that needed to be 
> fix.  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to