class

Cl8r::Model::Switch

Inherits YAML::Serializable < Reference < Object

Models physical Top-of-Rack (TOR), Spine, and Management switches and their port patch schedules.

Constructors

new(name : String = "", role : String = "tor", model : String | Nil = nil, rack : String | Nil = nil, rack_unit : Int32 | Nil = nil, management_ip : String | Nil = nil, ports : Hash(String, SwitchPort) = {} of String => SwitchPort)

Initializes a Switch with elevation, management IP, and port schedules.

Source
new(*, __context_for_yaml_serializable ctx : YAML::ParseContext, __node_for_yaml_serializable node : YAML::Nodes::Node)
Source

Instance methods

management_ip
Source
management_ip=(management_ip : String | Nil)
Source
model
Source
model=(model : String | Nil)
Source
name
Source
name=(name : String)
Source
ports
Source
ports=(ports : Hash(String, SwitchPort))
Source
rack
Source
rack=(rack : String | Nil)
Source
rack_unit
Source
rack_unit=(rack_unit : Int32 | Nil)
Source
role
Source
role=(role : String)
Source