Sha256: f2ac1a759daf635186f6696caae5e77f3a80672559c0ef0db09bb857c2a0cf02

Contents?: true

Size: 687 Bytes

Versions: 205

Compression:

Stored size: 687 Bytes

Contents

module Origen
  module Registers
    # This is a regular Ruby hash that is used to store collections of Reg objects, it has additional
    # methods added to allow interaction with the contained registers.
    # All Ruby hash methods are also available - http://www.ruby-doc.org/core/classes/Hash.html
    class RegCollection < Hash
      # Returns the object that owns the registers
      attr_reader :owner

      def initialize(owner, _options = {})
        @owner = owner
      end

      def inspect
        map { |k, _v| k }.inspect
      end

      # Display all regs visually in a console session
      def show
        puts map { |_k, v| v }.inspect
      end
    end
  end
end

Version data entries

205 entries across 205 versions & 1 rubygems

Version Path
origen-0.60.17 lib/origen/registers/reg_collection.rb
origen-0.60.16 lib/origen/registers/reg_collection.rb
origen-0.60.14 lib/origen/registers/reg_collection.rb
origen-0.60.13 lib/origen/registers/reg_collection.rb
origen-0.60.12 lib/origen/registers/reg_collection.rb
origen-0.60.11 lib/origen/registers/reg_collection.rb
origen-0.60.10 lib/origen/registers/reg_collection.rb
origen-0.60.9 lib/origen/registers/reg_collection.rb
origen-0.60.8 lib/origen/registers/reg_collection.rb
origen-0.60.7 lib/origen/registers/reg_collection.rb
origen-0.60.6 lib/origen/registers/reg_collection.rb
origen-0.60.5 lib/origen/registers/reg_collection.rb
origen-0.60.4 lib/origen/registers/reg_collection.rb
origen-0.60.3 lib/origen/registers/reg_collection.rb
origen-0.60.2 lib/origen/registers/reg_collection.rb
origen-0.60.1 lib/origen/registers/reg_collection.rb
origen-0.60.0 lib/origen/registers/reg_collection.rb
origen-0.59.8 lib/origen/registers/reg_collection.rb
origen-0.59.7 lib/origen/registers/reg_collection.rb
origen-0.59.6 lib/origen/registers/reg_collection.rb