Module: RSS::Atom::CommonModel

Constant Summary collapse

NSPOOL =
{}
ELEMENTS =
[]

Class Method Summary collapse

Class Method Details

.append_features(klass) ⇒ Object



12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'lib/rss/atom.rb', line 12

def self.append_features(klass)
  super
  klass.install_must_call_validator("atom", URI)
  [
   ["lang", :xml],
   ["base", :xml],
  ].each do |name, uri, required|
    klass.install_get_attribute(name, uri, required, [nil, :inherit])
  end
  klass.class_eval do
    class << self
      def required_uri
        URI
      end

      def need_parent?
        true
      end
    end
  end
end