Class SlotMatchers
java.lang.Object
org.spongepowered.api.item.inventory.slot.SlotMatchers
A collection of
KeyValueMatcher
s that
can be used to query for Slot
s.-
Method Summary
Modifier and TypeMethodDescriptionstatic KeyValueMatcher<Integer>
index
(int index) Creates aKeyValueMatcher
with the default operatorKeyValueMatcher.Operator.EQUAL
to match against slot indexes.static KeyValueMatcher<Integer>
index
(int index, KeyValueMatcher.Operator operator) Creates aKeyValueMatcher
to match against slot indexes.static KeyValueMatcher<Vector2i>
position
(int x, int y) Creates aKeyValueMatcher
with the default operatorKeyValueMatcher.Operator.EQUAL
to match against a slot position.static KeyValueMatcher<Vector2i>
position
(int x, int y, KeyValueMatcher.Operator operator) Creates aKeyValueMatcher
to match against a slot position.static KeyValueMatcher<Vector2i>
Creates aKeyValueMatcher
with the default operatorKeyValueMatcher.Operator.EQUAL
to match against a slot position.static KeyValueMatcher<Vector2i>
position
(Vector2i pos, KeyValueMatcher.Operator operator) Creates aKeyValueMatcher
to match against a slot position.
-
Method Details
-
index
Creates aKeyValueMatcher
with the default operatorKeyValueMatcher.Operator.EQUAL
to match against slot indexes.- Parameters:
index
- The slot index- Returns:
- The property query
-
index
Creates aKeyValueMatcher
to match against slot indexes.- Parameters:
index
- The slot index valueoperator
- The operator- Returns:
- The property query
-
position
Creates aKeyValueMatcher
with the default operatorKeyValueMatcher.Operator.EQUAL
to match against a slot position.- Parameters:
pos
- The slot position- Returns:
- The property query
-
position
Creates aKeyValueMatcher
with the default operatorKeyValueMatcher.Operator.EQUAL
to match against a slot position.- Parameters:
x
- The x coordinatey
- The y coordinate- Returns:
- The property query
-
position
Creates aKeyValueMatcher
to match against a slot position.- Parameters:
pos
- The slot positionoperator
- The operator- Returns:
- The property query
-
position
Creates aKeyValueMatcher
to match against a slot position.- Parameters:
x
- The x coordinatey
- The y coordinateoperator
- The operator- Returns:
- The property query
-