Sha256: 0940c2edd1bdbf9e2e20d12916ec26bf36d4325c54894bd2ffbfe2b4548fce56
Contents?: true
Size: 677 Bytes
Versions: 2
Compression:
Stored size: 677 Bytes
Contents
# frozen_string_literal: true require "dry/system/provider" require "dry/system/provider_registry" module Dry module System # Register external component provider # # @api public def self.register_provider(name, options) providers.register(name, options) providers[name].load_components self end # Register an external component that can be booted within other systems # # @api public def self.register_component(name, provider:, &block) providers[provider].register_component(name, block) self end # @api private def self.providers @providers ||= ProviderRegistry.new end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dry-system-0.22.0 | lib/dry/system.rb |
dry-system-0.21.0 | lib/dry/system.rb |