Sha256: 5eaf614c31c02a3117f8a3ba46883cd4f9b753644c294a007c0ad050918f9857
Contents?: true
Size: 673 Bytes
Versions: 1
Compression:
Stored size: 673 Bytes
Contents
# coding: utf-8 module ONIX2 class Website include Virtus.model attribute :website_role, Integer attribute :website_description attribute :website_link def to_xml WebsiteRepresenter.new(self).to_xml end def self.from_xml(data) WebsiteRepresenter.new(self.new).from_xml(data) end end class WebsiteRepresenter < Representable::Decorator include Representable::XML self.representation_wrap = :Website property :website_role, as: "WebsiteRole", render_filter: ::ONIX2::Formatters::TWO_DIGITS property :website_description, as: "WebsiteDescription" property :website_link, as: "WebsiteLink" end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
onix2-1.0.0 | lib/onix2/website.rb |