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.



324
325
326
327
328
329
330
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 324

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

Instance Method Details

#commitObject



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

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

#headerObject



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

def header
  @header
end

#ifaceObject



320
321
322
# File 'lib/construqt/flavour/ubuntu/flavour_ubuntu_result.rb', line 320

def iface
  @iface
end

#linesObject



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

def lines
  @lines
end

#nameObject



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

def name
  @iface.name
end

#resultObject



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

def result
  @result
end

#skip_interfacesObject



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

def skip_interfaces
  @skip_interfaces = true
  self
end

#skip_interfaces?Boolean

Returns:

  • (Boolean)


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

def skip_interfaces?
  @skip_interfaces
end