Class: Configuration
- Inherits:
-
Object
- Object
- Configuration
- Defined in:
- lib/torasup/configuration.rb
Constant Summary collapse
- DEFAULT_COUNTRIES =
["US", "GB", "AU", "IT", "RU", "NO"]
Instance Attribute Summary collapse
-
#custom_pstn_data_file ⇒ Object
Returns the value of attribute custom_pstn_data_file.
-
#default_countries ⇒ Object
Returns the value of attribute default_countries.
-
#registered_operators ⇒ Object
Returns the value of attribute registered_operators.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #register_operators(country_code, *operators) ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
5 6 7 |
# File 'lib/torasup/configuration.rb', line 5 def initialize @default_countries = DEFAULT_COUNTRIES end |
Instance Attribute Details
#custom_pstn_data_file ⇒ Object
Returns the value of attribute custom_pstn_data_file.
3 4 5 |
# File 'lib/torasup/configuration.rb', line 3 def custom_pstn_data_file @custom_pstn_data_file end |
#default_countries ⇒ Object
Returns the value of attribute default_countries.
3 4 5 |
# File 'lib/torasup/configuration.rb', line 3 def default_countries @default_countries end |
#registered_operators ⇒ Object
Returns the value of attribute registered_operators.
3 4 5 |
# File 'lib/torasup/configuration.rb', line 3 def registered_operators @registered_operators end |
Instance Method Details
#register_operators(country_code, *operators) ⇒ Object
19 20 21 22 |
# File 'lib/torasup/configuration.rb', line 19 def register_operators(country_code, *operators) registered_operators[country_code] = operators Torasup.load_pstn_data! end |