name of the currently loaded model.
name of the currently loaded model. Will be null if this is a new (unsaved) model. To get a version for display to the user, see modelNameForDisplay(). This is NOT a full path name, however, it does end in ".nlogo".
attaches the current model directory to a relative path, if necessary.
attaches the current model directory to a relative path, if necessary. If filePath is an absolute path, this method simply returns it. If it's a relative path, then the current model directory is prepended to it. If this is a new model, the user's platform-dependent home directory is prepended instead.
Runs NetLogo commands and waits for them to complete.
Runs NetLogo commands and waits for them to complete.
The command or commands to run
org.nlogo.api.LogoException if the code fails to run
org.nlogo.core.CompilerException
if the code fails to compile
instantly converts the current model to ModelTypeJ.NORMAL.
instantly converts the current model to ModelTypeJ.NORMAL. This is used by the edit command to enable quick saving of library models. It shouldn't be used anywhere else.
whether the user needs to enter a new filename to save this model.
whether the user needs to enter a new filename to save this model. We need to do a "save as" if the model is new, from the models library, or converted.
Basically, only normal models can get silently saved.
returns the full path to the directory from which the current model was loaded.
returns the full path to the directory from which the current model was loaded. May be null if, for example, this is a new model.
returns the name of the file from which the current model was loaded.
returns the name of the file from which the current model was loaded. May be null if, for example, this is a new model.
returns the full pathname of the currently loaded model, if any.
returns the full pathname of the currently loaded model, if any. This may return null in some cases, for instance if this is a new model.
Runs a NetLogo reporter.
Runs a NetLogo reporter.
The reporter to run
the result reported; may be of type java.lang.Integer, java.lang.Double,
java.lang.Boolean, java.lang.String, org.nlogo.core.LogoList,
org.nlogo.api.Agent, AgentSet, or Nobody
org.nlogo.api.LogoException if the code fails to run
org.nlogo.core.CompilerException
if the code fails to compile