Record Class WalkResult.ArgumentExpected<C extends CommandContext<C>>
java.lang.Object
java.lang.Record
site.lab0x13.scrow.commands.parser.WalkResult.ArgumentExpected<C>
- All Implemented Interfaces:
WalkResult<C>
- Enclosing interface:
WalkResult<C extends CommandContext<C>>
public static record WalkResult.ArgumentExpected<C extends CommandContext<C>>(C extends CommandContext<C> ctx, Literal<C extends CommandContext<C>> lastLiteral, boolean isValidUsage, Argument<C extends CommandContext<C>, ?> arg)
extends Record
implements WalkResult<C>
-
Nested Class Summary
Nested classes/interfaces inherited from interface WalkResult
WalkResult.ArgumentExpected<C>, WalkResult.ArgumentIllegal<C>, WalkResult.Complete<C>, WalkResult.LiteralExpected<C>, WalkResult.LiteralUnknown<C> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionarg()Returns the value of theargrecord component.ctx()Returns the value of thectxrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theisValidUsagerecord component.Returns the value of thelastLiteralrecord component.message()final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ArgumentExpected
Creates an instance of aArgumentExpectedrecord class.- Parameters:
ctx- the value for thectxrecord componentlastLiteral- the value for thelastLiteralrecord componentisValidUsage- the value for theisValidUsagerecord componentarg- the value for theargrecord component
-
-
Method Details
-
message
- Specified by:
messagein interfaceWalkResult<C extends CommandContext<C>>
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
ctx
Returns the value of thectxrecord component.- Specified by:
ctxin interfaceWalkResult<C extends CommandContext<C>>- Returns:
- the value of the
ctxrecord component
-
lastLiteral
Returns the value of thelastLiteralrecord component.- Specified by:
lastLiteralin interfaceWalkResult<C extends CommandContext<C>>- Returns:
- the value of the
lastLiteralrecord component
-
isValidUsage
public boolean isValidUsage()Returns the value of theisValidUsagerecord component.- Specified by:
isValidUsagein interfaceWalkResult<C extends CommandContext<C>>- Returns:
- the value of the
isValidUsagerecord component
-
arg
-