module Representable::XML::Namespace::AsWithNamespace

Public Instance Methods

read(node, as) click to toggle source

FIXME: this is shit, the NestedOptions is executed too late here!

Calls superclass method
# File lib/representable/xml/namespace.rb, line 67
def read(node, as)
  super(node, prefixed(self, as))
end
write(doc, fragment, as) click to toggle source
Calls superclass method
# File lib/representable/xml/namespace.rb, line 62
def write(doc, fragment, as)
  super(doc, fragment, prefixed(self, as))
end

Private Instance Methods

prefixed(dfn, as) click to toggle source
# File lib/representable/xml/namespace.rb, line 72
def prefixed(dfn, as)
  uri    = dfn[:namespace] # this is generic behavior and per property
  prefix = dfn[:namespace_defs][uri]
  as     = Namespace::Namespaced(prefix, as)
end