Record Class DefaultByteInput.DefaultByteInputMark
java.lang.Object
java.lang.Record
cool.scx.io.DefaultByteInput.DefaultByteInputMark
- All Implemented Interfaces:
ByteInputMark
- Enclosing class:
DefaultByteInput
protected static record DefaultByteInput.DefaultByteInputMark(DefaultByteInput defaultByteInput, DefaultByteInput.ByteChunkNode markNode, int markPosition)
extends Record
implements ByteInputMark
- Version:
- 0.0.1
- Author:
- scx567888
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedDefaultByteInputMark(DefaultByteInput defaultByteInput, DefaultByteInput.ByteChunkNode markNode, int markPosition) Creates an instance of aDefaultByteInputMarkrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedefaultByteInputrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.markNode()Returns the value of themarkNoderecord component.intReturns the value of themarkPositionrecord component.voidreset()将读取位置恢复到当前 mark.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
DefaultByteInputMark
protected DefaultByteInputMark(DefaultByteInput defaultByteInput, DefaultByteInput.ByteChunkNode markNode, int markPosition) Creates an instance of aDefaultByteInputMarkrecord class.- Parameters:
defaultByteInput- the value for thedefaultByteInputrecord componentmarkNode- the value for themarkNoderecord componentmarkPosition- the value for themarkPositionrecord component
-
-
Method Details
-
reset
Description copied from interface:ByteInputMark将读取位置恢复到当前 mark.- Specified by:
resetin interfaceByteInputMark- Throws:
AlreadyClosedException
-
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. -
defaultByteInput
Returns the value of thedefaultByteInputrecord component.- Returns:
- the value of the
defaultByteInputrecord component
-
markNode
Returns the value of themarkNoderecord component.- Returns:
- the value of the
markNoderecord component
-
markPosition
public int markPosition()Returns the value of themarkPositionrecord component.- Returns:
- the value of the
markPositionrecord component
-