Class: Rtlog::IndexPage
- Inherits:
-
Page
- Object
- Page
- Rtlog::IndexPage
show all
- Defined in:
- lib/rtlog/pages.rb
Instance Attribute Summary
Attributes inherited from Page
#config, #log, #logger
Instance Method Summary
collapse
Methods inherited from Page
#config_dir, #generate, #index_url, #initialize, #month_pages, #parse, #size, #template_file_name, #template_path
Constructor Details
This class inherits a constructor from Rtlog::Page
Instance Method Details
#file_path ⇒ Object
97
98
99
|
# File 'lib/rtlog/pages.rb', line 97
def file_path
File.expand_path( File.join(config['target_dir'], 'index.html') )
end
|
#page_name ⇒ Object
105
106
107
|
# File 'lib/rtlog/pages.rb', line 105
def page_name
'index'
end
|
#recent_day_pages(size) ⇒ Object
109
110
111
112
113
114
115
|
# File 'lib/rtlog/pages.rb', line 109
def recent_day_pages size
recent_day_pages = []
log.recent_day_entries(size).each do |d|
recent_day_pages << DayPage.new( config, log, d )
end
recent_day_pages
end
|
#title ⇒ Object
93
94
95
|
# File 'lib/rtlog/pages.rb', line 93
def title
'Index'
end
|
#url ⇒ Object
101
102
103
|
# File 'lib/rtlog/pages.rb', line 101
def url
config['url_prefix']
end
|