class LittleGhost::Providers::Configuration
Holds trusted provider connection settings independently from model profiles. Connection names and option keys are normalized to strings, and the resulting mapping is immutable.
Attributes
Normalized provider connections keyed by application-defined name.
Public Class Methods
Source
# File lib/little_ghost/providers/configuration.rb, line 13 def initialize(connections = {}) unless connections.is_a?(Hash) raise ConfigurationError, "providers must be a mapping" end @connections = normalize(connections).freeze validate! freeze end
Copies and freezes connections so callers may safely reuse their input.
Public Instance Methods
# File lib/little_ghost/providers/configuration.rb, line 26 def credentials(provider:, adapter:, configuration:) {} end
Returns credentials merged into configuration when provider is constructed with adapter. Subclasses may resolve secrets lazily here. The base implementation adds no credentials.