hobix 0.4 → 0.6
Sign up to get free protection for your applications and to get access to all the features.
- data/COPYING +18 -0
- data/README +18 -0
- data/Rakefile +96 -0
- data/bin/hobix +7 -3
- data/contrib/blosxom-to-hobix.rb +253 -0
- data/contrib/txp-to-hobix.rb +56 -0
- data/contrib/webrick-all-mine.rb +20 -0
- data/doc/CHANGELOG +285 -0
- data/doc/rdoc/classes/Hobix/API.html +382 -0
- data/doc/rdoc/classes/Hobix/Article.html +111 -0
- data/doc/rdoc/classes/Hobix/BaseContent.html +692 -0
- data/doc/rdoc/classes/Hobix/BaseEntry.html +218 -0
- data/doc/rdoc/classes/Hobix/BaseFacet.html +205 -0
- data/doc/rdoc/classes/Hobix/BaseOutput.html +122 -0
- data/doc/rdoc/classes/Hobix/BasePlugin.html +201 -0
- data/doc/rdoc/classes/Hobix/BaseProperties/ClassMethods.html +243 -0
- data/doc/rdoc/classes/Hobix/BaseProperties.html +218 -0
- data/doc/rdoc/classes/Hobix/BasePublish.html +157 -0
- data/doc/rdoc/classes/Hobix/BaseStorage.html +417 -0
- data/doc/rdoc/classes/Hobix/BixWik/Entry.html +196 -0
- data/doc/rdoc/classes/Hobix/BixWik/IndexEntry.html +170 -0
- data/doc/rdoc/classes/Hobix/BixWik/WikiRedCloth.html +111 -0
- data/doc/rdoc/classes/Hobix/BixWik.html +418 -0
- data/doc/rdoc/classes/Hobix/BixWikPlugin.html +158 -0
- data/doc/rdoc/classes/Hobix/CommandLine.html +1970 -0
- data/doc/rdoc/classes/Hobix/Comment.html +113 -0
- data/doc/rdoc/classes/Hobix/Config.html +212 -0
- data/doc/rdoc/classes/Hobix/DataMarsh.html +667 -0
- data/doc/rdoc/classes/Hobix/Entry.html +178 -0
- data/doc/rdoc/classes/Hobix/EntryEnum.html +162 -0
- data/doc/rdoc/classes/Hobix/Enumerable.html +170 -0
- data/doc/rdoc/classes/Hobix/Facets/WikiEdit.html +180 -0
- data/doc/rdoc/classes/Hobix/Facets.html +111 -0
- data/doc/rdoc/classes/Hobix/LinkList.html +182 -0
- data/doc/rdoc/classes/Hobix/Out/Quick.html +412 -0
- data/doc/rdoc/classes/Hobix/Out.html +119 -0
- data/doc/rdoc/classes/Hobix/Page.html +381 -0
- data/doc/rdoc/classes/Hobix/Trackback.html +113 -0
- data/doc/rdoc/classes/Hobix/UriStr.html +198 -0
- data/doc/rdoc/classes/Hobix/WebApp/QueryString.html +207 -0
- data/doc/rdoc/classes/Hobix/WebApp/QueryValidationFailure.html +111 -0
- data/doc/rdoc/classes/Hobix/WebApp.html +1383 -0
- data/doc/rdoc/classes/Hobix/Weblog/AuthorNotFound.html +111 -0
- data/doc/rdoc/classes/Hobix/Weblog.html +2082 -0
- data/doc/rdoc/classes/Hobix.html +399 -0
- data/doc/rdoc/classes/Kernel.html +139 -0
- data/doc/rdoc/classes/Regexp.html +154 -0
- data/doc/rdoc/classes/YAML/Omap.html +144 -0
- data/doc/rdoc/classes/YAML.html +111 -0
- data/doc/rdoc/created.rid +1 -0
- data/doc/rdoc/files/COPYING.html +129 -0
- data/doc/rdoc/files/README.html +131 -0
- data/doc/rdoc/files/doc/CHANGELOG.html +101 -0
- data/doc/rdoc/files/lib/hobix/api_rb.html +119 -0
- data/doc/rdoc/files/lib/hobix/article_rb.html +126 -0
- data/doc/rdoc/files/lib/hobix/base_rb.html +128 -0
- data/doc/rdoc/files/lib/hobix/bixwik_rb.html +126 -0
- data/doc/rdoc/files/lib/hobix/commandline_rb.html +140 -0
- data/doc/rdoc/files/lib/hobix/comments_rb.html +126 -0
- data/doc/rdoc/files/lib/hobix/config_rb.html +125 -0
- data/doc/rdoc/files/lib/hobix/datamarsh_rb.html +108 -0
- data/doc/rdoc/files/lib/hobix/entry_rb.html +118 -0
- data/doc/rdoc/files/lib/hobix/linklist_rb.html +127 -0
- data/doc/rdoc/files/lib/hobix/publisher_rb.html +126 -0
- data/doc/rdoc/files/lib/hobix/trackbacks_rb.html +128 -0
- data/doc/rdoc/files/lib/hobix/webapp_rb.html +127 -0
- data/doc/rdoc/files/lib/hobix/weblog_rb.html +135 -0
- data/doc/rdoc/files/lib/hobix_rb.html +127 -0
- data/doc/rdoc/fr_class_index.html +67 -0
- data/doc/rdoc/fr_file_index.html +44 -0
- data/doc/rdoc/fr_method_index.html +307 -0
- data/doc/rdoc/index.html +24 -0
- data/doc/rdoc/rdoc-style.css +208 -0
- data/git_hobix_update.php +13 -0
- data/lib/hobix/base.rb +6 -3
- data/lib/hobix/bixwik.rb +12 -12
- data/lib/hobix/commandline.rb +18 -2
- data/lib/hobix/comments.rb +4 -5
- data/lib/hobix/entry.rb +2 -1
- data/lib/hobix/facets/comments.rb +31 -6
- data/lib/hobix/linklist.rb +6 -1
- data/lib/hobix/out/atom.rb +29 -20
- data/lib/hobix/out/quick.rb +8 -6
- data/lib/hobix/out/rss.rb +16 -3
- data/lib/hobix/plugin/akismet.rb +196 -0
- data/lib/hobix/plugin/calendar.rb +6 -14
- data/lib/hobix/plugin/recent_comments.rb +4 -2
- data/lib/hobix/plugin/tags.rb +1 -1
- data/lib/hobix/storage/filesys.rb +41 -31
- data/lib/hobix/trackbacks.rb +1 -2
- data/lib/hobix/weblog.rb +73 -40
- data/lib/hobix.rb +9 -2
- data/share/default-blog/hobix.yaml +16 -0
- data/share/default-blog/htdocs/site.css +174 -0
- data/share/default-blog/skel/entry.html.quick +0 -0
- data/share/default-blog/skel/index.atom.atom +0 -0
- data/share/default-blog/skel/index.html.quick-summary +0 -0
- data/share/default-blog/skel/index.xml.rss +0 -0
- data/share/default-blog/skel/index.yaml.okaynews +0 -0
- data/share/default-blog/skel/monthly.html.quick-archive +0 -0
- data/share/default-blog/skel/section.html.quick-archive +0 -0
- data/share/default-blog/skel/yearly.html.quick-archive +0 -0
- data/share/default-blog-modes.yaml +7 -0
- data/share/default-blog.apache-cgi.patch +8 -0
- data/share/default-blog.apache-ssi.patch +38 -0
- data/share/default-blog.apache2-ssi.patch +3 -0
- data/share/default-blog.cgi.patch +8 -0
- data/share/default-blog.comments.patch +5 -0
- data/share/default-blog.prototype.patch +766 -0
- data/share/default-blog.publisher.patch +5 -0
- data/share/default-blog.wiki.patch +29 -0
- data/share/publisher/css/control.css +90 -0
- data/share/publisher/css/form.css +238 -0
- data/share/publisher/css/form.import.css +72 -0
- data/share/publisher/css/main-menu.css +134 -0
- data/share/publisher/i/hobix-emblazen-1.png +0 -0
- data/share/publisher/i/hobix-emblazen-2.png +0 -0
- data/share/publisher/i/hobix-emblazen-3.png +0 -0
- data/share/publisher/i/hobix-emblazen-4.png +0 -0
- data/share/publisher/i/hobix-emblazen-5.png +0 -0
- data/share/publisher/i/hobix-emblazen-6.png +0 -0
- data/share/publisher/i/hobix-emblazen-7.png +0 -0
- data/share/publisher/index.erb +66 -0
- data/share/publisher/js/controls.js +261 -0
- data/share/publisher/js/dragdrop.js +476 -0
- data/share/publisher/js/effects.js +570 -0
- data/share/publisher/js/prototype.js +1011 -0
- metadata +196 -53
- checksums.yaml +0 -7
@@ -0,0 +1,157 @@
|
|
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: Hobix::BasePublish</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">Hobix::BasePublish</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../../files/lib/hobix/base_rb.html">
|
59
|
+
lib/hobix/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
|
+
<a href="BasePlugin.html">
|
69
|
+
BasePlugin
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
<div id="description">
|
84
|
+
<p>
|
85
|
+
The <a href="BasePublish.html">BasePublish</a> plugin is the underlying
|
86
|
+
class for all publishing plugins, which are notified of updates to pages.
|
87
|
+
</p>
|
88
|
+
<p>
|
89
|
+
Publish plugins are executed after generation of the site. The plugin may
|
90
|
+
choose to watch updates to certain types of pages. The plugin also receives
|
91
|
+
a list of all the pages which have been updated.
|
92
|
+
</p>
|
93
|
+
<p>
|
94
|
+
Generally, publish plugins fall into two categories:
|
95
|
+
</p>
|
96
|
+
<ul>
|
97
|
+
<li>Plugins which contact a service when certain updates happen. (<a
|
98
|
+
href="../Hobix.html">Hobix</a> includes an XML-RPC ping, which is triggered
|
99
|
+
whenever the front page is updated.)
|
100
|
+
|
101
|
+
</li>
|
102
|
+
<li>Plugins which transform <a href="../Hobix.html">Hobix</a> output. (<a
|
103
|
+
href="../Hobix.html">Hobix</a> includes a replication plugin, which copies
|
104
|
+
updated pages to a remote system via FTP or SFTP.)
|
105
|
+
|
106
|
+
</li>
|
107
|
+
</ul>
|
108
|
+
<h2>Publish methods</h2>
|
109
|
+
<table>
|
110
|
+
<tr><td valign="top">initialize( weblog, settings ):</td><td>Like all other plugins, the initialize method takes two parameters, a <a
|
111
|
+
href="Weblog.html">Hobix::Weblog</a> object for the weblog being published
|
112
|
+
and the settings data from the plugin‘s entry in hobix.yaml.
|
113
|
+
|
114
|
+
</td></tr>
|
115
|
+
<tr><td valign="top">watch:</td><td>(Optional) Returns an array of page types which, when published, activate
|
116
|
+
the plugin.
|
117
|
+
|
118
|
+
</td></tr>
|
119
|
+
<tr><td valign="top">publish( pages ):</td><td>If pages are published and the watch criteria qualifies this plugin, this
|
120
|
+
method is called with a hash of pages published. The key is the page type
|
121
|
+
and the value is an array of <a href="Page.html">Page</a> objects.
|
122
|
+
|
123
|
+
</td></tr>
|
124
|
+
</table>
|
125
|
+
|
126
|
+
</div>
|
127
|
+
|
128
|
+
|
129
|
+
</div>
|
130
|
+
|
131
|
+
|
132
|
+
</div>
|
133
|
+
|
134
|
+
|
135
|
+
<!-- if includes -->
|
136
|
+
|
137
|
+
<div id="section">
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
|
142
|
+
|
143
|
+
|
144
|
+
|
145
|
+
|
146
|
+
<!-- if method_list -->
|
147
|
+
|
148
|
+
|
149
|
+
</div>
|
150
|
+
|
151
|
+
|
152
|
+
<div id="validator-badges">
|
153
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
154
|
+
</div>
|
155
|
+
|
156
|
+
</body>
|
157
|
+
</html>
|
@@ -0,0 +1,417 @@
|
|
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: Hobix::BaseStorage</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">Hobix::BaseStorage</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../../files/lib/hobix/base_rb.html">
|
59
|
+
lib/hobix/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
|
+
<a href="BasePlugin.html">
|
69
|
+
BasePlugin
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
<div id="description">
|
84
|
+
<p>
|
85
|
+
The <a href="BaseStorage.html">BaseStorage</a> class outlines the
|
86
|
+
fundamental <a href="API.html">API</a> for <a
|
87
|
+
href="BaseStorage.html#M000120">all</a> storage plugins. Storage plugins
|
88
|
+
are responsible for abstracting away entry queries and managing the loading
|
89
|
+
of <a href="Entry.html">Entry</a> objects. The goal being: cache as much as
|
90
|
+
you can, be efficient and tidy.
|
91
|
+
</p>
|
92
|
+
<h2>Query Methods</h2>
|
93
|
+
<table>
|
94
|
+
<tr><td valign="top">find:</td><td>Each of the query methods below uses the <tt>find</tt> method to perform
|
95
|
+
its search. This method accepts a Hash of parameters. Please note that
|
96
|
+
calling <tt>find</tt> without parameters will return <a
|
97
|
+
href="BaseStorage.html#M000120">all</a> entries which qualify for placement
|
98
|
+
on the front page.
|
99
|
+
|
100
|
+
</td></tr>
|
101
|
+
<tr><td valign="top"><a href="BaseStorage.html#M000120">all</a>:</td><td>Returns <a href="BaseStorage.html#M000120">all</a> entries. Searches find(
|
102
|
+
:<a href="BaseStorage.html#M000120">all</a> => true )
|
103
|
+
|
104
|
+
</td></tr>
|
105
|
+
<tr><td valign="top"><a href="BaseStorage.html#M000121">lastn</a>:</td><td>Returns the last <em>n</em> entries which qualify for the front page.
|
106
|
+
|
107
|
+
</td></tr>
|
108
|
+
<tr><td valign="top"><a href="BaseStorage.html#M000122">inpath</a>:</td><td>Returns entries <a href="BaseStorage.html#M000126">within</a> a path which
|
109
|
+
qualify for the front page.
|
110
|
+
|
111
|
+
</td></tr>
|
112
|
+
<tr><td valign="top"><a href="BaseStorage.html#M000123">after</a>:</td><td>Returns entries created <a href="BaseStorage.html#M000123">after</a> a
|
113
|
+
given date.
|
114
|
+
|
115
|
+
</td></tr>
|
116
|
+
<tr><td valign="top"><a href="BaseStorage.html#M000124">before</a>:</td><td>Returns entries created <a href="BaseStorage.html#M000124">before</a> a
|
117
|
+
given date.
|
118
|
+
|
119
|
+
</td></tr>
|
120
|
+
<tr><td valign="top"><a href="BaseStorage.html#M000126">within</a>:</td><td>Returns entries created between a start and end date.
|
121
|
+
|
122
|
+
</td></tr>
|
123
|
+
</table>
|
124
|
+
|
125
|
+
</div>
|
126
|
+
|
127
|
+
|
128
|
+
</div>
|
129
|
+
|
130
|
+
<div id="method-list">
|
131
|
+
<h3 class="section-bar">Methods</h3>
|
132
|
+
|
133
|
+
<div class="name-list">
|
134
|
+
<a href="#M000123">after</a>
|
135
|
+
<a href="#M000120">all</a>
|
136
|
+
<a href="#M000124">before</a>
|
137
|
+
<a href="#M000119">default_entry</a>
|
138
|
+
<a href="#M000118">default_entry_id</a>
|
139
|
+
<a href="#M000122">inpath</a>
|
140
|
+
<a href="#M000121">lastn</a>
|
141
|
+
<a href="#M000125">match</a>
|
142
|
+
<a href="#M000117">new</a>
|
143
|
+
<a href="#M000126">within</a>
|
144
|
+
</div>
|
145
|
+
</div>
|
146
|
+
|
147
|
+
</div>
|
148
|
+
|
149
|
+
|
150
|
+
<!-- if includes -->
|
151
|
+
|
152
|
+
<div id="section">
|
153
|
+
|
154
|
+
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
<!-- if method_list -->
|
162
|
+
<div id="methods">
|
163
|
+
<h3 class="section-bar">Public Class methods</h3>
|
164
|
+
|
165
|
+
<div id="method-M000117" class="method-detail">
|
166
|
+
<a name="M000117"></a>
|
167
|
+
|
168
|
+
<div class="method-heading">
|
169
|
+
<a href="#M000117" class="method-signature">
|
170
|
+
<span class="method-name">new</span><span class="method-args">( weblog )</span>
|
171
|
+
</a>
|
172
|
+
</div>
|
173
|
+
|
174
|
+
<div class="method-description">
|
175
|
+
<p><a class="source-toggle" href="#"
|
176
|
+
onclick="toggleCode('M000117-source');return false;">[Source]</a></p>
|
177
|
+
<div class="method-source-code" id="M000117-source">
|
178
|
+
<pre>
|
179
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 87</span>
|
180
|
+
87: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>( <span class="ruby-identifier">weblog</span> )
|
181
|
+
88: <span class="ruby-ivar">@link</span> = <span class="ruby-identifier">weblog</span>.<span class="ruby-identifier">link</span>
|
182
|
+
89: <span class="ruby-keyword kw">end</span>
|
183
|
+
</pre>
|
184
|
+
</div>
|
185
|
+
</div>
|
186
|
+
</div>
|
187
|
+
|
188
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
189
|
+
|
190
|
+
<div id="method-M000123" class="method-detail">
|
191
|
+
<a name="M000123"></a>
|
192
|
+
|
193
|
+
<div class="method-heading">
|
194
|
+
<a href="#M000123" class="method-signature">
|
195
|
+
<span class="method-name">after</span><span class="method-args">( after, n = nil )</span>
|
196
|
+
</a>
|
197
|
+
</div>
|
198
|
+
|
199
|
+
<div class="method-description">
|
200
|
+
<p><a class="source-toggle" href="#"
|
201
|
+
onclick="toggleCode('M000123-source');return false;">[Source]</a></p>
|
202
|
+
<div class="method-source-code" id="M000123-source">
|
203
|
+
<pre>
|
204
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 113</span>
|
205
|
+
113: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">after</span>( <span class="ruby-identifier">after</span>, <span class="ruby-identifier">n</span> = <span class="ruby-keyword kw">nil</span> )
|
206
|
+
114: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:after</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">after</span>, <span class="ruby-identifier">:lastn</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">n</span> )
|
207
|
+
115: <span class="ruby-keyword kw">end</span>
|
208
|
+
</pre>
|
209
|
+
</div>
|
210
|
+
</div>
|
211
|
+
</div>
|
212
|
+
|
213
|
+
<div id="method-M000120" class="method-detail">
|
214
|
+
<a name="M000120"></a>
|
215
|
+
|
216
|
+
<div class="method-heading">
|
217
|
+
<a href="#M000120" class="method-signature">
|
218
|
+
<span class="method-name">all</span><span class="method-args">()</span>
|
219
|
+
</a>
|
220
|
+
</div>
|
221
|
+
|
222
|
+
<div class="method-description">
|
223
|
+
<p><a class="source-toggle" href="#"
|
224
|
+
onclick="toggleCode('M000120-source');return false;">[Source]</a></p>
|
225
|
+
<div class="method-source-code" id="M000120-source">
|
226
|
+
<pre>
|
227
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 104</span>
|
228
|
+
104: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">all</span>
|
229
|
+
105: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:all</span> =<span class="ruby-operator">></span> <span class="ruby-keyword kw">true</span> )
|
230
|
+
106: <span class="ruby-keyword kw">end</span>
|
231
|
+
</pre>
|
232
|
+
</div>
|
233
|
+
</div>
|
234
|
+
</div>
|
235
|
+
|
236
|
+
<div id="method-M000124" class="method-detail">
|
237
|
+
<a name="M000124"></a>
|
238
|
+
|
239
|
+
<div class="method-heading">
|
240
|
+
<a href="#M000124" class="method-signature">
|
241
|
+
<span class="method-name">before</span><span class="method-args">( before, n = nil )</span>
|
242
|
+
</a>
|
243
|
+
</div>
|
244
|
+
|
245
|
+
<div class="method-description">
|
246
|
+
<p><a class="source-toggle" href="#"
|
247
|
+
onclick="toggleCode('M000124-source');return false;">[Source]</a></p>
|
248
|
+
<div class="method-source-code" id="M000124-source">
|
249
|
+
<pre>
|
250
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 116</span>
|
251
|
+
116: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">before</span>( <span class="ruby-identifier">before</span>, <span class="ruby-identifier">n</span> = <span class="ruby-keyword kw">nil</span> )
|
252
|
+
117: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:before</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">before</span>, <span class="ruby-identifier">:lastn</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">n</span> )
|
253
|
+
118: <span class="ruby-keyword kw">end</span>
|
254
|
+
</pre>
|
255
|
+
</div>
|
256
|
+
</div>
|
257
|
+
</div>
|
258
|
+
|
259
|
+
<div id="method-M000119" class="method-detail">
|
260
|
+
<a name="M000119"></a>
|
261
|
+
|
262
|
+
<div class="method-heading">
|
263
|
+
<a href="#M000119" class="method-signature">
|
264
|
+
<span class="method-name">default_entry</span><span class="method-args">( author )</span>
|
265
|
+
</a>
|
266
|
+
</div>
|
267
|
+
|
268
|
+
<div class="method-description">
|
269
|
+
<p><a class="source-toggle" href="#"
|
270
|
+
onclick="toggleCode('M000119-source');return false;">[Source]</a></p>
|
271
|
+
<div class="method-source-code" id="M000119-source">
|
272
|
+
<pre>
|
273
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 91</span>
|
274
|
+
91: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">default_entry</span>( <span class="ruby-identifier">author</span> )
|
275
|
+
92: <span class="ruby-constant">Hobix</span><span class="ruby-operator">::</span><span class="ruby-constant">Entry</span>.<span class="ruby-identifier">new</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">e</span><span class="ruby-operator">|</span>
|
276
|
+
93: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">id</span> = <span class="ruby-identifier">default_entry_id</span>
|
277
|
+
94: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">link</span> = <span class="ruby-identifier">e</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">url_link</span> <span class="ruby-identifier">e</span>, <span class="ruby-ivar">@link</span>, <span class="ruby-value str">"html"</span>
|
278
|
+
95: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">created</span> = <span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>
|
279
|
+
96: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">modified</span> = <span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>
|
280
|
+
97: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">updated</span> = <span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>
|
281
|
+
98: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">title</span> = <span class="ruby-value str">"This Ghostly Message From the Slime Will Soon Vanish!"</span>
|
282
|
+
99: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">tagline</span> = <span class="ruby-value str">"A temporary message, a tingling sensation, Hobix is up!!"</span>
|
283
|
+
100: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">author</span> = <span class="ruby-identifier">author</span>
|
284
|
+
101: <span class="ruby-identifier">e</span>.<span class="ruby-identifier">content</span> = <span class="ruby-constant">Hobix</span><span class="ruby-operator">::</span><span class="ruby-constant">Entry</span>.<span class="ruby-identifier">text_processor</span>.<span class="ruby-identifier">new</span>( <span class="ruby-value str">"Welcome to Hobix! Once you make your first blog post, this entry will disappear. However, in the meantime, you can tweak the CSS of your blog until it suits your satisfaction and you have this bit of words to act as a place holder."</span> )
|
285
|
+
102: <span class="ruby-keyword kw">end</span>
|
286
|
+
103: <span class="ruby-keyword kw">end</span>
|
287
|
+
</pre>
|
288
|
+
</div>
|
289
|
+
</div>
|
290
|
+
</div>
|
291
|
+
|
292
|
+
<div id="method-M000118" class="method-detail">
|
293
|
+
<a name="M000118"></a>
|
294
|
+
|
295
|
+
<div class="method-heading">
|
296
|
+
<a href="#M000118" class="method-signature">
|
297
|
+
<span class="method-name">default_entry_id</span><span class="method-args">()</span>
|
298
|
+
</a>
|
299
|
+
</div>
|
300
|
+
|
301
|
+
<div class="method-description">
|
302
|
+
<p><a class="source-toggle" href="#"
|
303
|
+
onclick="toggleCode('M000118-source');return false;">[Source]</a></p>
|
304
|
+
<div class="method-source-code" id="M000118-source">
|
305
|
+
<pre>
|
306
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 90</span>
|
307
|
+
90: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">default_entry_id</span>; <span class="ruby-value str">"hobix-default-entry"</span>; <span class="ruby-keyword kw">end</span>
|
308
|
+
</pre>
|
309
|
+
</div>
|
310
|
+
</div>
|
311
|
+
</div>
|
312
|
+
|
313
|
+
<div id="method-M000122" class="method-detail">
|
314
|
+
<a name="M000122"></a>
|
315
|
+
|
316
|
+
<div class="method-heading">
|
317
|
+
<a href="#M000122" class="method-signature">
|
318
|
+
<span class="method-name">inpath</span><span class="method-args">( path, n = nil )</span>
|
319
|
+
</a>
|
320
|
+
</div>
|
321
|
+
|
322
|
+
<div class="method-description">
|
323
|
+
<p><a class="source-toggle" href="#"
|
324
|
+
onclick="toggleCode('M000122-source');return false;">[Source]</a></p>
|
325
|
+
<div class="method-source-code" id="M000122-source">
|
326
|
+
<pre>
|
327
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 110</span>
|
328
|
+
110: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">inpath</span>( <span class="ruby-identifier">path</span>, <span class="ruby-identifier">n</span> = <span class="ruby-keyword kw">nil</span> )
|
329
|
+
111: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:inpath</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">path</span>, <span class="ruby-identifier">:lastn</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">n</span> )
|
330
|
+
112: <span class="ruby-keyword kw">end</span>
|
331
|
+
</pre>
|
332
|
+
</div>
|
333
|
+
</div>
|
334
|
+
</div>
|
335
|
+
|
336
|
+
<div id="method-M000121" class="method-detail">
|
337
|
+
<a name="M000121"></a>
|
338
|
+
|
339
|
+
<div class="method-heading">
|
340
|
+
<a href="#M000121" class="method-signature">
|
341
|
+
<span class="method-name">lastn</span><span class="method-args">( n )</span>
|
342
|
+
</a>
|
343
|
+
</div>
|
344
|
+
|
345
|
+
<div class="method-description">
|
346
|
+
<p><a class="source-toggle" href="#"
|
347
|
+
onclick="toggleCode('M000121-source');return false;">[Source]</a></p>
|
348
|
+
<div class="method-source-code" id="M000121-source">
|
349
|
+
<pre>
|
350
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 107</span>
|
351
|
+
107: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">lastn</span>( <span class="ruby-identifier">n</span> )
|
352
|
+
108: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:lastn</span> =<span class="ruby-operator">></span> ( <span class="ruby-identifier">n</span> <span class="ruby-operator">||</span> <span class="ruby-value">10</span> ) )
|
353
|
+
109: <span class="ruby-keyword kw">end</span>
|
354
|
+
</pre>
|
355
|
+
</div>
|
356
|
+
</div>
|
357
|
+
</div>
|
358
|
+
|
359
|
+
<div id="method-M000125" class="method-detail">
|
360
|
+
<a name="M000125"></a>
|
361
|
+
|
362
|
+
<div class="method-heading">
|
363
|
+
<a href="#M000125" class="method-signature">
|
364
|
+
<span class="method-name">match</span><span class="method-args">( expr )</span>
|
365
|
+
</a>
|
366
|
+
</div>
|
367
|
+
|
368
|
+
<div class="method-description">
|
369
|
+
<p><a class="source-toggle" href="#"
|
370
|
+
onclick="toggleCode('M000125-source');return false;">[Source]</a></p>
|
371
|
+
<div class="method-source-code" id="M000125-source">
|
372
|
+
<pre>
|
373
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 119</span>
|
374
|
+
119: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">match</span>( <span class="ruby-identifier">expr</span> )
|
375
|
+
120: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:match</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">expr</span> )
|
376
|
+
121: <span class="ruby-keyword kw">end</span>
|
377
|
+
</pre>
|
378
|
+
</div>
|
379
|
+
</div>
|
380
|
+
</div>
|
381
|
+
|
382
|
+
<div id="method-M000126" class="method-detail">
|
383
|
+
<a name="M000126"></a>
|
384
|
+
|
385
|
+
<div class="method-heading">
|
386
|
+
<a href="#M000126" class="method-signature">
|
387
|
+
<span class="method-name">within</span><span class="method-args">( after, before )</span>
|
388
|
+
</a>
|
389
|
+
</div>
|
390
|
+
|
391
|
+
<div class="method-description">
|
392
|
+
<p><a class="source-toggle" href="#"
|
393
|
+
onclick="toggleCode('M000126-source');return false;">[Source]</a></p>
|
394
|
+
<div class="method-source-code" id="M000126-source">
|
395
|
+
<pre>
|
396
|
+
<span class="ruby-comment cmt"># File lib/hobix/base.rb, line 122</span>
|
397
|
+
122: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">within</span>( <span class="ruby-identifier">after</span>, <span class="ruby-identifier">before</span> )
|
398
|
+
123: <span class="ruby-identifier">find</span>( <span class="ruby-identifier">:after</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">after</span>, <span class="ruby-identifier">:before</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">before</span> )
|
399
|
+
124: <span class="ruby-keyword kw">end</span>
|
400
|
+
</pre>
|
401
|
+
</div>
|
402
|
+
</div>
|
403
|
+
</div>
|
404
|
+
|
405
|
+
|
406
|
+
</div>
|
407
|
+
|
408
|
+
|
409
|
+
</div>
|
410
|
+
|
411
|
+
|
412
|
+
<div id="validator-badges">
|
413
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
414
|
+
</div>
|
415
|
+
|
416
|
+
</body>
|
417
|
+
</html>
|