Package net.minecraft.util
Record Class ColorRGBA
java.lang.Object
java.lang.Record
net.minecraft.util.ColorRGBA
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.private Stringfinal inthashCode()Returns a hash code value for this object.intrgba()Returns the value of thergbarecord component.toString()Returns a string representation of this record class.
- 
Field Details- 
rgbaprivate final int rgbaThe field for thergbarecord component.
- 
CUSTOM_COLOR_PREFIX- See Also:
 
- 
CODEC
 
- 
- 
Constructor Details- 
ColorRGBApublic ColorRGBA(int rgba) Creates an instance of aColorRGBArecord class.- Parameters:
- rgba- the value for the- rgbarecord component
 
 
- 
- 
Method Details- 
formatValue
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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 with '=='.
- 
rgbapublic int rgba()Returns the value of thergbarecord component.- Returns:
- the value of the rgbarecord component
 
 
-