Module: Ewigkeks
- Defined in:
- lib/ewigkeks.rb,
lib/ewigkeks/engine.rb,
lib/ewigkeks/version.rb,
app/helpers/ewigkeks/application_helper.rb,
app/controllers/ewigkeks/cookies_controller.rb,
app/controllers/ewigkeks/application_controller.rb,
lib/generators/ewigkeks/install/install_generator.rb
Defined Under Namespace
Modules: ApplicationHelper
Classes: ApplicationController, CookiesController, Engine, InstallGenerator
Constant Summary
collapse
- VERSION =
Gem::Version.new('1.0.0')
Class Method Summary
collapse
Class Method Details
.cache_cookie_name ⇒ Object
40
41
42
|
# File 'lib/ewigkeks.rb', line 40
def cache_cookie_name
@@cache_cookie_name ||= '%s_cache' % js_class
end
|
.cache_path ⇒ Object
36
37
38
|
# File 'lib/ewigkeks.rb', line 36
def cache_path
'/%s/%s' % [scope, 'cache']
end
|
8
9
10
11
12
13
14
|
# File 'lib/ewigkeks.rb', line 8
def configure(options = {}, &block)
options.each do |key, value|
public_send("#{key}=", value)
end
yield(self) if block_given?
end
|
.etag_cookie_name ⇒ Object
48
49
50
|
# File 'lib/ewigkeks.rb', line 48
def etag_cookie_name
@@etag_cookie_name ||= '%s_etag' % js_class
end
|
.etag_path ⇒ Object
44
45
46
|
# File 'lib/ewigkeks.rb', line 44
def etag_path
'/%s/%s' % [scope, 'etag']
end
|
.js_class ⇒ Object
16
17
18
|
# File 'lib/ewigkeks.rb', line 16
def js_class
@@js_class ||= 'evercookie'
end
|
.png_cookie_name ⇒ Object
32
33
34
|
# File 'lib/ewigkeks.rb', line 32
def png_cookie_name
@@png_cookie_name ||= '%s_png' % js_class
end
|
.png_path ⇒ Object
28
29
30
|
# File 'lib/ewigkeks.rb', line 28
def png_path
'/%s/%s' % [scope, 'png']
end
|
.scope ⇒ Object
20
21
22
|
# File 'lib/ewigkeks.rb', line 20
def scope
@@scope ||= 'ewigkeks'
end
|
.scope=(scope) ⇒ Object
24
25
26
|
# File 'lib/ewigkeks.rb', line 24
def scope=(scope)
@@scope = scope.sub(/\A\/*/, '')
end
|