Cl8r::Config::Schema
Inherits YAML::Serializable < Struct < Value < Object
Data model and strict validation schema for cl8r configuration settings.
Constants
ALLOWED_COLORS = ["auto", "always", "never"] of ::String
ALLOWED_OUTPUT_FORMATS = ["pretty", "text", "json", "yaml", "csv"] of ::String
ALLOWED_PROFILES = ["minimal", "small", "medium", "large", "ceph", "libvirt", "libvirt-ceph", "openshift", "openstack", "generic"] of ::String
VALID_KEYS = ["language", "output_format", "color", "server_host", "server_port", "default_profile"] of ::String
Constructors
new(language : String = "en", output_format : String = "pretty", color : String = "auto", server_host : String = "0.0.0.0", server_port : Int32 = 8080, default_profile : String = "minimal")
Sourcenew(*, __context_for_yaml_serializable ctx : YAML::ParseContext, __node_for_yaml_serializable node : YAML::Nodes::Node)
SourceClass methods
Normalizes language input such as 'es_MX' or 'es-mx' into 'es-MX'
Validates whether a key name is a known configuration parameter.
Instance methods
color
Sourcedefault_profile
Sourcelanguage
Sourceoutput_format
Sourceserver_host
Sourceserver_port
SourceSets a property by string key name with validation.