Class: ApiValve::RouteSet::Route
- Inherits:
-
Struct
- Object
- Struct
- ApiValve::RouteSet::Route
- Defined in:
- lib/api_valve/route_set.rb
Instance Attribute Summary collapse
-
#block ⇒ Object
Returns the value of attribute block.
-
#options ⇒ Object
Returns the value of attribute options.
-
#regexp ⇒ Object
Returns the value of attribute regexp.
Instance Method Summary collapse
Instance Attribute Details
#block ⇒ Object
Returns the value of attribute block
5 6 7 |
# File 'lib/api_valve/route_set.rb', line 5 def block @block end |
#options ⇒ Object
Returns the value of attribute options
5 6 7 |
# File 'lib/api_valve/route_set.rb', line 5 def @options end |
#regexp ⇒ Object
Returns the value of attribute regexp
5 6 7 |
# File 'lib/api_valve/route_set.rb', line 5 def regexp @regexp end |
Instance Method Details
#match(path_info) ⇒ Object
8 9 10 11 12 |
# File 'lib/api_valve/route_set.rb', line 8 def match(path_info) return {} if regexp.nil? # return empty 'match data' on catch all regexp.match(path_info) end |