Package xyz.jpenilla.squaremap.api
Class Key
java.lang.Object
xyz.jpenilla.squaremap.api.Key
Simple string wrapper used to identify things. Equality is checked based only on the key string.
Valid characters for keys are [a-zA-Z0-9._-].
In most cases keys should be unique, so prefixing keys with a plugin name, for example "myplugin_layer-1", would be good practice.
-
Method Details
-
of
Get a new Key instance for the provided key string.- Parameters:
key- string for the key- Returns:
- new key
-
key
Get a new Key instance for the provided key string.- Parameters:
key- string for the key- Returns:
- new key
-
getKey
Get the key string for this key- Returns:
- key string
-
equals
-
hashCode
public int hashCode() -
toString
-