Interface InstanceHost
- All Known Implementing Classes:
MudInstance
public interface InstanceHost
Interactive operations on one hosted mudlib, independent of its player transport.
-
Method Summary
Modifier and TypeMethodDescriptiondefault <T> Tadminister(Function<LPCRuntime, T> action) Executes trusted administrative work on the selected mudlib's execution queue, serialized with player dispatch and ticks.voidattachPersona(PrintWriter out, String remoteAddress) default voidbindClientProtocolSink(InstancePersona persona, BiConsumer<String, String> protocolOutputSink) Binds the transport callback used for negotiated out-of-band protocol messages.voiddetachPersona(InstancePersona persona) voiddispatch(InstancePersona persona, PrintWriter out, String commandLine) Delivers input; player-facing command meaning and responses belong to the mudlib.booleanisAttached(InstancePersona persona) booleanisCapturingInput(InstancePersona persona) booleanisCapturingNoEchoInput(InstancePersona persona) voidprintPromptIfReady(InstancePersona persona, PrintWriter out) default voidreceiveClientProtocolMessage(InstancePersona persona, String protocol, String message) Delivers one decoded-text message received over a negotiated client protocol.default voidsetClientProtocolEnabled(InstancePersona persona, String protocol, boolean enabled) Notifies the hosted runtime that a client protocol has been enabled or disabled.voiddefault StringPrefix that escapes a line into transport control rather than mudlib command dispatch.
-
Method Details
-
administer
Executes trusted administrative work on the selected mudlib's execution queue, serialized with player dispatch and ticks. The callback must not use the runtime outside an administer call, and must not wait for network input or write to a socket. -
mudlibRoot
Path mudlibRoot() -
bootResult
MudlibBootResult bootResult() -
worldTickInterval
Duration worldTickInterval() -
advanceWorldTick
void advanceWorldTick() -
shutdown
-
attachPersona
-
bindClientProtocolSink
default void bindClientProtocolSink(InstancePersona persona, BiConsumer<String, String> protocolOutputSink) Binds the transport callback used for negotiated out-of-band protocol messages. -
setClientProtocolEnabled
Notifies the hosted runtime that a client protocol has been enabled or disabled. -
receiveClientProtocolMessage
Delivers one decoded-text message received over a negotiated client protocol. -
detachPersona
-
dispatch
Delivers input; player-facing command meaning and responses belong to the mudlib. -
printPromptIfReady
-
isCapturingInput
-
isCapturingNoEchoInput
-
isAttached
-
transportControlPrefix
Prefix that escapes a line into transport control rather than mudlib command dispatch.
-