类 TestFrameworkImpl
java.lang.Object
net.neoforged.testframework.impl.TestFrameworkImpl
- 所有已实现的接口:
MutableTestFramework
,TestFramework
@Internal
@ParametersAreNonnullByDefault
public class TestFrameworkImpl
extends Object
implements MutableTestFramework
-
嵌套类概要
嵌套类从接口继承的嵌套类/接口 net.neoforged.testframework.impl.MutableTestFramework
MutableTestFramework.MutableTests
从接口继承的嵌套类/接口 net.neoforged.testframework.TestFramework
TestFramework.Tests
-
字段概要
字段修饰符和类型字段说明private final @Nullable FrameworkClient
private @UnknownNullability String
private final FrameworkConfiguration
private @UnknownNullability net.neoforged.fml.ModContainer
(专用程序包) static final Set
<TestFrameworkImpl> private final ResourceLocation
private boolean
private final org.slf4j.Logger
private @UnknownNullability net.neoforged.bus.api.IEventBus
private final SavedDataType
<PlayerTestStore> private @Nullable MinecraftServer
private final DynamicStructureTemplates
private final TestFrameworkImpl.TestsImpl
从接口继承的字段 net.neoforged.testframework.impl.MutableTestFramework
REFERENCE_CODEC
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static String
capitaliseWords
(String string, String splitOn) void
changeStatus
(Test test, Test.Status newStatus, @Nullable Entity changer) Changes the status of a test.collectTests
(net.neoforged.fml.ModContainer container) net.neoforged.fml.ModContainer
返回 the mod container bus linked to this framework。返回 a registrar for in-code structure templates。id()
返回 the ID of this framework instance。void
init
(net.neoforged.bus.api.IEventBus modBus, net.neoforged.fml.ModContainer container) org.slf4j.Logger
logger()
返回 this framework's logger。net.neoforged.bus.api.IEventBus
返回 the mod event bus linked to this framework。private void
processSummary
(TestSummary summary) void
registerCommands
(com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> node) private void
sendPacketIfOn
(@Nullable Runnable onServer, @Nullable Runnable remoteClient, @Nullable Runnable singlePlayer) void
setEnabled
(Test test, boolean enabled, @Nullable Entity changer) Enables or disables a test.private static void
setupClient
(TestFrameworkImpl impl, net.neoforged.bus.api.IEventBus modBus, net.neoforged.fml.ModContainer container) tests()
返回 the Tests instance of this framework。从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
从接口继承的方法 net.neoforged.testframework.impl.MutableTestFramework
buildCommand, disableCommand, enableCommand, setStatusCommand
-
字段详细资料
-
FRAMEWORKS
-
configuration
-
client
-
logger
private final org.slf4j.Logger logger -
id
-
tests
-
server
-
structures
-
inClientWorld
private boolean inClientWorld -
commandName
-
playerTestStoreType
-
modBus
private @UnknownNullability net.neoforged.bus.api.IEventBus modBus -
container
private @UnknownNullability net.neoforged.fml.ModContainer container
-
-
构造器详细资料
-
TestFrameworkImpl
-
-
方法详细资料
-
processSummary
-
registerCommands
public void registerCommands(com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> node) - 指定者:
registerCommands
在接口中MutableTestFramework
-
playerTestStore
- 指定者:
playerTestStore
在接口中MutableTestFramework
-
dynamicStructures
从接口复制的说明:TestFramework
返回 a registrar for in-code structure templates。- 指定者:
dynamicStructures
在接口中TestFramework
- 返回:
- a registrar for in-code structure templates
-
commandName
- 指定者:
commandName
在接口中MutableTestFramework
-
configuration
- 指定者:
configuration
在接口中MutableTestFramework
-
init
public void init(net.neoforged.bus.api.IEventBus modBus, net.neoforged.fml.ModContainer container) - 指定者:
init
在接口中MutableTestFramework
-
setupClient
private static void setupClient(TestFrameworkImpl impl, net.neoforged.bus.api.IEventBus modBus, net.neoforged.fml.ModContainer container) -
collectTests
- 指定者:
collectTests
在接口中MutableTestFramework
-
modEventBus
public net.neoforged.bus.api.IEventBus modEventBus()从接口复制的说明:TestFramework
返回 the mod event bus linked to this framework。- 指定者:
modEventBus
在接口中TestFramework
- 返回:
- the mod event bus linked to this framework
-
container
public net.neoforged.fml.ModContainer container()从接口复制的说明:TestFramework
返回 the mod container bus linked to this framework。- 指定者:
container
在接口中TestFramework
- 返回:
- the mod container bus linked to this framework
-
id
从接口复制的说明:TestFramework
返回 the ID of this framework instance。- 指定者:
id
在接口中TestFramework
- 返回:
- the ID of this framework instance
-
logger
public org.slf4j.Logger logger()从接口复制的说明:TestFramework
返回 this framework's logger。- 指定者:
logger
在接口中TestFramework
- 返回:
- this framework's logger
-
tests
从接口复制的说明:TestFramework
返回 the Tests instance of this framework。- 指定者:
tests
在接口中MutableTestFramework
- 指定者:
tests
在接口中TestFramework
- 返回:
- the Tests instance of this framework
-
changeStatus
从接口复制的说明:TestFramework
Changes the status of a test.- 指定者:
changeStatus
在接口中TestFramework
- 参数:
test
- the test whose status to changenewStatus
- the status to change tochanger
- the entity that changed the status of the test. Usually the player completing a test
-
setEnabled
从接口复制的说明:TestFramework
Enables or disables a test.- 指定者:
setEnabled
在接口中TestFramework
- 参数:
test
- the test to enable/disableenabled
-true
if to enable,false
if to disablechanger
- the entity that changed the status of the test. Usually the player which runs the enable command
-
sendPacketIfOn
-
capitaliseWords
-