Class: Coradoc::Markdown::Serializer::Strategies::Autolink::None

Inherits:
Base
  • Object
show all
Defined in:
lib/coradoc/markdown/serializer/strategies/autolink/none.rb

Overview

No autolink form — emit standard [text](url). The default when ‘autolinks: false` or when text differs from url.

Class Method Summary collapse

Methods inherited from Base

mode_name

Class Method Details

.applies?(_url, _text, _ctx) ⇒ Boolean

Returns:

  • (Boolean)


14
15
16
# File 'lib/coradoc/markdown/serializer/strategies/autolink/none.rb', line 14

def applies?(_url, _text, _ctx)
  false
end

.render(_url, _text, _ctx) ⇒ Object

Raises:

  • (NotImplementedError)


18
19
20
# File 'lib/coradoc/markdown/serializer/strategies/autolink/none.rb', line 18

def render(_url, _text, _ctx)
  raise NotImplementedError, 'None strategy never renders'
end