Package ch.njol.skript.bukkitutil
Class NamespacedUtils
java.lang.Object
ch.njol.skript.bukkitutil.NamespacedUtils
Utility class for
NamespacedKey
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ValidationResult
<org.bukkit.NamespacedKey> checkValidation
(String string) Check if thestring
is valid for aNamespacedKey
and get aValidationResult
containing if it's valid, an error or warning message and the resultingNamespacedKey
.static boolean
Check ifstring
is valid for aNamespacedKey
.static boolean
isValidKeyChar
(char character) static boolean
isValidNamespaceChar
(char character)
-
Field Details
-
NAMEDSPACED_FORMAT_MESSAGE
-
-
Constructor Details
-
NamespacedUtils
public NamespacedUtils()
-
-
Method Details
-
isValidNamespaceChar
public static boolean isValidNamespaceChar(char character) - Parameters:
character
- TheCharacter
to check.- Returns:
True
if valid, otherwisefalse
.
-
isValidKeyChar
public static boolean isValidKeyChar(char character) - Parameters:
character
- TheCharacter
to check.- Returns:
True
if valid, otherwisefalse
.
-
checkValidation
Check if thestring
is valid for aNamespacedKey
and get aValidationResult
containing if it's valid, an error or warning message and the resultingNamespacedKey
.- Parameters:
string
- TheString
to check.- Returns:
ValidationResult
.
-
isValid
Check ifstring
is valid for aNamespacedKey
.- Parameters:
string
- TheString
to check.- Returns:
True
if valid, otherwisefalse
.
-