class General::GSpecial
Represents a special character in a GTemplate
Author: Anshul Kharbanda Created: 7 - 29 - 2016
Constants
- REGEX
Regular expression that matches special partials
- REGEXES
Special regex information
- SPECIALS
Special character information
Public Class Methods
new(match, defaults={})
click to toggle source
Initializes the GSpecial
with the given match
Parameter: match - the match object of the GSpecial
Parameter: defaults - the hash of default data from the GTemplate
Calls superclass method
# File lib/gpartials/gspecial.rb, line 62 def initialize(match, defaults={}) super SPECIALS[match[:key].to_sym], {} @key = match[:key].to_sym end
Public Instance Methods
regex(first=true)
click to toggle source
string(first=true)
click to toggle source