Class: Autoproj::Ops::Tools::FakePackage

Inherits:
Autobuild::Package
  • Object
show all
Defined in:
lib/autoproj/ops/tools.rb

Overview

Data structure used to use autobuild importers without a package, to import configuration data.

It has to match the interface of Autobuild::Package that is relevant for importers

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(text_name, srcdir, importer = nil) ⇒ FakePackage

Returns a new instance of FakePackage.



20
21
22
23
24
25
# File 'lib/autoproj/ops/tools.rb', line 20

def initialize(text_name, srcdir, importer = nil)
    super(text_name)
    @srcdir = srcdir
    @importer = importer
    @@packages.delete(text_name)
end

Instance Attribute Details

#importerObject (readonly)

Returns the value of attribute importer.



11
12
13
# File 'lib/autoproj/ops/tools.rb', line 11

def importer
  @importer
end

#srcdirObject (readonly)

Returns the value of attribute srcdir.



10
11
12
# File 'lib/autoproj/ops/tools.rb', line 10

def srcdir
  @srcdir
end

#updatedObject

Used by the autobuild importers



14
15
16
# File 'lib/autoproj/ops/tools.rb', line 14

def updated
  @updated
end

Instance Method Details

#add_stat(*args) ⇒ Object



31
32
# File 'lib/autoproj/ops/tools.rb', line 31

def add_stat(*args)
end

#autoproj_nameObject



16
17
18
# File 'lib/autoproj/ops/tools.rb', line 16

def autoproj_name
    name
end

#import(**options) ⇒ Object



27
28
29
# File 'lib/autoproj/ops/tools.rb', line 27

def import(**options)
    importer.import(self, **options)
end