Class: SublimeDSL::TextMate::Grammar::RuleBuilder::MatchState
- Inherits:
-
State
- Object
- State
- SublimeDSL::TextMate::Grammar::RuleBuilder::MatchState
show all
- Defined in:
- lib/sublime_dsl/textmate/grammar/dsl_reader.rb
Instance Attribute Summary
Attributes inherited from State
#builder, #comment, #disabled, #scope
Instance Method Summary
collapse
Methods inherited from State
#initialize
Instance Method Details
#both(captures) ⇒ Object
301
302
303
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 301
def both(captures)
raise Error, "'both' is invalid with 'match'"
end
|
#content_scope=(scope) ⇒ Object
305
306
307
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 305
def content_scope=(scope)
raise Error, "'content_scope' is invalid with 'match'"
end
|
#from(re, captures) ⇒ Object
293
294
295
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 293
def from(re, captures)
raise Error, "'from' is invalid with 'match'"
end
|
#match(re, captures) ⇒ Object
288
289
290
291
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 288
def match(re, captures)
@match = Match.new(Tools::RegexpWannabe.new(re.source))
@match.captures.merge! captures
end
|
#patterns ⇒ Object
313
314
315
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 313
def patterns
raise Error, "'patterns' is invalid with 'match'"
end
|
#rule ⇒ Object
317
318
319
320
321
322
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 317
def rule
r = MatchRule.new
init r
r.match = @match
r
end
|
#to(re, captures) ⇒ Object
297
298
299
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 297
def to(re, captures)
raise Error, "'to' is invalid with 'match'"
end
|
#to_last=(value) ⇒ Object
309
310
311
|
# File 'lib/sublime_dsl/textmate/grammar/dsl_reader.rb', line 309
def to_last=(value)
raise Error, "'to_last' is invalid with 'match'"
end
|