|
Gridarta Editor
|
Inheritance diagram for net.sf.gridarta.gui.scripts.AbstractScriptArchUtils:
Collaboration diagram for net.sf.gridarta.gui.scripts.AbstractScriptArchUtils:Public Member Functions | |
| void | addEventsToJList (@NotNull final JList< String > list, @NotNull final 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. More... | |
| String [] | getEventNames () |
| Returns all event names. More... | |
| int | indexToEventType (final int index) |
| Converts a combo box index to an event type. More... | |
| String | typeName (final int eventType) |
| Returns a human readable name for an event type. More... | |
Public Member Functions inherited from net.sf.gridarta.model.scripts.ScriptArchUtils | |
| String | getArchetypeNameForEventType (int eventType) throws UndefinedEventArchetypeTypeException |
| Returns the archetype for an event type. More... | |
Protected Member Functions | |
| AbstractScriptArchUtils (@NotNull final Iterable< Pair< Integer, String >> eventTypes, @NotNull final String subtypeAttribute, final int eventTypeNo) | |
| Creates a new instance. More... | |
| String | getEventType (final int eventType) |
| Returns the type name for an event type. More... | |
Private Member Functions | |
| void | add (final int eventType, @NotNull final String eventName) |
| Adds on event description. More... | |
Private Attributes | |
| final Map< Integer, String > | allEventTypes = new HashMap<>() |
| Maps event type to event name. More... | |
| final List< String > | eventNames = new ArrayList<>() |
| All event names. More... | |
| final int | eventTypeNo |
| The object type for event objects. More... | |
| final Map< Integer, Integer > | indexToEventType = new HashMap<>() |
| Maps index into eventNames to event type. More... | |
| final String | subtypeAttribute |
| The attribute name for the subtype field. More... | |
Definition at line 35 of file AbstractScriptArchUtils.java.
|
protected |
Creates a new instance.
| eventTypes | the event types |
| subtypeAttribute | the attribute name for the subtype field |
| eventTypeNo | the object type for event objects |
Definition at line 74 of file AbstractScriptArchUtils.java.
References net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.add(), net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.eventTypeNo, and net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.subtypeAttribute.
Here is the call graph for this function:
|
private |
Adds on event description.
| eventType | the event type |
| eventName | the event name |
Definition at line 89 of file AbstractScriptArchUtils.java.
Referenced by net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.AbstractScriptArchUtils().
Here is the caller graph for this function:| void net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.addEventsToJList | ( | @NotNull final JList< String > | list, |
| @NotNull final 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.
| list | the JList |
| gameObject | the game object to operate on |
Implements net.sf.gridarta.model.scripts.ScriptArchUtils.
Definition at line 130 of file AbstractScriptArchUtils.java.
References net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.eventTypeNo, and net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.typeName().
Here is the call graph for this function:| String [] net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.getEventNames | ( | ) |
Returns all event names.
Implements net.sf.gridarta.model.scripts.ScriptArchUtils.
Definition at line 125 of file AbstractScriptArchUtils.java.
|
protected |
Returns the type name for an event type.
| eventType | the event type |
Definition at line 109 of file AbstractScriptArchUtils.java.
Referenced by net.sf.gridarta.var.crossfire.gui.scripts.DefaultScriptArchUtils.getArchetypeNameForEventType().
Here is the caller graph for this function:| int net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.indexToEventType | ( | final int | index | ) |
Converts a combo box index to an event type.
| index | the combo box index |
Implements net.sf.gridarta.model.scripts.ScriptArchUtils.
Definition at line 114 of file AbstractScriptArchUtils.java.
| String net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.typeName | ( | final int | eventType | ) |
Returns a human readable name for an event type.
| eventType | the event type |
Implements net.sf.gridarta.model.scripts.ScriptArchUtils.
Definition at line 98 of file AbstractScriptArchUtils.java.
Referenced by net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.addEventsToJList(), and net.sf.gridarta.var.crossfire.gui.scripts.DefaultScriptArchUtils.getArchetypeNameForEventType().
Here is the caller graph for this function:
|
private |
Maps event type to event name.
Definition at line 54 of file AbstractScriptArchUtils.java.
|
private |
All event names.
Definition at line 66 of file AbstractScriptArchUtils.java.
|
private |
The object type for event objects.
Definition at line 48 of file AbstractScriptArchUtils.java.
Referenced by net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.AbstractScriptArchUtils(), and net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.addEventsToJList().
|
private |
Maps index into eventNames to event type.
Definition at line 60 of file AbstractScriptArchUtils.java.
|
private |
The attribute name for the subtype field.
Definition at line 42 of file AbstractScriptArchUtils.java.
Referenced by net.sf.gridarta.gui.scripts.AbstractScriptArchUtils.AbstractScriptArchUtils().