Class: Onebox::Preview
- Inherits:
-
Object
- Object
- Onebox::Preview
- Defined in:
- lib/onebox/preview.rb
Defined Under Namespace
Classes: InvalidURI
Instance Method Summary collapse
-
#initialize(link, parameters = Onebox.options) ⇒ Preview
constructor
A new instance of Preview.
- #options ⇒ Object
- #placeholder_html ⇒ Object
- #to_s ⇒ Object
Constructor Details
Instance Method Details
#options ⇒ Object
30 31 32 |
# File 'lib/onebox/preview.rb', line 30 def OpenStruct.new(@options) end |
#placeholder_html ⇒ Object
23 24 25 26 27 28 |
# File 'lib/onebox/preview.rb', line 23 def placeholder_html return "" unless engine sanitize process_html engine.placeholder_html rescue *WEB_EXCEPTIONS "" end |
#to_s ⇒ Object
16 17 18 19 20 21 |
# File 'lib/onebox/preview.rb', line 16 def to_s return "" unless engine sanitize process_html engine_html rescue *WEB_EXCEPTIONS "" end |