Class: IceGrid::NodeDescriptor

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(variables = nil, serverInstances = nil, servers = nil, loadFactor = '', description = '', propertySets = nil) ⇒ NodeDescriptor

Returns a new instance of NodeDescriptor.



568
569
570
571
572
573
574
575
# File 'lib/IceGrid/Descriptor.rb', line 568

def initialize(variables=nil, serverInstances=nil, servers=nil, loadFactor='', description='', propertySets=nil)
    @variables = variables
    @serverInstances = serverInstances
    @servers = servers
    @loadFactor = loadFactor
    @description = description
    @propertySets = propertySets
end

Instance Attribute Details

#descriptionObject

Returns the value of attribute description.



603
604
605
# File 'lib/IceGrid/Descriptor.rb', line 603

def description
  @description
end

#loadFactorObject

Returns the value of attribute loadFactor.



603
604
605
# File 'lib/IceGrid/Descriptor.rb', line 603

def loadFactor
  @loadFactor
end

#propertySetsObject

Returns the value of attribute propertySets.



603
604
605
# File 'lib/IceGrid/Descriptor.rb', line 603

def propertySets
  @propertySets
end

#serverInstancesObject

Returns the value of attribute serverInstances.



603
604
605
# File 'lib/IceGrid/Descriptor.rb', line 603

def serverInstances
  @serverInstances
end

#serversObject

Returns the value of attribute servers.



603
604
605
# File 'lib/IceGrid/Descriptor.rb', line 603

def servers
  @servers
end

#variablesObject

Returns the value of attribute variables.



603
604
605
# File 'lib/IceGrid/Descriptor.rb', line 603

def variables
  @variables
end

Instance Method Details

#==(other) ⇒ Object



588
589
590
591
592
593
594
595
596
597
# File 'lib/IceGrid/Descriptor.rb', line 588

def ==(other)
    return false if !other.is_a? ::IceGrid::NodeDescriptor or
        @variables != other.variables or
        @serverInstances != other.serverInstances or
        @servers != other.servers or
        @loadFactor != other.loadFactor or
        @description != other.description or
        @propertySets != other.propertySets
    true
end

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


599
600
601
# File 'lib/IceGrid/Descriptor.rb', line 599

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

#hashObject



577
578
579
580
581
582
583
584
585
586
# File 'lib/IceGrid/Descriptor.rb', line 577

def hash
    _h = 0
    _h = 5 * _h + @variables.hash
    _h = 5 * _h + @serverInstances.hash
    _h = 5 * _h + @servers.hash
    _h = 5 * _h + @loadFactor.hash
    _h = 5 * _h + @description.hash
    _h = 5 * _h + @propertySets.hash
    _h % 0x7fffffff
end