CreationShakeIf

Constructors

Link copied to clipboard
constructor(condition: CreationShakeValue, body: CreationShakeCode, elseBody: CreationShakeCode? = null)

Properties

Link copied to clipboard
open override val body: CreationShakeCode

The block of code to be executed if the condition is true.

Link copied to clipboard
open override val condition: CreationShakeValue

The condition that determines whether the 'if' block or the 'else' block (if present) should be executed. This is a value that should evaluate to a boolean.

Link copied to clipboard
open override val elseBody: CreationShakeCode? = null

The block of code to be executed if the condition is false. This is optional and may be null if no 'else' block is present.

Functions

Link copied to clipboard
open override fun toJson(): Map<String, Any?>

Converts this statement to a JSON representation. This can be useful for serialization, debugging, or analyzing the structure of the code.