Class: RubyGemsRequirementsSystem::SystemRepository
- Inherits:
-
Object
- Object
- RubyGemsRequirementsSystem::SystemRepository
- Defined in:
- lib/rubygems-requirements-system/system-repository.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #[](key) ⇒ Object
- #each(&block) ⇒ Object
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(id, properties) ⇒ SystemRepository
constructor
A new instance of SystemRepository.
Constructor Details
#initialize(id, properties) ⇒ SystemRepository
Returns a new instance of SystemRepository.
21 22 23 24 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 21 def initialize(id, properties) @id = id @properties = properties end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
18 19 20 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 18 def id @id end |
Instance Method Details
#==(other) ⇒ Object
26 27 28 29 30 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 26 def ==(other) other.is_a?(self.class) and @id == other.id and @properties == other.properties end |
#[](key) ⇒ Object
40 41 42 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 40 def [](key) @properties[key] end |
#each(&block) ⇒ Object
44 45 46 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 44 def each(&block) @properties.each(&block) end |
#eql?(other) ⇒ Boolean
32 33 34 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 32 def eql?(other) self == other end |
#hash ⇒ Object
36 37 38 |
# File 'lib/rubygems-requirements-system/system-repository.rb', line 36 def hash [@id, @properties].hash end |