PluginException

Sealed hierarchy for plugin lifecycle exceptions.

Extracted from TrustWeaveException to give plugin-related errors a focused home. All subtypes extend TrustWeaveException so they remain compatible with existing catch blocks that catch the base type.

Inheritors

Types

Link copied to clipboard
data class AlreadyRegistered(val pluginId: String, val existingPlugin: String? = null) : PluginException
Link copied to clipboard

Singleton representing a blank/empty plugin ID — has no state.

Link copied to clipboard
data class DependencyVersionMismatch(val pluginId: String, val dependencyId: String, val requiredRange: String, val actualVersion: String) : PluginException

A required org.trustweave.core.plugin.PluginDependency.versionRange is not satisfied by the version of an already-registered dependency.

Link copied to clipboard
data class InitializationFailed(val pluginId: String, val reason: String, val cause: Throwable? = null) : PluginException
Link copied to clipboard
data class NotFound(val pluginId: String, val pluginType: String? = null) : PluginException

Properties

Link copied to clipboard
open override val cause: Throwable?
Link copied to clipboard
open val code: String
Link copied to clipboard
open val context: Map<String, Any?>

Context map containing additional error information.

Link copied to clipboard
open override val message: String

Functions

Link copied to clipboard

Checks if the exception is configuration-related (i.e., an instance of ConfigException).

Link copied to clipboard

Checks if the exception is encoding/digest-related.

Link copied to clipboard

Checks if the exception is serialization/JSON-related (i.e., an instance of SerializationException).

Link copied to clipboard

Checks if the exception is plugin-related (i.e., an instance of PluginException).

Link copied to clipboard

Checks if the exception is provider-related (i.e., an instance of ProviderException).

Link copied to clipboard

Checks if the exception is validation-related.

Link copied to clipboard

Extension function to convert any Throwable to a TrustWeaveException.