Class SynchronousDebugEnv
java.lang.Object
gay.object.hexdebug.core.api.debugging.DebugEnvironment
gay.object.hexdebug.core.api.debugging.SynchronousDebugEnv
-
Constructor Summary
ConstructorsConstructorDescriptionSynchronousDebugEnv(@NotNull net.minecraft.server.level.ServerPlayer caster, @NotNull at.petrak.hexcasting.api.casting.eval.CastingEnvironment env, @NotNull List<at.petrak.hexcasting.api.casting.iota.Iota> iotas) -
Method Summary
Modifier and TypeMethodDescriptionbooleanFor in-world debugees, returns whether the caster is close enough to the debuggee to allow debug-related actions to be performed (eg.booleanpause()Attempts to pause the debuggee.booleanrestart(int threadId) Attempts to restart the debuggee on the given debug thread.booleanresume(@NotNull at.petrak.hexcasting.api.casting.eval.CastingEnvironment env, @NotNull at.petrak.hexcasting.api.casting.eval.vm.CastingImage image, @NotNull at.petrak.hexcasting.api.casting.eval.ResolvedPatternType resolutionType) Attempts to resume execution of the debuggee.voidMethods inherited from class gay.object.hexdebug.core.api.debugging.DebugEnvironment
getCaster, getLastDebugStepType, getLastEvaluatedAction, getSessionId, printDebugMessage, printDebugMessage, printDebugMessage, printDebugMishap, setLastDebugStepType, setLastEvaluatedAction
-
Constructor Details
-
SynchronousDebugEnv
public SynchronousDebugEnv(@NotNull @NotNull net.minecraft.server.level.ServerPlayer caster, @NotNull @NotNull at.petrak.hexcasting.api.casting.eval.CastingEnvironment env, @NotNull @NotNull List<at.petrak.hexcasting.api.casting.iota.Iota> iotas)
-
-
Method Details
-
pause
public boolean pause()Description copied from class:DebugEnvironmentAttempts to pause the debuggee. This is called by the debugger when requested by the user.- Specified by:
pausein classDebugEnvironment- Returns:
- whether the debuggee was successfully paused
-
resume
public boolean resume(@NotNull @NotNull at.petrak.hexcasting.api.casting.eval.CastingEnvironment env, @NotNull @NotNull at.petrak.hexcasting.api.casting.eval.vm.CastingImage image, @NotNull @NotNull at.petrak.hexcasting.api.casting.eval.ResolvedPatternType resolutionType) Description copied from class:DebugEnvironmentAttempts to resume execution of the debuggee. This is called by the debugger after the current continuation is successfully evaluated to completion.- Specified by:
resumein classDebugEnvironment- Returns:
- true if the debug session can continue, or false if the debuggee has been terminated
-
restart
public boolean restart(int threadId) Description copied from class:DebugEnvironmentAttempts to restart the debuggee on the given debug thread. This is called by the debugger when requested by the user.
The previous debug thread is removed before this method is called, so the implementation may useHexDebugCoreAPI.createDebugThread(gay.object.hexdebug.core.api.debugging.DebugEnvironment, java.lang.Integer)andHexDebugCoreAPI.startExecuting(gay.object.hexdebug.core.api.debugging.DebugEnvironment, at.petrak.hexcasting.api.casting.eval.CastingEnvironment, java.util.List<at.petrak.hexcasting.api.casting.iota.Iota>).- Specified by:
restartin classDebugEnvironment- Returns:
- whether the debuggee was successfully restarted
-
isCasterInRange
public boolean isCasterInRange()Description copied from class:DebugEnvironmentFor in-world debugees, returns whether the caster is close enough to the debuggee to allow debug-related actions to be performed (eg. pause, step, restart).- Specified by:
isCasterInRangein classDebugEnvironment
-
start
public void start(@Nullable @Nullable Integer threadId) throws IllegalDebugSessionException, IllegalDebugThreadException
-