Class: RgGen::RAL::Item

Inherits:
OutputBase::Item show all
Includes:
VerilogUtility
Defined in:
lib/rggen/core_components/ral/item.rb

Constant Summary

Constants inherited from OutputBase::Item

OutputBase::Item::CODE_GENERATION_METHODS

Instance Attribute Summary collapse

Attributes inherited from Base::Item

#owner

Instance Method Summary collapse

Methods included from VerilogUtility

#create_blank_file

Methods included from CodeUtility

#create_blank_code

Methods inherited from OutputBase::Item

#build, inherited, #write_file

Methods inherited from Base::Item

#available?, available?, define_helpers, inherit_class_instance_variable

Methods included from Forwardable

#def_class_delegator, #def_class_delegators

Constructor Details

#initialize(owner) ⇒ Item



7
8
9
10
11
12
# File 'lib/rggen/core_components/ral/item.rb', line 7

def initialize(owner)
  super(owner)
  @identifiers            = []
  @variable_declarations  = Hash.new { |h, d| h[d]  = [] }
  @parameter_declarations = Hash.new { |h, d| h[d]  = [] }
end

Instance Attribute Details

#identifiersObject (readonly)

Returns the value of attribute identifiers.



14
15
16
# File 'lib/rggen/core_components/ral/item.rb', line 14

def identifiers
  @identifiers
end

Instance Method Details

#parameter_declarations(domain = nil) ⇒ Object



36
37
38
39
# File 'lib/rggen/core_components/ral/item.rb', line 36

def parameter_declarations(domain = nil)
  domain || (return @parameter_declarations)
  @parameter_declarations[domain]
end

#variable_declarations(domain = nil) ⇒ Object



31
32
33
34
# File 'lib/rggen/core_components/ral/item.rb', line 31

def variable_declarations(domain = nil)
  domain || (return @variable_declarations)
  @variable_declarations[domain]
end