Package org.deepsymmetry.beatlink.data
Class ColorItem
- java.lang.Object
-
- org.deepsymmetry.beatlink.data.SearchableItem
-
- org.deepsymmetry.beatlink.data.ColorItem
-
public class ColorItem extends SearchableItem
Represents a track color label. This is a specializedSearchableItem, since in addition to a specific color, it has an ID and label that can be used as a way to select tracks in a dynamic playlist request, and on which playlists can be sorted. A simple immutable value class.- Author:
- James Elliott
-
-
Constructor Detail
-
ColorItem
public ColorItem(int id, String label, Color color, String colorName)Constructor simply sets the immutable value fields- Parameters:
id- the database ID associated with this item, for searcheslabel- the text label used to show this item to the usercolor- the color represented by this itemcolorName- the name of the color represented by this item, for textual display
-
-
Method Detail
-
toString
public String toString()
- Overrides:
toStringin classSearchableItem
-
hashCode
public int hashCode()
- Overrides:
hashCodein classSearchableItem
-
equals
public boolean equals(Object obj)
- Overrides:
equalsin classSearchableItem
-
-