Skip to content

Commit 6424e10

Browse files
committed
Add a list of quantifiers to the README
1 parent 3bb9e74 commit 6424e10

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,4 +119,17 @@ fun noMoreThanOneGsonInstance() = detector(
119119
file { callExpression(moreThan(1)) { suchThat { it.isGsonConstructor } } }
120120
)
121121
)
122+
```
123+
124+
The list of available quantifiers is:
125+
126+
```kotlin
127+
val any // The default quantifier, if a rule matches any number of times then it's reported
128+
val all // It should appear in every single appearance of the node
129+
fun times(times: Int) // Match the rule an exact number of "times"
130+
fun atMost(times: Int) // matches <= "times"
131+
fun atLeast(times: Int) // matches >= "times"
132+
fun lessThan(times: Int) // matches < "times"
133+
fun moreThan(times: Int) // matches > "times"
134+
val none // No matches
122135
```

0 commit comments

Comments
 (0)