Package io.guise.framework.style
Class ResourceColor
java.lang.Object
io.guise.framework.style.ResourceColor
- All Implemented Interfaces:
Color
A color that retrieves its values from the Guise session resources based upon a resource key. When color-related access methods are called the calling thread
must have access to the current Guise session.
- Author:
- Garret Wilson
- See Also:
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
ResourceColor
Resource key constructor.- Parameters:
resourceKey
- The key to accessing the color defined in the resources.- Throws:
NullPointerException
- if the given resource key isnull
.
-
-
Method Details
-
getResourceKey
- Returns:
- The key to accessing the color defined in the resources.
-
asHSL
This implementation retrieves a color from the Guise session resources and delegates to that object.
-
asRGB
This implementation retrieves a color from the Guise session resources and delegates to that object.
-
hashCode
public int hashCode() -
equals
This implementation returns whether the object is another resource color with the same resource key.
-