Module technology.sola.ecs
Package technology.sola.ecs.view
Record Class View1Entry<C1 extends Component>
java.lang.Object
java.lang.Record
technology.sola.ecs.view.View1Entry<C1>
- Type Parameters:
C1
- the component type- Record Components:
entity
- theEntity
c1
- theComponent
instance
- All Implemented Interfaces:
ViewEntry
-
Constructor Summary
ConstructorsConstructorDescriptionView1Entry
(Entity entity, C1 c1) Creates an instance of aView1Entry
record class. -
Method Summary
Modifier and TypeMethodDescriptionc1()
Returns the value of thec1
record component.entity()
Returns the value of theentity
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
Method Details
-
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)
. -
entity
Returns the value of theentity
record component. -
c1
Returns the value of thec1
record component.- Returns:
- the value of the
c1
record component
-