Class: OrigenTesters::SmartestBasedTester::Base::PatternMaster

Inherits:
Object
  • Object
show all
Includes:
Generator
Defined in:
lib/origen_testers/smartest_based_tester/base/pattern_master.rb

Direct Known Subclasses

V93K::PatternMaster

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Generator

#close, #collection, #collection=, #compiler, #current_dir, #dont_diff=, execute_source, #file_extension, #file_pipeline, #finalize, #identity_map, #import, #inhibit_output, #name, #on_close, #output_file, #output_inhibited?, #platform, #reference_file, #render, #set_flow_description, #stats, #to_be_written?, #write_from_template, #write_to_file

Constructor Details

#initialize(flow = nil) ⇒ PatternMaster

Returns a new instance of PatternMaster.



11
12
13
14
# File 'lib/origen_testers/smartest_based_tester/base/pattern_master.rb', line 11

def initialize(flow = nil)
  @flow = flow
  @paths = {}
end

Instance Attribute Details

#filenameObject

Returns the value of attribute filename.



9
10
11
# File 'lib/origen_testers/smartest_based_tester/base/pattern_master.rb', line 9

def filename
  @filename
end

#flowObject (readonly)

Returns the value of attribute flow.



8
9
10
# File 'lib/origen_testers/smartest_based_tester/base/pattern_master.rb', line 8

def flow
  @flow
end

#pathsObject (readonly)

Returns the value of attribute paths.



8
9
10
# File 'lib/origen_testers/smartest_based_tester/base/pattern_master.rb', line 8

def paths
  @paths
end

Instance Method Details

#add(name, options = {}) ⇒ Object



24
25
26
27
28
29
30
31
# File 'lib/origen_testers/smartest_based_tester/base/pattern_master.rb', line 24

def add(name, options = {})
  name, subdir = extract_subdir(name, options)
  name += '.binl.gz' unless name =~ /binl.gz$/
  Origen.interface.referenced_patterns << name
  paths[subdir] ||= []
  # Just add it, duplicates will be removed at render time
  paths[subdir] << name unless paths[subdir].include?(name)
end

#subdirectoryObject



20
21
22
# File 'lib/origen_testers/smartest_based_tester/base/pattern_master.rb', line 20

def subdirectory
  'vectors'
end