More range annotations for parameters

This commit is contained in:
Tagir Valeev
2019-02-19 15:14:31 +07:00
parent ef665fe44c
commit 6af8a293e3
2 changed files with 43 additions and 13 deletions
+36 -12
View File
@@ -29,6 +29,18 @@
<val name="to" val="java.lang.Byte.MAX_VALUE"/>
</annotation>
</item>
<item name='java.lang.CharSequence java.lang.CharSequence subSequence(int, int) 0'>
<annotation name='org.jetbrains.annotations.Range'>
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name='java.lang.CharSequence java.lang.CharSequence subSequence(int, int) 1'>
<annotation name='org.jetbrains.annotations.Range'>
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name="java.lang.CharSequence java.lang.String toString()">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
@@ -449,18 +461,6 @@
<item name="java.lang.String String(java.lang.StringBuilder) 0">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
<item name="java.lang.String char charAt(int) 0">
<annotation name="org.jetbrains.annotations.Range" >
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name="java.lang.String int codePointAt(int) 0">
<annotation name="org.jetbrains.annotations.Range" >
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name="java.lang.String boolean contains(java.lang.CharSequence) 0">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
@@ -529,6 +529,12 @@
<item name="java.lang.String byte[] getBytes(java.nio.charset.Charset) 0">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
<item name="java.lang.String char charAt(int) 0">
<annotation name="org.jetbrains.annotations.Range" >
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name="java.lang.String char[] toCharArray()">
<annotation name="org.jetbrains.annotations.NotNull" />
<annotation name='org.jetbrains.annotations.Contract'>
@@ -536,6 +542,12 @@
<val name="pure" val="true"/>
</annotation>
</item>
<item name="java.lang.String int codePointAt(int) 0">
<annotation name="org.jetbrains.annotations.Range" >
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name="java.lang.String int compareTo(java.lang.String) 0">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
@@ -570,6 +582,18 @@
<item name="java.lang.String java.lang.CharSequence subSequence(int, int)">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
<item name='java.lang.String java.lang.CharSequence subSequence(int, int) 0'>
<annotation name='org.jetbrains.annotations.Range'>
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name='java.lang.String java.lang.CharSequence subSequence(int, int) 1'>
<annotation name='org.jetbrains.annotations.Range'>
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name="java.lang.String java.lang.String concat(java.lang.String)">
<annotation name="org.jetbrains.annotations.NotNull" />
</item>
@@ -2233,7 +2233,13 @@
<val name="mutates" val="&quot;this&quot;"/>
</annotation>
</item>
<item name='java.util.List E set(int, E)'>
<item name='java.util.List E remove(int) 0'>
<annotation name='org.jetbrains.annotations.Range'>
<val name="from" val="0"/>
<val name="to" val="java.lang.Integer.MAX_VALUE"/>
</annotation>
</item>
<item name='java.util.List E set(int, E)'>
<annotation name='org.jetbrains.annotations.Contract'>
<val name="mutates" val="&quot;this&quot;"/>
</annotation>