lib/origen/pins/pin.rb
# Add an alias to the given pin.
#
# If the options contain a package, mode or configuration reference then the alias
# will only work under that context.
Add an alias to the given pin.
If the options contain a package, mode or configuration reference then the alias
will only work under that context.
Add an alias to the given pin . If the options contain a package mode or configuration reference then the alias will only work under that context .
def add_alias(id, options = {})
        obj = options.delete(:obj) || myself
        if aliases[id]
          aliases[id][:packages] += resolve_packages(options)
          aliases[id][:modes] += resolve_modes(options)
          aliases[id][:configurations] += resolve_configurations(options)
          aliases[id][:packages].uniq!
          aliases[id][:modes].uniq!
          aliases[id][:configurations].uniq!
        else
          aliases[id] = {
            packages:       resolve_packages(options),
            modes:          resolve_modes(options),
            configurations: resolve_configurations(options)
          }
          Origen.pin_bank.register_alias(id, obj, options)
        end
      end
def add_alias ( id , options = { } ) obj = options . delete ( :obj ) || myself if aliases [ id ] aliases [ id ] [ :packages ] += resolve_packages ( options ) aliases [ id ] [ :modes ] += resolve_modes ( options ) aliases [ id ] [ :configurations ] += resolve_configurations ( options ) aliases [ id ] [ :packages ] . uniq! aliases [ id ] [ :modes ] . uniq! aliases [ id ] [ :configurations ] . uniq! else aliases [ id ] = { packages : resolve_packages ( options ) , modes : resolve_modes ( options ) , configurations : resolve_configurations ( options ) } Origen . pin_bank . register_alias ( id , obj , options ) end end
Add an alias to the given pin.
Add an alias to the given pin .
id
<not_specific>
options
<not_specific>