Class: IceGrid::PropertyDescriptor
- Inherits:
-
Object
- Object
- IceGrid::PropertyDescriptor
- Defined in:
- lib/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.
- #inspect ⇒ Object
Constructor Details
#initialize(name = '', value = '') ⇒ PropertyDescriptor
Returns a new instance of PropertyDescriptor.
34 35 36 37 |
# File 'lib/IceGrid/Descriptor.rb', line 34 def initialize(name='', value='') @name = name @value = value end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
61 62 63 |
# File 'lib/IceGrid/Descriptor.rb', line 61 def name @name end |
#value ⇒ Object
Returns the value of attribute value.
61 62 63 |
# File 'lib/IceGrid/Descriptor.rb', line 61 def value @value end |
Instance Method Details
#==(other) ⇒ Object
46 47 48 49 50 51 |
# File 'lib/IceGrid/Descriptor.rb', line 46 def ==(other) return false if !other.is_a? ::IceGrid::PropertyDescriptor or @name != other.name or @value != other.value true end |
#eql?(other) ⇒ Boolean
53 54 55 |
# File 'lib/IceGrid/Descriptor.rb', line 53 def eql?(other) return other.class == self.class && other == self end |
#hash ⇒ Object
39 40 41 42 43 44 |
# File 'lib/IceGrid/Descriptor.rb', line 39 def hash _h = 0 _h = 5 * _h + @name.hash _h = 5 * _h + @value.hash _h % 0x7fffffff end |
#inspect ⇒ Object
57 58 59 |
# File 'lib/IceGrid/Descriptor.rb', line 57 def inspect ::Ice::__stringify(self, T_PropertyDescriptor) end |