Package septogeddon.pluginquery.api
Interface QueryMetadataKey<T>
- Type Parameters:
T- Anything
public interface QueryMetadataKey<T>
Metadata Key used to get Metadata Value
- Author:
- Thito Yalasatria Sunarya
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionHandle object castingbooleanisInstance(Object from) Determine if the object is exactly what we wantedname()Key namestatic <T> QueryMetadataKey<T> newCastableKey(String key, Class<T> cl) Create new key using Cast-able rule where this key only accept value that instance of the specified class
-
Method Details
-
newCastableKey
Create new key using Cast-able rule where this key only accept value that instance of the specified class- Type Parameters:
T- Anything- Parameters:
key- The key name forname()cl- The class owner- Returns:
- The created metadata key
-
name
String name()Key name- Returns:
-
cast
Handle object casting- Parameters:
from- Object stored in the metadata storage- Returns:
- Casted object
-
isInstance
Determine if the object is exactly what we wanted- Parameters:
from- Object stored in the metadata storage- Returns:
- true if its the object we wanted
- See Also:
-