Skip to content

Commit 0a71c69

Browse files
committed
Rename DebugOutputCategory to OutputCategory
1 parent 8efd92b commit 0a71c69

File tree

5 files changed

+18
-18
lines changed

5 files changed

+18
-18
lines changed

Common/src/main/java/gay/object/hexdebug/mixin/MixinBlockEntityAbstractImpetus.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import com.llamalad7.mixinextras.injector.wrapoperation.Operation;
77
import com.llamalad7.mixinextras.injector.wrapoperation.WrapOperation;
88
import gay.object.hexdebug.core.api.HexDebugCoreAPI;
9-
import gay.object.hexdebug.core.api.debugging.DebugOutputCategory;
9+
import gay.object.hexdebug.core.api.debugging.OutputCategory;
1010
import gay.object.hexdebug.core.api.exceptions.DebugException;
1111
import gay.object.hexdebug.debugger.circles.CircleDebugEnv;
1212
import gay.object.hexdebug.debugger.circles.IMixinBlockEntityAbstractImpetus;
@@ -80,7 +80,7 @@ public InteractionResult startDebugging(@NotNull ServerPlayer caster, int thread
8080
if (executionState != null) {
8181
var debugEnv = ((IMixinCircleExecutionState) executionState).getDebugEnv$hexdebug();
8282
if (debugEnv != null) {
83-
debugEnv.printDebugMessage(mishapDisplay, DebugOutputCategory.STDERR);
83+
debugEnv.printDebugMessage(mishapDisplay, OutputCategory.STDERR);
8484
}
8585
}
8686
}
@@ -101,7 +101,7 @@ public InteractionResult startDebugging(@NotNull ServerPlayer caster, int thread
101101
if (executionState != null) {
102102
var debugEnv = ((IMixinCircleExecutionState) executionState).getDebugEnv$hexdebug();
103103
if (debugEnv != null) {
104-
debugEnv.printDebugMessage(error, DebugOutputCategory.STDERR, false);
104+
debugEnv.printDebugMessage(error, OutputCategory.STDERR, false);
105105
}
106106
}
107107
original.call(instance, error, display);

Common/src/main/kotlin/gay/object/hexdebug/impl/HexDebugCoreAPIImpl.kt

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import at.petrak.hexcasting.api.casting.iota.Iota
66
import gay.`object`.hexdebug.adapter.DebugAdapter
77
import gay.`object`.hexdebug.adapter.DebugAdapterManager
88
import gay.`object`.hexdebug.core.api.HexDebugCoreAPI
9+
import gay.`object`.hexdebug.core.api.debugging.OutputCategory
910
import gay.`object`.hexdebug.core.api.debugging.env.DebugEnvironment
10-
import gay.`object`.hexdebug.core.api.debugging.DebugOutputCategory
1111
import gay.`object`.hexdebug.core.api.exceptions.IllegalDebugSessionException
1212
import net.minecraft.network.chat.Component
1313
import net.minecraft.server.level.ServerPlayer
@@ -52,15 +52,15 @@ class HexDebugCoreAPIImpl : HexDebugCoreAPI {
5252
caster: ServerPlayer,
5353
sessionId: UUID,
5454
message: Component,
55-
category: DebugOutputCategory,
55+
category: OutputCategory,
5656
withSource: Boolean,
5757
) {
5858
val categoryStr = when (category) {
59-
DebugOutputCategory.CONSOLE -> OutputEventArgumentsCategory.CONSOLE
60-
DebugOutputCategory.IMPORTANT -> OutputEventArgumentsCategory.IMPORTANT
61-
DebugOutputCategory.STDOUT -> OutputEventArgumentsCategory.STDOUT
62-
DebugOutputCategory.STDERR -> OutputEventArgumentsCategory.STDERR
63-
DebugOutputCategory.TELEMETRY -> OutputEventArgumentsCategory.TELEMETRY
59+
OutputCategory.CONSOLE -> OutputEventArgumentsCategory.CONSOLE
60+
OutputCategory.IMPORTANT -> OutputEventArgumentsCategory.IMPORTANT
61+
OutputCategory.STDOUT -> OutputEventArgumentsCategory.STDOUT
62+
OutputCategory.STDERR -> OutputEventArgumentsCategory.STDERR
63+
OutputCategory.TELEMETRY -> OutputEventArgumentsCategory.TELEMETRY
6464
}
6565
DebugAdapterManager[caster]?.print(sessionId, message.string + "\n", categoryStr, withSource)
6666
}

Core/Common/src/main/java/gay/object/hexdebug/core/api/HexDebugCoreAPI.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import at.petrak.hexcasting.api.casting.eval.vm.CastingImage;
55
import at.petrak.hexcasting.api.casting.iota.Iota;
66
import gay.object.hexdebug.core.api.debugging.env.DebugEnvironment;
7-
import gay.object.hexdebug.core.api.debugging.DebugOutputCategory;
7+
import gay.object.hexdebug.core.api.debugging.OutputCategory;
88
import gay.object.hexdebug.core.api.exceptions.IllegalDebugSessionException;
99
import gay.object.hexdebug.core.api.exceptions.IllegalDebugThreadException;
1010
import net.minecraft.network.chat.Component;
@@ -83,7 +83,7 @@ default void printDebugMessage(
8383
@NotNull ServerPlayer caster,
8484
@NotNull UUID sessionId,
8585
@NotNull Component message,
86-
@NotNull DebugOutputCategory category,
86+
@NotNull OutputCategory category,
8787
boolean withSource
8888
) {}
8989

Core/Common/src/main/java/gay/object/hexdebug/core/api/debugging/DebugOutputCategory.java renamed to Core/Common/src/main/java/gay/object/hexdebug/core/api/debugging/OutputCategory.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package gay.object.hexdebug.core.api.debugging;
22

3-
public enum DebugOutputCategory {
3+
public enum OutputCategory {
44
CONSOLE,
55
IMPORTANT,
66
STDOUT,

Core/Common/src/main/java/gay/object/hexdebug/core/api/debugging/env/DebugEnvironment.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import at.petrak.hexcasting.api.casting.eval.sideeffects.OperatorSideEffect;
77
import at.petrak.hexcasting.api.casting.eval.vm.CastingImage;
88
import gay.object.hexdebug.core.api.HexDebugCoreAPI;
9-
import gay.object.hexdebug.core.api.debugging.DebugOutputCategory;
9+
import gay.object.hexdebug.core.api.debugging.OutputCategory;
1010
import gay.object.hexdebug.core.api.debugging.DebugStepType;
1111
import gay.object.hexdebug.core.api.debugging.StopReason;
1212
import net.minecraft.network.chat.Component;
@@ -94,19 +94,19 @@ public void postStep(
9494
) {}
9595

9696
public void printDebugMessage(@NotNull Component message) {
97-
printDebugMessage(message, DebugOutputCategory.STDOUT, true);
97+
printDebugMessage(message, OutputCategory.STDOUT, true);
9898
}
9999

100100
public void printDebugMessage(
101101
@NotNull Component message,
102-
@NotNull DebugOutputCategory category
102+
@NotNull OutputCategory category
103103
) {
104104
printDebugMessage(message, category, true);
105105
}
106106

107107
public void printDebugMessage(
108108
@NotNull Component message,
109-
@NotNull DebugOutputCategory category,
109+
@NotNull OutputCategory category,
110110
boolean withSource
111111
) {
112112
HexDebugCoreAPI.INSTANCE.printDebugMessage(caster, sessionId, message, category, withSource);
@@ -118,7 +118,7 @@ public void printDebugMishap(
118118
) {
119119
var message = sideEffect.getMishap().errorMessageWithName(env, sideEffect.getErrorCtx());
120120
if (message != null) {
121-
printDebugMessage(message, DebugOutputCategory.STDERR);
121+
printDebugMessage(message, OutputCategory.STDERR);
122122
}
123123
}
124124

0 commit comments

Comments
 (0)