Class: Decode::Comment::Pragma
- Defined in:
- lib/decode/comment/pragma.rb
Overview
Asserts a specific property about the method signature.
-
‘@reentrant This method is thread-safe.`
-
‘@deprecated Please use other_method instead.`
-
‘@blocking This method may block.`
-
‘@asynchronous This method may yield.`
Constant Summary
Constants inherited from Tag
Instance Attribute Summary
Attributes inherited from Tag
#The directive that generated the tag., #directive
Attributes inherited from Node
#The children of this node., #children
Class Method Summary collapse
-
.build(directive, text) ⇒ Object
Build a pragma from a directive and text.
-
.parse(directive, text, lines, tags, level = 0) ⇒ Object
Parse a pragma directive from text.
Instance Method Summary collapse
-
#initialize(directive) ⇒ Pragma
constructor
Initialize a new pragma.
Methods inherited from Tag
Methods inherited from Node
#add, #children?, #each, #filter, #text, #traverse
Constructor Details
#initialize(directive) ⇒ Pragma
Initialize a new pragma.
43 44 45 |
# File 'lib/decode/comment/pragma.rb', line 43 def initialize(directive) super(directive) end |
Class Method Details
.build(directive, text) ⇒ Object
Build a pragma from a directive and text.
31 32 33 34 35 36 37 38 39 |
# File 'lib/decode/comment/pragma.rb', line 31 def self.build(directive, text) node = self.new(directive) if text node.add(Text.new(text)) end return node end |
.parse(directive, text, lines, tags, level = 0) ⇒ Object
Parse a pragma directive from text.
24 25 26 |
# File 'lib/decode/comment/pragma.rb', line 24 def self.parse(directive, text, lines, , level = 0) self.build(directive, text) end |