Interface ArgumentResolver<T>
- Type Parameters:
T- the resolved type
- All Known Subinterfaces:
AngleResolver, BlockPositionResolver, ColumnPositionResolver, EntitiesResolver, EntityResolver, PlayerProfilesResolver, PlayerResolver, PlayersResolver, PositionResolver
public sealed interface ArgumentResolver<T>
permits EntityResolver, EntitiesResolver, PlayerResolver, PlayersResolver, PlayerProfilesResolver, BlockPositionResolver, ColumnPositionResolver, PositionResolver, AngleResolver
An argument resolved against the source running the command, not the one it was parsed with.
/execute parses once, then changes the executor and location. Anything depending on them (selectors, relative or local coordinates) is resolved here.
Each subtype reads its argument with a static method named after its factory in
Arguments, like PlayersResolver.players(CommandContext, String).
- Since:
- 0.1.0
-
Method Summary
Modifier and TypeMethodDescriptionresolve(CommandSource source) Returns this argument resolved forsource.
-
Method Details
-
resolve
Returns this argument resolved forsource.- Parameters:
source- the source running the command- Returns:
- this argument resolved for
source - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- if it can't be resolved forsource- Since:
- 0.1.0
-