Class: MarkdownExec::LinkState
Instance Attribute Summary collapse
-
#block_name ⇒ Object
Returns the value of attribute block_name.
-
#display_menu ⇒ Object
Returns the value of attribute display_menu.
-
#document_filename ⇒ Object
Returns the value of attribute document_filename.
-
#inherited_block_names ⇒ Object
Returns the value of attribute inherited_block_names.
-
#inherited_dependencies ⇒ Object
Returns the value of attribute inherited_dependencies.
-
#inherited_lines ⇒ Object
Returns the value of attribute inherited_lines.
-
#prior_block_was_link ⇒ Object
Returns the value of attribute prior_block_was_link.
Class Method Summary collapse
-
.empty ⇒ LinkState
Creates an empty LinkState instance.
Instance Method Summary collapse
-
#==(other) ⇒ Boolean
Custom equality method to compare LinkState objects.
-
#initialize(block_name: nil, display_menu: nil, document_filename: nil, inherited_block_names: [], inherited_dependencies: nil, inherited_lines: nil, prior_block_was_link: nil) ⇒ LinkState
constructor
Initialize the LinkState with keyword arguments for each attribute.
Constructor Details
#initialize(block_name: nil, display_menu: nil, document_filename: nil, inherited_block_names: [], inherited_dependencies: nil, inherited_lines: nil, prior_block_was_link: nil) ⇒ LinkState
Initialize the LinkState with keyword arguments for each attribute.
17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/link_history.rb', line 17 def initialize(block_name: nil, display_menu: nil, document_filename: nil, inherited_block_names: [], inherited_dependencies: nil, inherited_lines: nil, prior_block_was_link: nil) @block_name = block_name @display_menu = @document_filename = document_filename @inherited_block_names = inherited_block_names @inherited_dependencies = inherited_dependencies @inherited_lines = inherited_lines @prior_block_was_link = prior_block_was_link end |
Instance Attribute Details
#block_name ⇒ Object
Returns the value of attribute block_name.
7 8 9 |
# File 'lib/link_history.rb', line 7 def block_name @block_name end |
#display_menu ⇒ Object
Returns the value of attribute display_menu.
7 8 9 |
# File 'lib/link_history.rb', line 7 def @display_menu end |
#document_filename ⇒ Object
Returns the value of attribute document_filename.
7 8 9 |
# File 'lib/link_history.rb', line 7 def document_filename @document_filename end |
#inherited_block_names ⇒ Object
Returns the value of attribute inherited_block_names.
7 8 9 |
# File 'lib/link_history.rb', line 7 def inherited_block_names @inherited_block_names end |
#inherited_dependencies ⇒ Object
Returns the value of attribute inherited_dependencies.
7 8 9 |
# File 'lib/link_history.rb', line 7 def inherited_dependencies @inherited_dependencies end |
#inherited_lines ⇒ Object
Returns the value of attribute inherited_lines.
7 8 9 |
# File 'lib/link_history.rb', line 7 def inherited_lines @inherited_lines end |
#prior_block_was_link ⇒ Object
Returns the value of attribute prior_block_was_link.
7 8 9 |
# File 'lib/link_history.rb', line 7 def prior_block_was_link @prior_block_was_link end |
Class Method Details
.empty ⇒ LinkState
Creates an empty LinkState instance.
31 32 33 |
# File 'lib/link_history.rb', line 31 def self.empty new end |
Instance Method Details
#==(other) ⇒ Boolean
Custom equality method to compare LinkState objects.
38 39 40 41 42 43 44 45 46 47 |
# File 'lib/link_history.rb', line 38 def ==(other) other.class == self.class && other.block_name == block_name && other. == && other.document_filename == document_filename && other.inherited_block_names == inherited_block_names && other.inherited_dependencies == inherited_dependencies && other.inherited_lines == inherited_lines && other.prior_block_was_link == prior_block_was_link end |