Module: OSGi::ProjectExtension
- Includes:
- Extension
- Included in:
- Buildr::Project
- Defined in:
- lib/buildr4osgi/osgi/project_extension.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#dependencies(&block) ⇒ Object
Reads the dependencies from dependencies.yml and returns the direct dependencies of the project, as well as its project dependencies and their own dependencies.
-
#manifest_dependencies ⇒ Object
returns an array of the dependencies of the plugin, read from the manifest.
Instance Method Details
#dependencies(&block) ⇒ Object
Reads the dependencies from dependencies.yml and returns the direct dependencies of the project, as well as its project dependencies and their own dependencies. This method is used recursively, so beware of cyclic dependencies.
198 199 200 201 202 |
# File 'lib/buildr4osgi/osgi/project_extension.rb', line 198 def dependencies(&block) deps = ::OSGi::Dependencies.new(project) deps.read deps.dependencies + deps.projects end |
#manifest_dependencies ⇒ Object
returns an array of the dependencies of the plugin, read from the manifest.
205 206 207 208 |
# File 'lib/buildr4osgi/osgi/project_extension.rb', line 205 def manifest_dependencies() as_bundle = Bundle.fromProject(self) as_bundle.nil? ? [] : as_bundle.bundles.collect{|b| b.resolve(self)}.compact + as_bundle.imports.collect {|i| i.resolve(self)}.flatten end |