public abstract class AbstractScriptArchUtils extends java.lang.Object implements ScriptArchUtils
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractScriptArchUtils(@NotNull java.lang.Iterable<Pair<java.lang.Integer,java.lang.String>> eventTypes,
@NotNull java.lang.String subtypeAttribute,
int eventTypeNo)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addEventsToJList(@NotNull javax.swing.JList<java.lang.String> list,
@NotNull java.lang.Iterable<? extends GameObject<?,?,?>> gameObject)
Set all ScriptedEvents to appear in the given JList This method should be
fast because it may be executed when user clicks on map objects.
|
@NotNull java.lang.String[] |
getEventNames()
Returns all event names.
|
protected @Nullable java.lang.String |
getEventType(int eventType)
Returns the type name for an event type.
|
int |
indexToEventType(int index)
Converts a combo box index to an event type.
|
@NotNull java.lang.String |
typeName(int eventType)
Returns a human readable name for an event type.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetArchetypeNameForEventTypeprotected AbstractScriptArchUtils(@NotNull
@NotNull java.lang.Iterable<Pair<java.lang.Integer,java.lang.String>> eventTypes,
@NotNull
@NotNull java.lang.String subtypeAttribute,
int eventTypeNo)
eventTypes - the event typessubtypeAttribute - the attribute name for the subtype fieldeventTypeNo - the object type for event objects@NotNull public @NotNull java.lang.String typeName(int eventType)
ScriptArchUtilstypeName in interface ScriptArchUtilseventType - the event type@Nullable protected @Nullable java.lang.String getEventType(int eventType)
eventType - the event typenull for invalid event typespublic int indexToEventType(int index)
ScriptArchUtilsindexToEventType in interface ScriptArchUtilsindex - the combo box index@NotNull public @NotNull java.lang.String[] getEventNames()
ScriptArchUtilsgetEventNames in interface ScriptArchUtilspublic void addEventsToJList(@NotNull
@NotNull javax.swing.JList<java.lang.String> list,
@NotNull
@NotNull java.lang.Iterable<? extends GameObject<?,?,?>> gameObject)
ScriptArchUtilsaddEventsToJList in interface ScriptArchUtilslist - the JListgameObject - the game object to operate on