SourcePluginRuntime
Shared source execution and compatibility facade, independent of audio and Discord clients.
class SourcePluginRuntime extends SafeEventEmitter<SourceRuntimeEvents> implements LegacyPlayerContextShared source execution and compatibility facade, independent of audio and Discord clients.
Constructors
constructoroverride
constructor(options: SourcePluginRuntimeOptions = {})Create a source runtime.
Parameters
| Name | Type | Description |
|---|---|---|
| options | SourcePluginRuntimeOptionsDefault: {} | Source settings and optional embedding context. |
Properties
pluginsreadonly
Implementation of LegacyPlayerContext.plugins
readonly plugins: PluginRegistryCanonical operation registry and lifecycle owner.
extractorsreadonly
Implementation of LegacyPlayerContext.extractors
readonly extractors: ExtractorExecutionContextLegacy constructor adapter sharing the same registry.
playerreadonly
readonly player: LegacyPlayerContextActual Player or this runtime's source facade.
optionsreadonly
Implementation of LegacyPlayerContext.options
readonly options: {
blockExtractors?: readonly string[];
probeTimeout?: number;
}Source compatibility options.
Methods
getRemedia
Implementation of LegacyPlayerContext.getRemedia
getRemedia(): RemediaClientRequired audio access is unavailable in standalone execution.
Returns
RemediaClient
getRemedia(throwOnMissing: false): RemediaClient | nullOptional audio access returns null.
Parameters
| Name | Type | Description |
|---|---|---|
| throwOnMissing | false | Optional lookup flag. |
Returns
RemediaClient | null
debug
Implementation of LegacyPlayerContext.debug
debug(message: string): voidEmit a source diagnostic.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string | Diagnostic text. |
Returns
void
destroy
search
Implementation of LegacyPlayerContext.search
search(query: MediaResource, options: SearchOptions = {}): Promise<SearchResult>Search using the same routing policy in embedded and standalone execution.
Parameters
| Name | Type | Description |
|---|---|---|
| query | MediaResource | Query or existing metadata. |
| options | SearchOptionsDefault: {} | Source targeting and cancellation. |
Returns
Promise<SearchResult>