Class: Dependency

Inherits:
Object
  • Object
show all
Defined in:
lib/vraptor-scaffold/generators/app/dependency/dependency.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (Dependency) initialize(group, name, version = nil, exclusions = [])

Returns a new instance of Dependency



5
6
7
8
9
10
# File 'lib/vraptor-scaffold/generators/app/dependency/dependency.rb', line 5

def initialize group, name, version=nil, exclusions=[]
  @group = group
  @name = name
  @version = version
  @exclusions = exclusions
end

Instance Attribute Details

- (Object) exclusions

Returns the value of attribute exclusions



3
4
5
# File 'lib/vraptor-scaffold/generators/app/dependency/dependency.rb', line 3

def exclusions
  @exclusions
end

- (Object) group

Returns the value of attribute group



3
4
5
# File 'lib/vraptor-scaffold/generators/app/dependency/dependency.rb', line 3

def group
  @group
end

- (Object) name

Returns the value of attribute name



3
4
5
# File 'lib/vraptor-scaffold/generators/app/dependency/dependency.rb', line 3

def name
  @name
end

- (Object) version

Returns the value of attribute version



3
4
5
# File 'lib/vraptor-scaffold/generators/app/dependency/dependency.rb', line 3

def version
  @version
end

Instance Method Details

- (Boolean) has_exclusions?

Returns:

  • (Boolean)


12
13
14
# File 'lib/vraptor-scaffold/generators/app/dependency/dependency.rb', line 12

def has_exclusions?
  !@exclusions.empty?
end