C# Class ARCed.Scripting.Script

Represents a script file
Mostrar archivo Open project: borisblizzard/arcreator Class Usage Examples

Public Properties

Property Type Description
DummyScript Script

Public Methods

Method Description
Exists ( ) : bool

Checks if the script has a associated file

GetFullPath ( ) : string

Uses the index and title of the script to create a unique filename

Load ( string filename ) : bool

Loads a script file from the given path

Reload ( ) : void

Reloads the script from file

Save ( ) : bool

Saves the script to disk using generated filename

Script ( ) : System

Default constructor

Script ( string filename ) : System

Parametered constructor to load a script after construction

Private Methods

Method Description
SetIndex ( int index ) : void

Sets the index of the script

SetText ( string text ) : void

Sets the text of the script

SetTitle ( string title ) : void

Sets the title of the script

Method Details

Exists() public method

Checks if the script has a associated file
public Exists ( ) : bool
return bool

GetFullPath() public method

Uses the index and title of the script to create a unique filename
public GetFullPath ( ) : string
return string

Load() public method

Loads a script file from the given path
public Load ( string filename ) : bool
filename string The path to the script
return bool

Reload() public method

Reloads the script from file
public Reload ( ) : void
return void

Save() public method

Saves the script to disk using generated filename
public Save ( ) : bool
return bool

Script() public method

Default constructor
public Script ( ) : System
return System

Script() public method

Parametered constructor to load a script after construction
public Script ( string filename ) : System
filename string The filename of the script to load
return System

Property Details

DummyScript public_oe static_oe property

Gets an empty script object.
public static Script DummyScript
return Script