Class: Zhima::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/zhima/config.rb

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.app_idObject

Returns the value of attribute app_id.



4
5
6
# File 'lib/zhima/config.rb', line 4

def app_id
  @app_id
end

.private_keyObject

Returns the value of attribute private_key.



4
5
6
# File 'lib/zhima/config.rb', line 4

def private_key
  @private_key
end

.public_keyObject

Returns the value of attribute public_key.



4
5
6
# File 'lib/zhima/config.rb', line 4

def public_key
  @public_key
end

Class Method Details

.configure {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:

  • _self (Zhima::Config)

    the object that the method was called on



6
7
8
# File 'lib/zhima/config.rb', line 6

def configure
  yield self
end

.mech_rsaObject



10
11
12
# File 'lib/zhima/config.rb', line 10

def mech_rsa
  @mech_rsa ||= OpenSSL::PKey::RSA.new private_key
end

.zm_rsaObject



14
15
16
# File 'lib/zhima/config.rb', line 14

def zm_rsa
  @zm_rsa ||= OpenSSL::PKey::RSA.new public_key
end