Class: Gat::Dependence::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/gat/dependence/base.rb

Direct Known Subclasses

Argument, Folder, Program

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, config, operation) ⇒ Base

Returns a new instance of Base.



38
39
40
41
42
43
44
# File 'lib/gat/dependence/base.rb', line 38

def initialize(name, config, operation)
	operation.gatget.logger.log("trace", "dependence", "Initialize dependence #{ self.class } @#{ name }")
	@operation    = operation
	@config       = config
	@name         = name
	@description  = @config['description'] || "Another #{ self.class } dependence named #{ self.name }"
end

Instance Attribute Details

#configObject (readonly)

Returns the value of attribute config.



29
30
31
# File 'lib/gat/dependence/base.rb', line 29

def config
  @config
end

#descriptionObject (readonly)

Returns the value of attribute description.



32
33
34
# File 'lib/gat/dependence/base.rb', line 32

def description
  @description
end

#nameObject (readonly)

Returns the value of attribute name.



30
31
32
# File 'lib/gat/dependence/base.rb', line 30

def name
  @name
end

#operationObject (readonly)

Returns the value of attribute operation.



28
29
30
# File 'lib/gat/dependence/base.rb', line 28

def operation
  @operation
end

#typeObject (readonly)

Returns the value of attribute type.



31
32
33
# File 'lib/gat/dependence/base.rb', line 31

def type
  @type
end

#valueObject

Returns the value of attribute value.



35
36
37
# File 'lib/gat/dependence/base.rb', line 35

def value
  @value
end

Instance Method Details

#evalueObject

Raises:



47
48
49
# File 'lib/gat/dependence/base.rb', line 47

def evalue
	raise GatgetException.new("Evalue method is not available at Gat::Dependece. Create your own at #{ self.class }", 'evalue_dependence_without_type')
end