class NetboxClientRuby::IPAM::IpAddress

Constants

STATUS_VALUES

Public Instance Methods

interface() click to toggle source
# File lib/netbox_client_ruby/api/ipam/ip_address.rb, line 36
def interface
  interface_data = data['interface']

  return nil unless interface_data

  if interface_data.key? ('virtual_machine')
    Virtualization::Interface.new interface_data['id']
  else
    DCIM::Interface.new interface_data['id']
  end
end
status=(value) click to toggle source
# File lib/netbox_client_ruby/api/ipam/ip_address.rb, line 31
def status=(value)
  status_code_lookup = STATUS_VALUES.fetch(value, value)
  method_missing(:status=, status_code_lookup)
end