20 package net.sf.gridarta.model.gameobject;
25 import org.jetbrains.annotations.NotNull;
26 import org.jetbrains.annotations.Nullable;
57 final StringBuilder errors =
new StringBuilder();
60 final int spaceIndex = line.indexOf(
' ');
61 final Comparable<String> attrKey = spaceIndex == -1 ? line : line.substring(0, spaceIndex);
66 errors.append(line.trim()).append(
'\n');
83 final String retErrors = errors.toString();
84 if (retErrors.trim().isEmpty()) {
GameObjectUtils()
Private constructor to prevent instantiation.
Utility class for string manipulation.
static String getSyntaxErrors(@NotNull final BaseObject<?, ?, ?, ?> gameObject, @NotNull final ArchetypeType type)
This method checks the objectText for syntax errors.
Contains the data of one Gridarta Object-Type.
String TYPE
The attribute name of the object's type.
Base package of all Gridarta classes.
String DIRECTION
The attribute name of the object's direction.
Utility class for GameObject related functions.
static final Pattern PATTERN_END_OF_LINE
The pattern to match end of line characters separating lines.
String NAME
The attribute name of the object's name.
Defines types of GameObjects with corresponding attributes.