Class: OrigenTesters::Timing::Timeset

Inherits:
Object
  • Object
show all
Defined in:
lib/origen_testers/timing.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attrs = {}) ⇒ Timeset

Returns a new instance of Timeset.



35
36
37
38
39
# File 'lib/origen_testers/timing.rb', line 35

def initialize(attrs = {})
  attrs.each do |name, value|
    send("#{name}=", value)
  end
end

Instance Attribute Details

#nameObject

Returns the value of attribute name.



33
34
35
# File 'lib/origen_testers/timing.rb', line 33

def name
  @name
end

#period_in_nsObject

Returns the value of attribute period_in_ns.



33
34
35
# File 'lib/origen_testers/timing.rb', line 33

def period_in_ns
  @period_in_ns
end

Instance Method Details

#shorter_period_than?(timeset) ⇒ Boolean

Returns true if the timeset has a shorter period than the supplied timeset

Returns:

  • (Boolean)


42
43
44
# File 'lib/origen_testers/timing.rb', line 42

def shorter_period_than?(timeset)
  period_in_ns < timeset.period_in_ns
end