Class: Glacier2::SSLInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/Glacier2/SSLInfo.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(remoteHost = '', remotePort = 0, localHost = '', localPort = 0, cipher = '', certs = nil) ⇒ SSLInfo

Returns a new instance of SSLInfo.



29
30
31
32
33
34
35
36
# File 'lib/Glacier2/SSLInfo.rb', line 29

def initialize(remoteHost='', remotePort=0, localHost='', localPort=0, cipher='', certs=nil)
    @remoteHost = remoteHost
    @remotePort = remotePort
    @localHost = localHost
    @localPort = localPort
    @cipher = cipher
    @certs = certs
end

Instance Attribute Details

#certsObject

Returns the value of attribute certs.



68
69
70
# File 'lib/Glacier2/SSLInfo.rb', line 68

def certs
  @certs
end

#cipherObject

Returns the value of attribute cipher.



68
69
70
# File 'lib/Glacier2/SSLInfo.rb', line 68

def cipher
  @cipher
end

#localHostObject

Returns the value of attribute localHost.



68
69
70
# File 'lib/Glacier2/SSLInfo.rb', line 68

def localHost
  @localHost
end

#localPortObject

Returns the value of attribute localPort.



68
69
70
# File 'lib/Glacier2/SSLInfo.rb', line 68

def localPort
  @localPort
end

#remoteHostObject

Returns the value of attribute remoteHost.



68
69
70
# File 'lib/Glacier2/SSLInfo.rb', line 68

def remoteHost
  @remoteHost
end

#remotePortObject

Returns the value of attribute remotePort.



68
69
70
# File 'lib/Glacier2/SSLInfo.rb', line 68

def remotePort
  @remotePort
end

Instance Method Details

#==(other) ⇒ Object



49
50
51
52
53
54
55
56
57
58
# File 'lib/Glacier2/SSLInfo.rb', line 49

def ==(other)
    return false if !other.is_a? ::Glacier2::SSLInfo or
        @remoteHost != other.remoteHost or
        @remotePort != other.remotePort or
        @localHost != other.localHost or
        @localPort != other.localPort or
        @cipher != other.cipher or
        @certs != other.certs
    true
end

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


60
61
62
# File 'lib/Glacier2/SSLInfo.rb', line 60

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

#hashObject



38
39
40
41
42
43
44
45
46
47
# File 'lib/Glacier2/SSLInfo.rb', line 38

def hash
    _h = 0
    _h = 5 * _h + @remoteHost.hash
    _h = 5 * _h + @remotePort.hash
    _h = 5 * _h + @localHost.hash
    _h = 5 * _h + @localPort.hash
    _h = 5 * _h + @cipher.hash
    _h = 5 * _h + @certs.hash
    _h % 0x7fffffff
end

#inspectObject



64
65
66
# File 'lib/Glacier2/SSLInfo.rb', line 64

def inspect
    ::Ice::__stringify(self, T_SSLInfo)
end