Skip to content

ChannelSubscription

Namespace Mc.Scripting · Kind class (sealed)

public sealed class ChannelSubscription : IDisposable, IPluginResource

A listener on a plugin messaging channel (ChannelRegistry.On). Dispose it to stop listening.

Member Description
string Channel { get; } The channel the subscription listens on.
bool IsActive { get; } Whether the subscription still listens (false after Dispose).
public string Channel { get; }

The channel the subscription listens on.

public bool IsActive { get; }

Whether the subscription still listens (false after Dispose).

Member Description
void Dispose() Stops listening.
public void Dispose()

Stops listening. When it was the last listener of its channel, the engine stops announcing the channel to the clients.

IPluginResource