Class: Coalmine::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/coalmine/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



17
18
19
20
21
22
23
24
25
26
27
28
# File 'lib/coalmine/configuration.rb', line 17

def initialize
  self.protocol = "https"
  self.host = "coalmineapp.com"
  self.port = 443
  self.secure = true
  self.enabled_environments = ["production", "staging"]

  self.http_open_timeout = 3
  self.http_read_timeout = 6
  self.logger = Coalmine::Logger.new
  self.filters = []
end

Instance Attribute Details

#enabled_environmentsObject

Returns the value of attribute enabled_environments.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def enabled_environments
  @enabled_environments
end

#environmentObject

Returns the value of attribute environment.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def environment
  @environment
end

#filtersObject

Returns the value of attribute filters.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def filters
  @filters
end

#frameworkObject

Returns the value of attribute framework.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def framework
  @framework
end

#hostObject

Returns the value of attribute host.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def host
  @host
end

#http_open_timeoutObject

Returns the value of attribute http_open_timeout.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def http_open_timeout
  @http_open_timeout
end

#http_passwordObject

Returns the value of attribute http_password.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def http_password
  @http_password
end

#http_read_timeoutObject

Returns the value of attribute http_read_timeout.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def http_read_timeout
  @http_read_timeout
end

#http_userObject

Returns the value of attribute http_user.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def http_user
  @http_user
end

#loggerObject

Returns the value of attribute logger.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def logger
  @logger
end

#portObject

Returns the value of attribute port.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def port
  @port
end

#project_rootObject

Returns the value of attribute project_root.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def project_root
  @project_root
end

#protocolObject

Returns the value of attribute protocol.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def protocol
  @protocol
end

#proxy_hostObject

Returns the value of attribute proxy_host.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def proxy_host
  @proxy_host
end

#proxy_passwordObject

Returns the value of attribute proxy_password.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def proxy_password
  @proxy_password
end

#proxy_portObject

Returns the value of attribute proxy_port.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def proxy_port
  @proxy_port
end

#proxy_userObject

Returns the value of attribute proxy_user.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def proxy_user
  @proxy_user
end

#secureObject

Returns the value of attribute secure.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def secure
  @secure
end

#signatureObject

Returns the value of attribute signature.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def signature
  @signature
end

#urlObject

Returns the value of attribute url.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def url
  @url
end

#versionObject

Returns the value of attribute version.



4
5
6
# File 'lib/coalmine/configuration.rb', line 4

def version
  @version
end

Instance Method Details

#secure?Boolean

Returns:

  • (Boolean)


35
36
37
# File 'lib/coalmine/configuration.rb', line 35

def secure?
  self.secure
end