Class: Source2MD::Type::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/source2md/type/base.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(element) ⇒ Base

Returns a new instance of Base.



10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# File 'lib/source2md/type/base.rb', line 10

def initialize(element)
  @element = element

  Source2MD.logger.debug do
    o = []
    o << "-" * 80
    o << self.class.name
    o << ""
    o << "head:"
    o << element.head
    o << ""
    o << "in:"
    o << element.body
    o << ""
    o << "out:"
    o << to_md
    o << "-" * 80
    o.compact * "\n"
  end
end

Instance Attribute Details

#elementObject (readonly)

Returns the value of attribute element.



8
9
10
# File 'lib/source2md/type/base.rb', line 8

def element
  @element
end

Class Method Details

.accept?(element) ⇒ Boolean

Returns:

  • (Boolean)


4
5
6
# File 'lib/source2md/type/base.rb', line 4

def self.accept?(element)
  false
end

Instance Method Details

#to_mdObject



31
32
# File 'lib/source2md/type/base.rb', line 31

def to_md
end