Class: Utils::Bottles::Collector

Inherits:
Object
  • Object
show all
Defined in:
brew/Library/Homebrew/utils/bottles.rb,
brew/Library/Homebrew/extend/os/mac/utils/bottles.rb

Instance Method Summary collapse

Constructor Details

#initializeCollector

Returns a new instance of Collector



91
92
93
# File 'brew/Library/Homebrew/utils/bottles.rb', line 91

def initialize
  @checksums = {}
end

Instance Method Details

#[](key) ⇒ Object



104
105
106
# File 'brew/Library/Homebrew/utils/bottles.rb', line 104

def [](key)
  @checksums[key]
end

#[]=(key, value) ⇒ Object



108
109
110
# File 'brew/Library/Homebrew/utils/bottles.rb', line 108

def []=(key, value)
  @checksums[key] = value
end

#fetch_checksum_for(tag) ⇒ Object



95
96
97
98
# File 'brew/Library/Homebrew/utils/bottles.rb', line 95

def fetch_checksum_for(tag)
  tag = find_matching_tag(tag)
  return self[tag], tag if tag
end

#key?(key) ⇒ Boolean

Returns:

  • (Boolean)


112
113
114
# File 'brew/Library/Homebrew/utils/bottles.rb', line 112

def key?(key)
  @checksums.key?(key)
end

#keysObject



100
101
102
# File 'brew/Library/Homebrew/utils/bottles.rb', line 100

def keys
  @checksums.keys
end