Skip to content
This repository
Browse code

Add documentation

  • Loading branch information...
commit c73fb6fc50b412a34fec32cff63e709576f33963 1 parent b1a25c7
Mike Burns authored September 26, 2012

Showing 1 changed file with 5 additions and 0 deletions. Show diff stats Hide diff stats

  1. 5  lib/high_voltage/page_finder.rb
5  lib/high_voltage/page_finder.rb
... ...
@@ -1,4 +1,6 @@
1 1
 module HighVoltage
  2
+  # A command for finding pages by id. This encapsulates the concepts of
  3
+  # mapping page names to file names.
2 4
   class PageFinder
3 5
     VALID_CHARACTERS = "a-zA-Z0-9~!@$%^&*()#`_+-=<>\"{}|[];',?".freeze
4 6
 
@@ -6,6 +8,8 @@ def initialize(page_id)
6 8
       @page_id = page_id
7 9
     end
8 10
 
  11
+    # Produce a template path to the page, in a format understood by
  12
+    # `render :template => find`
9 13
     def find
10 14
       "#{content_path}#{clean_path}"
11 15
     end
@@ -16,6 +20,7 @@ def content_path
16 20
 
17 21
     protected
18 22
 
  23
+    # The raw page id passed in by the user
19 24
     attr_reader :page_id
20 25
 
21 26
     private

0 notes on commit c73fb6f

Please sign in to comment.
Something went wrong with that request. Please try again.