Gridarta Editor
net.sf.gridarta.plugin.PluginParameters Class Reference

Makes basic Gridarta classes available to scripts. More...

+ Collaboration diagram for net.sf.gridarta.plugin.PluginParameters:

Public Member Functions

void addPluginParameter (@NotNull final String name, @Nullable final Object value)
 Defines a variable to be passed to plugins. More...
 
void setInterpreterValues (@NotNull final Interpreter interpreter, @NotNull final PluginRunMode pluginRunMode) throws EvalError
 Adds variables to a Interpreter instance. More...
 

Private Attributes

final Map< String, Object > variables = new HashMap<>()
 All defined variables for new plugins. More...
 

Detailed Description

Makes basic Gridarta classes available to scripts.

Author
Andreas Kirschbaum

Definition at line 33 of file PluginParameters.java.

Member Function Documentation

◆ addPluginParameter()

void net.sf.gridarta.plugin.PluginParameters.addPluginParameter ( @NotNull final String  name,
@Nullable final Object  value 
)

Defines a variable to be passed to plugins.

Parameters
namethe variable name
valuethe variable's value

Definition at line 46 of file PluginParameters.java.

Referenced by net.sf.gridarta.project.ProjectModel<?, ?, ?>.newPluginParameters().

+ Here is the caller graph for this function:

◆ setInterpreterValues()

void net.sf.gridarta.plugin.PluginParameters.setInterpreterValues ( @NotNull final Interpreter  interpreter,
@NotNull final PluginRunMode  pluginRunMode 
) throws EvalError

Adds variables to a Interpreter instance.

Parameters
interpreterthe interpreter to modify
pluginRunModethe plugin run mode to use
Exceptions
EvalErrorif a variable cannot be set

Definition at line 56 of file PluginParameters.java.

Referenced by net.sf.gridarta.plugin.PluginExecutor< G extends GameObject< G, A, R, A extends MapArchObject< A, R extends Archetype< G, A, R >.doRunPlugin().

+ Here is the caller graph for this function:

Member Data Documentation

◆ variables

final Map<String, Object> net.sf.gridarta.plugin.PluginParameters.variables = new HashMap<>()
private

All defined variables for new plugins.

Maps variable name to value.

Definition at line 39 of file PluginParameters.java.


The documentation for this class was generated from the following file: