Class: WebRobots::RobotsTxt::AgentLine
- Defined in:
- lib/webrobots/robotstxt.rb
Instance Attribute Summary collapse
-
#pattern ⇒ Object
readonly
Returns the value of attribute pattern.
Attributes inherited from Line
Instance Method Summary collapse
Methods inherited from Line
Constructor Details
This class inherits a constructor from WebRobots::RobotsTxt::Line
Instance Attribute Details
#pattern ⇒ Object (readonly)
Returns the value of attribute pattern.
683 684 685 |
# File 'lib/webrobots/robotstxt.rb', line 683 def pattern @pattern end |
Instance Method Details
#compile ⇒ Object
674 675 676 677 678 679 680 681 |
# File 'lib/webrobots/robotstxt.rb', line 674 def compile if @value == '*' @pattern = // else @pattern = Regexp.new(Regexp.quote(@value), Regexp::IGNORECASE) end self end |