Class: IceGrid::PropertyDescriptor
- Inherits:
-
Object
- Object
- IceGrid::PropertyDescriptor
- Includes:
- Ice::Inspect_mixin
- Defined in:
- ruby/IceGrid/Descriptor.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(name = '', value = '') ⇒ PropertyDescriptor
constructor
A new instance of PropertyDescriptor.
Methods included from Ice::Inspect_mixin
Constructor Details
#initialize(name = '', value = '') ⇒ PropertyDescriptor
Returns a new instance of PropertyDescriptor.
18 19 20 21 |
# File 'ruby/IceGrid/Descriptor.rb', line 18 def initialize(name='', value='') @name = name @value = value end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
41 42 43 |
# File 'ruby/IceGrid/Descriptor.rb', line 41 def name @name end |
#value ⇒ Object
Returns the value of attribute value.
41 42 43 |
# File 'ruby/IceGrid/Descriptor.rb', line 41 def value @value end |
Instance Method Details
#==(other) ⇒ Object
30 31 32 33 34 35 |
# File 'ruby/IceGrid/Descriptor.rb', line 30 def ==(other) return false if !other.is_a? ::IceGrid::PropertyDescriptor or @name != other.name or @value != other.value true end |
#eql?(other) ⇒ Boolean
37 38 39 |
# File 'ruby/IceGrid/Descriptor.rb', line 37 def eql?(other) return other.class == self.class && other == self end |
#hash ⇒ Object
23 24 25 26 27 28 |
# File 'ruby/IceGrid/Descriptor.rb', line 23 def hash _h = 0 _h = 5 * _h + @name.hash _h = 5 * _h + @value.hash _h % 0x7fffffff end |