module Dry::System
Constants
- ComponentDirAlreadyAddedError
Error raised when a component dir is added to configuration more than once
@api public
- ComponentDirNotFoundError
Error raised when a configured component directory could not be found
@api public
- ComponentFileMismatchError
Error raised when booter file do not match with register component
@api public
- ComponentNotStartedError
Error raised when trying to stop a component that hasn't started yet
@api public
- DEFAULT_SEPARATOR
- DuplicatedComponentKeyError
- InvalidComponentError
Error raised when resolved component couldn't be loaded
@api public
- InvalidComponentNameError
Error raised when component's name is not valid
@api public
- InvalidSettingsError
- NamespaceAlreadyAddedError
Error raised when a namespace for a component dir is added to configuration more than once
- PATH_SEPARATOR
- PluginDependencyMissing
Exception raise when a plugin dependency failed to load
@api public
- PluginNotFoundError
Error raised when trying to use a plugin that does not exist.
@api public
- RB_EXT
- RB_GLOB
- VERSION
- WORD_REGEX
Public Class Methods
@api private
# File lib/dry/system.rb, line 26 def self.providers @providers ||= ProviderRegistry.new end
Register an external component that can be booted within other systems
@api public
# File lib/dry/system.rb, line 20 def self.register_component(name, provider:, &block) providers[provider].register_component(name, block) self end
Register external component provider
@api public
# File lib/dry/system.rb, line 11 def self.register_provider(name, options) providers.register(name, options) providers[name].load_components self end