Class ScriptConfiguration
- Namespace
- Artemis.Core.ScriptingProviders
- Assembly
- Artemis.Core.dll
Represents the configuration of a script
public class ScriptConfiguration : CorePropertyChanged, IStorageModel
- Inheritance
-
ScriptConfiguration
- Implements
Constructors
ScriptConfiguration(ScriptingProvider, string, ScriptType)
Creates a new instance of the ScriptConfiguration class
public ScriptConfiguration(ScriptingProvider provider, string name, ScriptType scriptType)
Parameters
provider
ScriptingProvidername
stringscriptType
ScriptType
Properties
HasChanges
Gets or sets a boolean indicating whether this configuration has pending changes to it's ScriptContent
public bool HasChanges { get; set; }
Property Value
IsSuspended
[NYI] Gets or sets a boolean indicating whether this configuration is suspended
public bool IsSuspended { get; set; }
Property Value
Name
Gets or sets the name of the script
public string Name { get; set; }
Property Value
PendingScriptContent
Gets or sets the pending changes to the script's content
public string? PendingScriptContent { get; set; }
Property Value
Script
If active, gets the script
public Script? Script { get; }
Property Value
ScriptContent
Gets or sets the script's content
public string? ScriptContent { get; }
Property Value
ScriptingProviderId
Gets or sets the ID of the scripting provider
public string ScriptingProviderId { get; set; }
Property Value
Methods
ApplyPendingChanges()
Applies the PendingScriptContent to the ScriptContent
public void ApplyPendingChanges()
DiscardPendingChanges()
Discards the PendingScriptContent
public void DiscardPendingChanges()
Load()
Loads the model from its associated entity
public void Load()
OnScriptContentChanged()
Invokes the ScriptContentChanged event
protected virtual void OnScriptContentChanged()
Save()
Saves the model to its associated entity
public void Save()
Events
ScriptContentChanged
Occurs whenever the contents of the script have changed
public event EventHandler? ScriptContentChanged