cachetastic 1.2.3 → 1.2.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README +3 -7
- data/bin/cachetastic_drb_server +18 -3
- data/lib/adapters/cachetastic_adapters_base.rb +2 -1
- data/lib/adapters/cachetastic_adapters_drb.rb +4 -18
- data/lib/adapters/cachetastic_adapters_file.rb +0 -3
- data/lib/adapters/cachetastic_adapters_html_file.rb +119 -0
- data/lib/caches/cachetastic_caches_base.rb +24 -18
- data/lib/caches/cachetastic_caches_mack_session_cache.rb +3 -0
- data/lib/cachetastic.rb +2 -0
- data/lib/cachetastic_logger.rb +1 -1
- data/lib/tasks/rubyforge_config.yml +1 -1
- metadata +13 -111
- data/doc/classes/ActiveRecord/Base.html +0 -227
- data/doc/classes/ActiveRecord/Base.src/M000001.html +0 -25
- data/doc/classes/ActiveRecord/Base.src/M000002.html +0 -18
- data/doc/classes/ActiveRecord/Base.src/M000003.html +0 -18
- data/doc/classes/ActiveRecord/Base.src/M000004.html +0 -18
- data/doc/classes/ActiveRecord/Base.src/M000005.html +0 -18
- data/doc/classes/CGI/Session/CachetasticStore.html +0 -122
- data/doc/classes/Cachetastic/Adapters/Base.html +0 -260
- data/doc/classes/Cachetastic/Adapters/Base.src/M000024.html +0 -24
- data/doc/classes/Cachetastic/Adapters/Base.src/M000025.html +0 -20
- data/doc/classes/Cachetastic/Adapters/Base.src/M000026.html +0 -21
- data/doc/classes/Cachetastic/Adapters/Drb.html +0 -244
- data/doc/classes/Cachetastic/Adapters/Drb.src/M000027.html +0 -22
- data/doc/classes/Cachetastic/Adapters/Drb.src/M000028.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Drb.src/M000029.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Drb.src/M000030.html +0 -26
- data/doc/classes/Cachetastic/Adapters/Drb.src/M000031.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Drb.src/M000032.html +0 -25
- data/doc/classes/Cachetastic/Adapters/File.html +0 -265
- data/doc/classes/Cachetastic/Adapters/File.src/M000033.html +0 -18
- data/doc/classes/Cachetastic/Adapters/File.src/M000034.html +0 -20
- data/doc/classes/Cachetastic/Adapters/File.src/M000035.html +0 -19
- data/doc/classes/Cachetastic/Adapters/File.src/M000036.html +0 -35
- data/doc/classes/Cachetastic/Adapters/File.src/M000037.html +0 -21
- data/doc/classes/Cachetastic/Adapters/File.src/M000038.html +0 -25
- data/doc/classes/Cachetastic/Adapters/LocalMemory.html +0 -238
- data/doc/classes/Cachetastic/Adapters/LocalMemory.src/M000018.html +0 -18
- data/doc/classes/Cachetastic/Adapters/LocalMemory.src/M000019.html +0 -18
- data/doc/classes/Cachetastic/Adapters/LocalMemory.src/M000020.html +0 -18
- data/doc/classes/Cachetastic/Adapters/LocalMemory.src/M000021.html +0 -26
- data/doc/classes/Cachetastic/Adapters/LocalMemory.src/M000022.html +0 -18
- data/doc/classes/Cachetastic/Adapters/LocalMemory.src/M000023.html +0 -25
- data/doc/classes/Cachetastic/Adapters/Memcache.html +0 -335
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000007.html +0 -19
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000008.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000009.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000010.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000011.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000012.html +0 -18
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000013.html +0 -24
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000014.html +0 -19
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000015.html +0 -20
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000016.html +0 -20
- data/doc/classes/Cachetastic/Adapters/Memcache.src/M000017.html +0 -24
- data/doc/classes/Cachetastic/Caches/Base.html +0 -441
- data/doc/classes/Cachetastic/Caches/Base.src/M000040.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000041.html +0 -43
- data/doc/classes/Cachetastic/Caches/Base.src/M000042.html +0 -23
- data/doc/classes/Cachetastic/Caches/Base.src/M000043.html +0 -20
- data/doc/classes/Cachetastic/Caches/Base.src/M000044.html +0 -19
- data/doc/classes/Cachetastic/Caches/Base.src/M000045.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000046.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000047.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000048.html +0 -23
- data/doc/classes/Cachetastic/Caches/Base.src/M000049.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000050.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000051.html +0 -18
- data/doc/classes/Cachetastic/Caches/Base.src/M000052.html +0 -28
- data/doc/classes/Cachetastic/Caches/Base/RegisteredCaches.html +0 -168
- data/doc/classes/Cachetastic/Caches/Base/RegisteredCaches.src/M000053.html +0 -18
- data/doc/classes/Cachetastic/Caches/PageCache.html +0 -121
- data/doc/classes/Cachetastic/Caches/RailsSessionCache.html +0 -145
- data/doc/classes/Cachetastic/Caches/RailsSessionCache.src/M000039.html +0 -18
- data/doc/classes/Cachetastic/Connection.html +0 -186
- data/doc/classes/Cachetastic/Connection.src/M000054.html +0 -18
- data/doc/classes/Cachetastic/Connection.src/M000055.html +0 -24
- data/doc/classes/Cachetastic/Errors/UnsupportedAdapter.html +0 -137
- data/doc/classes/Cachetastic/Errors/UnsupportedAdapter.src/M000006.html +0 -18
- data/doc/classes/Cachetastic/Logger.html +0 -174
- data/doc/classes/Cachetastic/Logger.src/M000056.html +0 -22
- data/doc/created.rid +0 -1
- data/doc/files/init_rb.html +0 -227
- data/doc/files/lib/adapters/cachetastic_adapters_base_rb.html +0 -139
- data/doc/files/lib/adapters/cachetastic_adapters_drb_rb.html +0 -115
- data/doc/files/lib/adapters/cachetastic_adapters_file_rb.html +0 -121
- data/doc/files/lib/adapters/cachetastic_adapters_local_memory_rb.html +0 -109
- data/doc/files/lib/adapters/cachetastic_adapters_memcache_rb.html +0 -127
- data/doc/files/lib/adapters/cachetastic_adapters_store_object_rb.html +0 -101
- data/doc/files/lib/caches/cachetastic_caches_base_rb.html +0 -108
- data/doc/files/lib/caches/cachetastic_caches_page_cache_rb.html +0 -109
- data/doc/files/lib/caches/cachetastic_caches_rails_session_cache_rb.html +0 -107
- data/doc/files/lib/cachetastic_connection_rb.html +0 -107
- data/doc/files/lib/cachetastic_logger_rb.html +0 -107
- data/doc/files/lib/cachetastic_rb.html +0 -255
- data/doc/files/lib/errors/cachetastic_errors_unsupported_adapter_rb.html +0 -101
- data/doc/files/lib/helpers/cachetastic_helpers_active_record_rb.html +0 -101
- data/doc/files/lib/rails_extensions/cachetastic_active_record_base_rb.html +0 -101
- data/doc/files/lib/rails_extensions/cgi_session_cachetastic_store_rb.html +0 -109
- data/doc/fr_class_index.html +0 -40
- data/doc/fr_file_index.html +0 -43
- data/doc/fr_method_index.html +0 -82
- data/doc/index.html +0 -24
- data/doc/rdoc-style.css +0 -208
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>all_registered_caches (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 48</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">all_registered_caches</span>
|
|
15
|
-
<span class="ruby-constant">RegisteredCaches</span>.<span class="ruby-identifier">instance</span>.<span class="ruby-identifier">list</span>
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>get (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 58</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">get</span>(<span class="ruby-identifier">key</span>)
|
|
15
|
-
<span class="ruby-identifier">res</span> = <span class="ruby-keyword kw">nil</span>
|
|
16
|
-
<span class="ruby-identifier">do_with_logging</span>(<span class="ruby-identifier">:get</span>, <span class="ruby-identifier">key</span>) <span class="ruby-keyword kw">do</span>
|
|
17
|
-
<span class="ruby-identifier">retryable</span>(<span class="ruby-identifier">:on</span> =<span class="ruby-operator">></span> <span class="ruby-constant">ArgumentError</span>) <span class="ruby-keyword kw">do</span>
|
|
18
|
-
<span class="ruby-keyword kw">begin</span>
|
|
19
|
-
<span class="ruby-identifier">res</span> = <span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">get</span>(<span class="ruby-identifier">key</span>.<span class="ruby-identifier">to_s</span>)
|
|
20
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">res</span>.<span class="ruby-identifier">nil?</span>
|
|
21
|
-
<span class="ruby-identifier">res</span> = <span class="ruby-keyword kw">yield</span> <span class="ruby-identifier">key</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block_given?</span>
|
|
22
|
-
<span class="ruby-keyword kw">else</span>
|
|
23
|
-
<span class="ruby-identifier">res</span> = <span class="ruby-identifier">unmarshall</span>(<span class="ruby-identifier">res</span>)
|
|
24
|
-
<span class="ruby-keyword kw">end</span>
|
|
25
|
-
<span class="ruby-identifier">res</span>
|
|
26
|
-
<span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">ArgumentError</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">e</span>
|
|
27
|
-
<span class="ruby-identifier">m</span> = <span class="ruby-identifier">e</span>.<span class="ruby-identifier">message</span>.<span class="ruby-identifier">match</span>(<span class="ruby-regexp re">/class\/module .*/</span>)
|
|
28
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">m</span>
|
|
29
|
-
<span class="ruby-identifier">m</span> = <span class="ruby-identifier">m</span>.<span class="ruby-identifier">to_s</span>
|
|
30
|
-
<span class="ruby-identifier">m</span>.<span class="ruby-identifier">gsub!</span>(<span class="ruby-value str">"class/module"</span>, <span class="ruby-value str">''</span>)
|
|
31
|
-
<span class="ruby-identifier">m</span>.<span class="ruby-identifier">gsub!</span>(<span class="ruby-value str">"(ArgumentError)"</span>, <span class="ruby-value str">''</span>)
|
|
32
|
-
<span class="ruby-identifier">require</span> <span class="ruby-identifier">m</span>.<span class="ruby-identifier">strip</span>.<span class="ruby-identifier">underscore</span>
|
|
33
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-identifier">e</span>
|
|
34
|
-
<span class="ruby-keyword kw">end</span>
|
|
35
|
-
<span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">Exception</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">e</span>
|
|
36
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-identifier">e</span>
|
|
37
|
-
<span class="ruby-keyword kw">end</span>
|
|
38
|
-
<span class="ruby-keyword kw">end</span>
|
|
39
|
-
<span class="ruby-keyword kw">end</span>
|
|
40
|
-
<span class="ruby-identifier">res</span>
|
|
41
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
42
|
-
</body>
|
|
43
|
-
</html>
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>set (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 94</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set</span>(<span class="ruby-identifier">key</span>, <span class="ruby-identifier">value</span>, <span class="ruby-identifier">expiry</span> = (<span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">all_options</span>[<span class="ruby-value str">"default_expiry"</span>] <span class="ruby-operator">||</span> <span class="ruby-value">0</span>))
|
|
15
|
-
<span class="ruby-identifier">do_with_logging</span>(<span class="ruby-identifier">:set</span>, <span class="ruby-identifier">key</span>) <span class="ruby-keyword kw">do</span>
|
|
16
|
-
<span class="ruby-identifier">expiry</span> = <span class="ruby-identifier">calculate_expiry_time</span>(<span class="ruby-identifier">expiry</span>)
|
|
17
|
-
<span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">set</span>(<span class="ruby-identifier">key</span>.<span class="ruby-identifier">to_s</span>, <span class="ruby-identifier">marshall</span>(<span class="ruby-identifier">value</span>), <span class="ruby-identifier">expiry</span>.<span class="ruby-identifier">to_i</span>)
|
|
18
|
-
<span class="ruby-identifier">logger</span>.<span class="ruby-identifier">info</span>(<span class="ruby-value str">''</span>, <span class="ruby-value str">''</span>, <span class="ruby-identifier">:expiry</span>, <span class="ruby-identifier">cache_name</span>, <span class="ruby-identifier">key</span>, <span class="ruby-identifier">expiry</span>.<span class="ruby-identifier">to_i</span>)
|
|
19
|
-
<span class="ruby-identifier">value</span>
|
|
20
|
-
<span class="ruby-keyword kw">end</span>
|
|
21
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
22
|
-
</body>
|
|
23
|
-
</html>
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>delete (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 108</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">delete</span>(<span class="ruby-identifier">key</span>, <span class="ruby-identifier">delay</span> = <span class="ruby-value">0</span>)
|
|
15
|
-
<span class="ruby-identifier">do_with_logging</span>(<span class="ruby-identifier">:delete</span>, <span class="ruby-identifier">key</span>) <span class="ruby-keyword kw">do</span>
|
|
16
|
-
<span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">delete</span>(<span class="ruby-identifier">key</span>.<span class="ruby-identifier">to_s</span>, <span class="ruby-identifier">delay</span>)
|
|
17
|
-
<span class="ruby-keyword kw">end</span>
|
|
18
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
19
|
-
</body>
|
|
20
|
-
</html>
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>expire_all (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 115</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">expire_all</span>
|
|
15
|
-
<span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">expire_all</span>
|
|
16
|
-
<span class="ruby-identifier">logger</span>.<span class="ruby-identifier">info</span>(<span class="ruby-value str">''</span>, <span class="ruby-value str">''</span>, <span class="ruby-identifier">:expired</span>, <span class="ruby-identifier">cache_name</span>)
|
|
17
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
18
|
-
</body>
|
|
19
|
-
</html>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>populate_all (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 123</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">populate_all</span>
|
|
15
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">MethodNotImplemented</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">"populate_all"</span>)
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>stats (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 128</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">stats</span>
|
|
15
|
-
<span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">stats</span>
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>cache_name (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 136</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">cache_name</span>
|
|
15
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">name</span>.<span class="ruby-identifier">methodize</span>
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>adapter (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 141</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">adapter</span>
|
|
15
|
-
<span class="ruby-identifier">a</span> = <span class="ruby-identifier">cache_conn_instance</span>.<span class="ruby-identifier">get</span>(<span class="ruby-identifier">cache_name</span>)
|
|
16
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">adapter_supported?</span>(<span class="ruby-identifier">a</span>.<span class="ruby-identifier">class</span>)
|
|
17
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">a</span>
|
|
18
|
-
<span class="ruby-keyword kw">else</span>
|
|
19
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">Cachetastic</span><span class="ruby-operator">::</span><span class="ruby-constant">Errors</span><span class="ruby-operator">::</span><span class="ruby-constant">UnsupportedAdapter</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">cache_name</span>, <span class="ruby-identifier">a</span>.<span class="ruby-identifier">class</span>)
|
|
20
|
-
<span class="ruby-keyword kw">end</span>
|
|
21
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
22
|
-
</body>
|
|
23
|
-
</html>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>logger (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 151</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">logger</span>
|
|
15
|
-
<span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">logger</span>
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>unsupported_adapters (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 158</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">unsupported_adapters</span>
|
|
15
|
-
[]
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>adapter_supported? (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 163</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">adapter_supported?</span>(<span class="ruby-identifier">a</span> = <span class="ruby-identifier">cache_conn_instance</span>.<span class="ruby-identifier">get</span>(<span class="ruby-identifier">cache_name</span>).<span class="ruby-identifier">class</span>)
|
|
15
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-operator">!</span><span class="ruby-identifier">unsupported_adapters</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">a</span>)
|
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
17
|
-
</body>
|
|
18
|
-
</html>
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html>
|
|
7
|
-
<head>
|
|
8
|
-
<title>calculate_expiry_time (Cachetastic::Caches::Base)</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
11
|
-
</head>
|
|
12
|
-
<body class="standalone-code">
|
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/caches/cachetastic_caches_base.rb, line 170</span>
|
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">calculate_expiry_time</span>(<span class="ruby-identifier">expiry</span>) <span class="ruby-comment cmt"># :doc:</span>
|
|
15
|
-
<span class="ruby-identifier">exp_swing</span> = <span class="ruby-identifier">adapter</span>.<span class="ruby-identifier">all_options</span>[<span class="ruby-value str">"expiry_swing"</span>]
|
|
16
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">exp_swing</span>
|
|
17
|
-
<span class="ruby-identifier">swing</span> = <span class="ruby-identifier">rand</span>(<span class="ruby-identifier">exp_swing</span>.<span class="ruby-identifier">to_i</span>)
|
|
18
|
-
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">rand</span>(<span class="ruby-value">2</span>)
|
|
19
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value">0</span>
|
|
20
|
-
<span class="ruby-identifier">expiry</span> = (<span class="ruby-identifier">expiry</span>.<span class="ruby-identifier">to_i</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">swing</span>)
|
|
21
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value">1</span>
|
|
22
|
-
<span class="ruby-identifier">expiry</span> = (<span class="ruby-identifier">expiry</span>.<span class="ruby-identifier">to_i</span> <span class="ruby-operator">-</span> <span class="ruby-identifier">swing</span>)
|
|
23
|
-
<span class="ruby-keyword kw">end</span>
|
|
24
|
-
<span class="ruby-keyword kw">end</span>
|
|
25
|
-
<span class="ruby-identifier">expiry</span>
|
|
26
|
-
<span class="ruby-keyword kw">end</span></pre>
|
|
27
|
-
</body>
|
|
28
|
-
</html>
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
2
|
-
<!DOCTYPE html
|
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
5
|
-
|
|
6
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
7
|
-
<head>
|
|
8
|
-
<title>Class: Cachetastic::Caches::Base::RegisteredCaches</title>
|
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
|
10
|
-
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
|
11
|
-
<link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
|
|
12
|
-
<script type="text/javascript">
|
|
13
|
-
// <![CDATA[
|
|
14
|
-
|
|
15
|
-
function popupCode( url ) {
|
|
16
|
-
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
function toggleCode( id ) {
|
|
20
|
-
if ( document.getElementById )
|
|
21
|
-
elem = document.getElementById( id );
|
|
22
|
-
else if ( document.all )
|
|
23
|
-
elem = eval( "document.all." + id );
|
|
24
|
-
else
|
|
25
|
-
return false;
|
|
26
|
-
|
|
27
|
-
elemStyle = elem.style;
|
|
28
|
-
|
|
29
|
-
if ( elemStyle.display != "block" ) {
|
|
30
|
-
elemStyle.display = "block"
|
|
31
|
-
} else {
|
|
32
|
-
elemStyle.display = "none"
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
return true;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
// Make codeblocks hidden by default
|
|
39
|
-
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
|
40
|
-
|
|
41
|
-
// ]]>
|
|
42
|
-
</script>
|
|
43
|
-
|
|
44
|
-
</head>
|
|
45
|
-
<body>
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
<div id="classHeader">
|
|
50
|
-
<table class="header-table">
|
|
51
|
-
<tr class="top-aligned-row">
|
|
52
|
-
<td><strong>Class</strong></td>
|
|
53
|
-
<td class="class-name-in-header">Cachetastic::Caches::Base::RegisteredCaches</td>
|
|
54
|
-
</tr>
|
|
55
|
-
<tr class="top-aligned-row">
|
|
56
|
-
<td><strong>In:</strong></td>
|
|
57
|
-
<td>
|
|
58
|
-
<a href="../../../../files/lib/caches/cachetastic_caches_base_rb.html">
|
|
59
|
-
lib/caches/cachetastic_caches_base.rb
|
|
60
|
-
</a>
|
|
61
|
-
<br />
|
|
62
|
-
</td>
|
|
63
|
-
</tr>
|
|
64
|
-
|
|
65
|
-
<tr class="top-aligned-row">
|
|
66
|
-
<td><strong>Parent:</strong></td>
|
|
67
|
-
<td>
|
|
68
|
-
Object
|
|
69
|
-
</td>
|
|
70
|
-
</tr>
|
|
71
|
-
</table>
|
|
72
|
-
</div>
|
|
73
|
-
<!-- banner header -->
|
|
74
|
-
|
|
75
|
-
<div id="bodyContent">
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
<div id="contextContent">
|
|
80
|
-
|
|
81
|
-
<div id="description">
|
|
82
|
-
<p>
|
|
83
|
-
Used to store a list of all the caches registered with the system. In order
|
|
84
|
-
for a cache to be registered it must extend <a
|
|
85
|
-
href="../Base.html">Cachetastic::Caches::Base</a>.
|
|
86
|
-
</p>
|
|
87
|
-
|
|
88
|
-
</div>
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
</div>
|
|
92
|
-
|
|
93
|
-
<div id="method-list">
|
|
94
|
-
<h3 class="section-bar">Methods</h3>
|
|
95
|
-
|
|
96
|
-
<div class="name-list">
|
|
97
|
-
<a href="#M000053">new</a>
|
|
98
|
-
</div>
|
|
99
|
-
</div>
|
|
100
|
-
|
|
101
|
-
</div>
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
<!-- if includes -->
|
|
105
|
-
<div id="includes">
|
|
106
|
-
<h3 class="section-bar">Included Modules</h3>
|
|
107
|
-
|
|
108
|
-
<div id="includes-list">
|
|
109
|
-
<span class="include-name">Singleton</span>
|
|
110
|
-
</div>
|
|
111
|
-
</div>
|
|
112
|
-
|
|
113
|
-
<div id="section">
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
<div id="attribute-list">
|
|
120
|
-
<h3 class="section-bar">Attributes</h3>
|
|
121
|
-
|
|
122
|
-
<div class="name-list">
|
|
123
|
-
<table>
|
|
124
|
-
<tr class="top-aligned-row context-row">
|
|
125
|
-
<td class="context-item-name">list</td>
|
|
126
|
-
<td class="context-item-value"> [R] </td>
|
|
127
|
-
<td class="context-item-desc">
|
|
128
|
-
list of all caches registered with the system.
|
|
129
|
-
|
|
130
|
-
</td>
|
|
131
|
-
</tr>
|
|
132
|
-
</table>
|
|
133
|
-
</div>
|
|
134
|
-
</div>
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
<!-- if method_list -->
|
|
139
|
-
<div id="methods">
|
|
140
|
-
<h3 class="section-bar">Public Class methods</h3>
|
|
141
|
-
|
|
142
|
-
<div id="method-M000053" class="method-detail">
|
|
143
|
-
<a name="M000053"></a>
|
|
144
|
-
|
|
145
|
-
<div class="method-heading">
|
|
146
|
-
<a href="RegisteredCaches.src/M000053.html" target="Code" class="method-signature"
|
|
147
|
-
onclick="popupCode('RegisteredCaches.src/M000053.html');return false;">
|
|
148
|
-
<span class="method-name">new</span><span class="method-args">()</span>
|
|
149
|
-
</a>
|
|
150
|
-
</div>
|
|
151
|
-
|
|
152
|
-
<div class="method-description">
|
|
153
|
-
</div>
|
|
154
|
-
</div>
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
</div>
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
</div>
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
<div id="validator-badges">
|
|
164
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
|
165
|
-
</div>
|
|
166
|
-
|
|
167
|
-
</body>
|
|
168
|
-
</html>
|