class HDLRuby::High::TypeDef
Describes a high-level type definition.
NOTE: type definition are actually type with a name refering to another
type (and equivalent to it).
Constants
- High
High-level libraries for describing digital hardware.
Public Class Methods
new(name,type)
click to toggle source
Creates a new type definition named name
refering type
.
Calls superclass method
HDLRuby::Low::TypeDef::new
# File lib/HDLRuby/hruby_high.rb, line 1691 def initialize(name,type) # Initialize the type structure. super(name,type) end
Public Instance Methods
to_low(name = self.name)
click to toggle source
Converts the type to HDLRuby::Low
and set its name
.
NOTE: should be overridden by other type classes.
# File lib/HDLRuby/hruby_high.rb, line 1699 def to_low(name = self.name) # return HDLRuby::Low::TypeDef.new(name,self.def.to_low) typeDefL = HDLRuby::Low::TypeDef.new(name,self.def.to_low) # For debugging: set the source high object typeDefL.properties[:low2high] = self.hdr_id self.properties[:high2low] = typeDefL return typeDefL end