Class: Construqt::Flavour::Ubuntu::EtcNetworkInterfaces::Entry

Inherits:
Object
  • Object
show all
Defined in:
lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb

Defined Under Namespace

Classes: Header, Lines

Instance Method Summary collapse

Constructor Details

#initialize(result, iface) ⇒ Entry

Returns a new instance of Entry.



336
337
338
339
340
341
342
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 336

def initialize(result, iface)
  @result = result
  @iface = iface
  @header = Header.new(self)
  @lines = Lines.new(self)
  @skip_interfaces = false
end

Instance Method Details

#commitObject



369
370
371
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 369

def commit
  @header.commit + @lines.commit
end

#headerObject



352
353
354
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 352

def header
  @header
end

#ifaceObject



332
333
334
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 332

def iface
  @iface
end

#linesObject



356
357
358
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 356

def lines
  @lines
end

#nameObject



348
349
350
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 348

def name
  @iface.name
end

#resultObject



344
345
346
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 344

def result
  @result
end

#skip_interfacesObject



364
365
366
367
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 364

def skip_interfaces
  @skip_interfaces = true
  self
end

#skip_interfaces?Boolean

Returns:

  • (Boolean)


360
361
362
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 360

def skip_interfaces?
  @skip_interfaces
end