Sha256: 353dd1568b05a1bac500f99f843c8d76b7bfda1c1713f1a5c52ce5b7e6006a76
Contents?: true
Size: 645 Bytes
Versions: 2
Compression:
Stored size: 645 Bytes
Contents
require 'schematic/generator/sandbox' require 'schematic/exceptions' module Schematic module Serializers module Xsd def self.extended(klass) raise ClassMissingXmlSerializer unless klass.ancestors.include?(ActiveModel::Serializers::Xml) raise ClassMissingAttributes unless klass.instance_methods.include?(:attributes) end def schematic(&block) schematic_sandbox.run(&block) end def schematic_sandbox @schematic_sandbox ||= Schematic::Generator::Sandbox.new(self) end def to_xsd(options = {}) schematic_sandbox.to_xsd(options) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
schematic-0.7.1 | lib/schematic/serializers/xsd.rb |
schematic-0.7.0 | lib/schematic/serializers/xsd.rb |