[ 
https://issues.apache.org/jira/browse/UIMA-6388?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Richard Eckart de Castilho updated UIMA-6388:
---------------------------------------------
    Fix Version/s: 3.3.0SDK
                       (was: 3.2.1SDK)

> CAS.select(null) returns all annotations
> ----------------------------------------
>
>                 Key: UIMA-6388
>                 URL: https://issues.apache.org/jira/browse/UIMA-6388
>             Project: UIMA
>          Issue Type: Bug
>          Components: Core Java Framework
>    Affects Versions: 3.2.0SDK
>            Reporter: Richard Eckart de Castilho
>            Assignee: Richard Eckart de Castilho
>            Priority: Major
>             Fix For: 3.3.0SDK
>
>
> When calling {{CAS.select()}} with a {{Type null}} argument, then all 
> annotations are returned. I believe when select is called with a {{null}} 
> argument, an {{IllegalArgumentException}} should be thrown instead. It is 
> very surprising if you write code like this:
> {code}
> var type = cas.getTypeSystem("non.existing.Type");
> cas.select(type).asList() <= returns a list of all feature structures in the 
> CAS, e.g. the DocumentAnnotation etc.
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to