LANG-1182: adding clarifying examples to StringUtils#containsAny javadoc

as suggested by Larry West in https://issues.apache.org/jira/browse/LANG-1182
This commit is contained in:
Pascal Schumacher 2015-11-08 22:44:07 +01:00
parent 481137553f
commit 1260e09d6f
1 changed files with 10 additions and 8 deletions

View File

@ -1889,14 +1889,16 @@ public class StringUtils {
* </p>
*
* <pre>
* StringUtils.containsAny(null, *) = false
* StringUtils.containsAny("", *) = false
* StringUtils.containsAny(*, null) = false
* StringUtils.containsAny(*, "") = false
* StringUtils.containsAny("zzabyycdxx", "za") = true
* StringUtils.containsAny("zzabyycdxx", "by") = true
* StringUtils.containsAny("zzabyycdxx", "zy") = true
* StringUtils.containsAny("aba","z") = false
* StringUtils.containsAny(null, *) = false
* StringUtils.containsAny("", *) = false
* StringUtils.containsAny(*, null) = false
* StringUtils.containsAny(*, "") = false
* StringUtils.containsAny("zzabyycdxx", "za") = true
* StringUtils.containsAny("zzabyycdxx", "by") = true
* StringUtils.containsAny("zzabyycdxx", "zy") = true
* StringUtils.containsAny("zzabyycdxx", "\tx") = true
* StringUtils.containsAny("zzabyycdxx", "$.#yF") = true
* StringUtils.containsAny("aba","z") = false
* </pre>
*
* @param cs