Class: IceGrid::AdapterDescriptor

Inherits:
Object
  • Object
show all
Includes:
Ice::Inspect_mixin
Defined in:
lib/IceGrid/Descriptor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Ice::Inspect_mixin

#inspect

Constructor Details

#initialize(name = '', description = '', id = '', replicaGroupId = '', priority = '', registerProcess = false, serverLifetime = false, objects = nil, allocatables = nil) ⇒ AdapterDescriptor

Returns a new instance of AdapterDescriptor.



151
152
153
154
155
156
157
158
159
160
161
# File 'lib/IceGrid/Descriptor.rb', line 151

def initialize(name='', description='', id='', replicaGroupId='', priority='', registerProcess=false, serverLifetime=false, objects=nil, allocatables=nil)
    @name = name
    @description = description
    @id = id
    @replicaGroupId = replicaGroupId
    @priority = priority
    @registerProcess = registerProcess
    @serverLifetime = serverLifetime
    @objects = objects
    @allocatables = allocatables
end

Instance Attribute Details

#allocatablesObject

Returns the value of attribute allocatables.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def allocatables
  @allocatables
end

#descriptionObject

Returns the value of attribute description.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def description
  @description
end

#idObject

Returns the value of attribute id.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def id
  @id
end

#nameObject

Returns the value of attribute name.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def name
  @name
end

#objectsObject

Returns the value of attribute objects.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def objects
  @objects
end

#priorityObject

Returns the value of attribute priority.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def priority
  @priority
end

#registerProcessObject

Returns the value of attribute registerProcess.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def registerProcess
  @registerProcess
end

#replicaGroupIdObject

Returns the value of attribute replicaGroupId.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def replicaGroupId
  @replicaGroupId
end

#serverLifetimeObject

Returns the value of attribute serverLifetime.



195
196
197
# File 'lib/IceGrid/Descriptor.rb', line 195

def serverLifetime
  @serverLifetime
end

Instance Method Details

#==(other) ⇒ Object



177
178
179
180
181
182
183
184
185
186
187
188
189
# File 'lib/IceGrid/Descriptor.rb', line 177

def ==(other)
    return false if !other.is_a? ::IceGrid::AdapterDescriptor or
        @name != other.name or
        @description != other.description or
        @id != other.id or
        @replicaGroupId != other.replicaGroupId or
        @priority != other.priority or
        @registerProcess != other.registerProcess or
        @serverLifetime != other.serverLifetime or
        @objects != other.objects or
        @allocatables != other.allocatables
    true
end

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


191
192
193
# File 'lib/IceGrid/Descriptor.rb', line 191

def eql?(other)
    return other.class == self.class && other == self
end

#hashObject



163
164
165
166
167
168
169
170
171
172
173
174
175
# File 'lib/IceGrid/Descriptor.rb', line 163

def hash
    _h = 0
    _h = 5 * _h + @name.hash
    _h = 5 * _h + @description.hash
    _h = 5 * _h + @id.hash
    _h = 5 * _h + @replicaGroupId.hash
    _h = 5 * _h + @priority.hash
    _h = 5 * _h + @registerProcess.hash
    _h = 5 * _h + @serverLifetime.hash
    _h = 5 * _h + @objects.hash
    _h = 5 * _h + @allocatables.hash
    _h % 0x7fffffff
end