Class: YandexTranslator::Configuration

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



14
15
16
17
18
19
20
21
# File 'lib/yat/config.rb', line 14

def initialize
  @chunk_size = 10000
  @maximum_requests = 10
  @api_key = nil
  @host = "https://translate.yandex.net"
  @json_path = '/api/v1.5/tr.json'
  @xml_path = '/api/v1.5/tr'
end

Instance Attribute Details

#api_keyObject

Returns the value of attribute api_key.



12
13
14
# File 'lib/yat/config.rb', line 12

def api_key
  @api_key
end

#chunk_sizeObject

Returns the value of attribute chunk_size.



12
13
14
# File 'lib/yat/config.rb', line 12

def chunk_size
  @chunk_size
end

#hostObject

Returns the value of attribute host.



12
13
14
# File 'lib/yat/config.rb', line 12

def host
  @host
end

#json_pathObject

Returns the value of attribute json_path.



12
13
14
# File 'lib/yat/config.rb', line 12

def json_path
  @json_path
end

#maximum_requestsObject

Returns the value of attribute maximum_requests.



12
13
14
# File 'lib/yat/config.rb', line 12

def maximum_requests
  @maximum_requests
end

#portObject

Returns the value of attribute port.



12
13
14
# File 'lib/yat/config.rb', line 12

def port
  @port
end

#xml_pathObject

Returns the value of attribute xml_path.



12
13
14
# File 'lib/yat/config.rb', line 12

def xml_path
  @xml_path
end