summaryrefslogtreecommitdiff
path: root/lib/coderay
diff options
context:
space:
mode:
authormurphy <murphy@rubychan.de>2010-03-26 03:03:04 +0000
committermurphy <murphy@rubychan.de>2010-03-26 03:03:04 +0000
commit971e6861621518e49687e2521552067838401720 (patch)
treec8c91c1527c3e3d271178819b3f158ad60fb74ed /lib/coderay
parent5daa248eb972fb6c1a07fdf74999cb40a51451aa (diff)
downloadcoderay-971e6861621518e49687e2521552067838401720.tar.gz
Cleanup of JSON Scanner.
Diffstat (limited to 'lib/coderay')
-rw-r--r--lib/coderay/scanners/plaintext.rb11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/coderay/scanners/plaintext.rb b/lib/coderay/scanners/plaintext.rb
index f00aabb..b8db721 100644
--- a/lib/coderay/scanners/plaintext.rb
+++ b/lib/coderay/scanners/plaintext.rb
@@ -1,6 +1,11 @@
module CodeRay
module Scanners
-
+
+ # Scanner for plain text.
+ #
+ # Yields just one token of the kind :plain.
+ #
+ # Alias: +plain+
class Plaintext < Scanner
register_for :plaintext, :plain
@@ -8,7 +13,9 @@ module Scanners
include Streamable
- KINDS_NOT_LOC = [:plain]
+ KINDS_NOT_LOC = [:plain] # :nodoc:
+
+ protected
def scan_tokens tokens, options
tokens << [string, :plain]