Record Class ScriptManager.Script
java.lang.Object
java.lang.Record
com.soulfiremc.server.script.ScriptManager.Script
- Enclosing class:
ScriptManager
public static record ScriptManager.Script(UUID scriptId, String name, Path dataPath, Path codePath, ScriptEntity.ScriptType scriptType, boolean elevatedPermissions, ScriptLanguage language, AtomicReference<ScriptManager.RuntimeComponents> runtime)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionScript(UUID scriptId, String name, Path dataPath, Path codePath, ScriptEntity.ScriptType scriptType, boolean elevatedPermissions, ScriptLanguage language, AtomicReference<ScriptManager.RuntimeComponents> runtime) Creates an instance of aScriptrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncodePath()Returns the value of thecodePathrecord component.dataPath()Returns the value of thedataPathrecord component.booleanReturns the value of theelevatedPermissionsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.language()Returns the value of thelanguagerecord component.name()Returns the value of thenamerecord component.runtime()Returns the value of theruntimerecord component.scriptId()Returns the value of thescriptIdrecord component.Returns the value of thescriptTyperecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Script
public Script(UUID scriptId, String name, Path dataPath, Path codePath, ScriptEntity.ScriptType scriptType, boolean elevatedPermissions, ScriptLanguage language, AtomicReference<ScriptManager.RuntimeComponents> runtime) Creates an instance of aScriptrecord class.- Parameters:
scriptId- the value for thescriptIdrecord componentname- the value for thenamerecord componentdataPath- the value for thedataPathrecord componentcodePath- the value for thecodePathrecord componentscriptType- the value for thescriptTyperecord componentelevatedPermissions- the value for theelevatedPermissionsrecord componentlanguage- the value for thelanguagerecord componentruntime- the value for theruntimerecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
scriptId
Returns the value of thescriptIdrecord component.- Returns:
- the value of the
scriptIdrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
dataPath
Returns the value of thedataPathrecord component.- Returns:
- the value of the
dataPathrecord component
-
codePath
Returns the value of thecodePathrecord component.- Returns:
- the value of the
codePathrecord component
-
scriptType
Returns the value of thescriptTyperecord component.- Returns:
- the value of the
scriptTyperecord component
-
elevatedPermissions
public boolean elevatedPermissions()Returns the value of theelevatedPermissionsrecord component.- Returns:
- the value of the
elevatedPermissionsrecord component
-
language
Returns the value of thelanguagerecord component.- Returns:
- the value of the
languagerecord component
-
runtime
Returns the value of theruntimerecord component.- Returns:
- the value of the
runtimerecord component
-