judofyr / ruby-oembed

oEmbed for Ruby

ruby-oembed / lib / oembed / errors.rb
100644 25 lines (22 sloc) 0.54 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
module OEmbed
  class NotFound < StandardError
    def to_s
      "No embeddable content at '#{super}'"
    end
  end
  
  class UnknownFormat < StandardError
    def to_s
      "The provider doesn't support the '#{super}' format"
    end
  end
  
  class FormatNotSupported < StandardError
    def to_s
      "This server doesn't have the correct libraries installed to support the '#{super}' format"
    end
  end
  
  class UnknownResponse < StandardError
    def to_s
      "Got unkown response (#{super}) from server"
    end
  end
end