Class: BlueFeather::Parser::RenderState

Inherits:
Object
  • Object
show all
Defined in:
lib/bluefeather.rb

Overview

Rendering state class Keeps track of URLs, titles, and HTML blocks midway through a render. I prefer this to the globals of the Perl version because globals make me break out in hives. Or something.

Defined Under Namespace

Classes: Header

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeRenderState

Returns a new instance of RenderState.



402
403
404
405
406
407
408
409
410
411
# File 'lib/bluefeather.rb', line 402

def initialize
  @urls, @titles, @html_blocks = {}, {}, {}
  @log = nil
  @footnotes, @found_footnote_ids, @warnings = {}, [], []
  @headers = []
  @block_transform_depth = 0
  @header_id_type = HeaderIDType::MD5
  @numbering = false
  @numbering_start_level = 2
end

Instance Attribute Details

#block_transform_depthObject

Returns the value of attribute block_transform_depth.



397
398
399
# File 'lib/bluefeather.rb', line 397

def block_transform_depth
  @block_transform_depth
end

#footnotesObject

BlueFeather Extension



396
397
398
# File 'lib/bluefeather.rb', line 396

def footnotes
  @footnotes
end

#found_footnote_idsObject

BlueFeather Extension



396
397
398
# File 'lib/bluefeather.rb', line 396

def found_footnote_ids
  @found_footnote_ids
end

#header_id_typeObject

option switch



398
399
400
# File 'lib/bluefeather.rb', line 398

def header_id_type
  @header_id_type
end

#headersObject

Returns the value of attribute headers.



397
398
399
# File 'lib/bluefeather.rb', line 397

def headers
  @headers
end

#html_blocksObject

from Original BlueCloth



393
394
395
# File 'lib/bluefeather.rb', line 393

def html_blocks
  @html_blocks
end

#logObject

from Original BlueCloth



393
394
395
# File 'lib/bluefeather.rb', line 393

def log
  @log
end

#numberingObject Also known as: numbering?

option switch



399
400
401
# File 'lib/bluefeather.rb', line 399

def numbering
  @numbering
end

#numbering_start_levelObject

option switch



399
400
401
# File 'lib/bluefeather.rb', line 399

def numbering_start_level
  @numbering_start_level
end

#titlesObject

from Original BlueCloth



393
394
395
# File 'lib/bluefeather.rb', line 393

def titles
  @titles
end

#urlsObject

from Original BlueCloth



393
394
395
# File 'lib/bluefeather.rb', line 393

def urls
  @urls
end

#warningsObject

BlueFeather Extension



396
397
398
# File 'lib/bluefeather.rb', line 396

def warnings
  @warnings
end