Record Class BookViewScreen.BookAccess
java.lang.Object
java.lang.Record
net.minecraft.client.gui.screens.inventory.BookViewScreen.BookAccess
- Enclosing class:
BookViewScreen
-
Field Summary
-
Constructor Summary
ConstructorDescriptionBookAccess
(List<Component> pages) Creates an instance of aBookAccess
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.static BookViewScreen.BookAccess
getPage
(int p_98311_) int
final int
hashCode()
Returns a hash code value for this object.pages()
Returns the value of thepages
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
pages
The field for thepages
record component.
-
-
Constructor Details
-
BookAccess
Creates an instance of aBookAccess
record class.- Parameters:
pages
- the value for thepages
record component
-
-
Method Details
-
getPageCount
public int getPageCount() -
getPage
-
fromItem
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. All components in this record class are compared withObjects::equals(Object,Object)
. -
pages
Returns the value of thepages
record component.- Returns:
- the value of the
pages
record component
-