Class: Languages::Comment Abstract
- Inherits:
-
Object
- Object
- Languages::Comment
- Defined in:
- lib/kuniri/language/abstract_container/structured_and_oo/comment.rb
Overview
Class responsible for handling comments. Attention, this class
is the only exception to the pattern. Usually, we implements a method called detect_something. However, in the case of comment, it is easier to create another set of methods.
Direct Known Subclasses
Instance Method Summary collapse
-
#get_comment(pLine) ⇒ Object
This method is responsible for handling comments.
-
#is_multiple_line_comment?(pLine) ⇒ Boolean
This method verify if it a multiple line comment.
-
#is_multiple_line_comment_end?(pLine) ⇒ Boolean
This method verify if it is the end of multiple line comment.
-
#is_single_line_comment?(pLine) ⇒ Boolean
This method is responsible for checking if is a single line comment.
-
#prepare_line_comment(pString) ⇒ Object
protected
Method responsible for doing the final adjustment in the comment.
Instance Method Details
#get_comment(pLine) ⇒ Object
This method is responsible for handling comments.
16 17 18 |
# File 'lib/kuniri/language/abstract_container/structured_and_oo/comment.rb', line 16 def get_comment(pLine) raise NotImplementedError end |
#is_multiple_line_comment?(pLine) ⇒ Boolean
This method verify if it a multiple line comment.
32 33 34 |
# File 'lib/kuniri/language/abstract_container/structured_and_oo/comment.rb', line 32 def is_multiple_line_comment?(pLine) raise NotImplementedError end |
#is_multiple_line_comment_end?(pLine) ⇒ Boolean
This method verify if it is the end of multiple line comment.
40 41 42 |
# File 'lib/kuniri/language/abstract_container/structured_and_oo/comment.rb', line 40 def is_multiple_line_comment_end?(pLine) raise NotImplementedError end |
#is_single_line_comment?(pLine) ⇒ Boolean
This method is responsible for checking if is a single line comment.
24 25 26 |
# File 'lib/kuniri/language/abstract_container/structured_and_oo/comment.rb', line 24 def is_single_line_comment?(pLine) raise NotImplementedError end |
#prepare_line_comment(pString) ⇒ Object (protected)
Method responsible for doing the final adjustment in the comment.
49 50 51 |
# File 'lib/kuniri/language/abstract_container/structured_and_oo/comment.rb', line 49 def prepare_line_comment(pString) raise NotImplementedError end |