Class: MistApi::GatewayPortMirroringPortMirror
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- MistApi::GatewayPortMirroringPortMirror
- Defined in:
- lib/mist_api/models/gateway_port_mirroring_port_mirror.rb
Overview
GatewayPortMirroringPortMirror Model.
Instance Attribute Summary collapse
-
#family_type ⇒ String
TODO: Write general description for this method.
-
#ingress_port_ids ⇒ Array[String]
TODO: Write general description for this method.
-
#output_port_id ⇒ String
TODO: Write general description for this method.
-
#rate ⇒ Integer
TODO: Write general description for this method.
-
#run_length ⇒ Integer
TODO: Write general description for this method.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(family_type = SKIP, ingress_port_ids = SKIP, output_port_id = SKIP, rate = SKIP, run_length = SKIP) ⇒ GatewayPortMirroringPortMirror
constructor
A new instance of GatewayPortMirroringPortMirror.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(family_type = SKIP, ingress_port_ids = SKIP, output_port_id = SKIP, rate = SKIP, run_length = SKIP) ⇒ GatewayPortMirroringPortMirror
Returns a new instance of GatewayPortMirroringPortMirror.
59 60 61 62 63 64 65 66 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 59 def initialize(family_type = SKIP, ingress_port_ids = SKIP, output_port_id = SKIP, rate = SKIP, run_length = SKIP) @family_type = family_type unless family_type == SKIP @ingress_port_ids = ingress_port_ids unless ingress_port_ids == SKIP @output_port_id = output_port_id unless output_port_id == SKIP @rate = rate unless rate == SKIP @run_length = run_length unless run_length == SKIP end |
Instance Attribute Details
#family_type ⇒ String
TODO: Write general description for this method
14 15 16 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 14 def family_type @family_type end |
#ingress_port_ids ⇒ Array[String]
TODO: Write general description for this method
18 19 20 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 18 def ingress_port_ids @ingress_port_ids end |
#output_port_id ⇒ String
TODO: Write general description for this method
22 23 24 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 22 def output_port_id @output_port_id end |
#rate ⇒ Integer
TODO: Write general description for this method
26 27 28 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 26 def rate @rate end |
#run_length ⇒ Integer
TODO: Write general description for this method
30 31 32 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 30 def run_length @run_length end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 69 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. family_type = hash.key?('family_type') ? hash['family_type'] : SKIP ingress_port_ids = hash.key?('ingress_port_ids') ? hash['ingress_port_ids'] : SKIP output_port_id = hash.key?('output_port_id') ? hash['output_port_id'] : SKIP rate = hash.key?('rate') ? hash['rate'] : SKIP run_length = hash.key?('run_length') ? hash['run_length'] : SKIP # Create object from extracted values. GatewayPortMirroringPortMirror.new(family_type, ingress_port_ids, output_port_id, rate, run_length) end |
.names ⇒ Object
A mapping from model property names to API property names.
33 34 35 36 37 38 39 40 41 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 33 def self.names @_hash = {} if @_hash.nil? @_hash['family_type'] = 'family_type' @_hash['ingress_port_ids'] = 'ingress_port_ids' @_hash['output_port_id'] = 'output_port_id' @_hash['rate'] = 'rate' @_hash['run_length'] = 'run_length' @_hash end |
.nullables ⇒ Object
An array for nullable fields
55 56 57 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 55 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
44 45 46 47 48 49 50 51 52 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 44 def self.optionals %w[ family_type ingress_port_ids output_port_id rate run_length ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
97 98 99 100 101 102 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 97 def inspect class_name = self.class.name.split('::').last "<#{class_name} family_type: #{@family_type.inspect}, ingress_port_ids:"\ " #{@ingress_port_ids.inspect}, output_port_id: #{@output_port_id.inspect}, rate:"\ " #{@rate.inspect}, run_length: #{@run_length.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
90 91 92 93 94 |
# File 'lib/mist_api/models/gateway_port_mirroring_port_mirror.rb', line 90 def to_s class_name = self.class.name.split('::').last "<#{class_name} family_type: #{@family_type}, ingress_port_ids: #{@ingress_port_ids},"\ " output_port_id: #{@output_port_id}, rate: #{@rate}, run_length: #{@run_length}>" end |