markdown $ LineBlockquote :: SELF
Type of this instance, automatically specialized in every classcore :: Object :: class_factory
Implementation used byget_class
to create the specific class.
markdown :: Line :: defaultinit
core :: Object :: defaultinit
core :: Object :: is_same_instance
Return true ifself
and other
are the same instance (i.e. same identity).
core :: Object :: is_same_serialized
Isself
the same as other
in a serialization context?
core :: Object :: is_same_type
Return true ifself
and other
have the same dynamic type.
core :: Object :: output_class_name
Display class name on stdout (debug only).
# A markdown blockquote line.
class LineBlockquote
super Line
redef fun process(v) do
var line = v.current_line
var current_block = v.current_block.as(not null)
# go to bquote end
while line != null do
if not line.is_empty and (line.prev_empty and
line.leading == 0 and
not v.line_kind(line) isa LineBlockquote) then break
line = line.next
end
# build sub block
var block: MDBlock
if line != null then
block = current_block.split(line.prev.as(not null))
else
block = current_block.split(current_block.last_line.as(not null))
end
var kind = new BlockQuote(block)
block.kind = kind
block.remove_surrounding_empty_lines
kind.remove_block_quote_prefix(block)
v.current_line = line
v.recurse(block, false)
v.current_line = current_block.first_line
end
end
lib/markdown/markdown.nit:1743,1--1772,3