Class: Texter::Formatter

Inherits:
Object
  • Object
show all
Defined in:
app/lib/texter/formatter.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(body, options = {}) ⇒ Formatter

Returns a new instance of Formatter.



5
6
7
8
9
# File 'app/lib/texter/formatter.rb', line 5

def initialize(body, options = {})
  @body = body
  @options = options.dup
  reverse_merge_defaults
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



3
4
5
# File 'app/lib/texter/formatter.rb', line 3

def body
  @body
end

#optionsObject (readonly)

Returns the value of attribute options.



3
4
5
# File 'app/lib/texter/formatter.rb', line 3

def options
  @options
end

Instance Method Details

#blockString, NilClass

Returns:

  • (String, NilClass)

Raises:

  • (NotImplementedError)


17
18
19
# File 'app/lib/texter/formatter.rb', line 17

def block
  raise NotImplementedError
end

#inlineString, NilClass

Returns:

  • (String, NilClass)

Raises:

  • (NotImplementedError)


12
13
14
# File 'app/lib/texter/formatter.rb', line 12

def inline
  raise NotImplementedError
end