class Praxis::BlueprintAttributeGroup
Public Class Methods
Source
# File lib/praxis/blueprint_attribute_group.rb, line 10 def self.construct(attribute_definition, options = {}) return self if attribute_definition.nil? # Construct a group-derived class with the given mediatype as the reference ::Class.new(self) do attributes(**options, &attribute_definition) end end
Construct a new subclass, using attribute_definition to define attributes.
Source
# File lib/praxis/blueprint_attribute_group.rb, line 5 def self.constructable? true end
Source
# File lib/praxis/blueprint_attribute_group.rb, line 19 def self.for(media_type) return media_type::AttributeGrouping if defined?(media_type::AttributeGrouping) # Cache the grouping class ::Class.new(self) do @media_type = media_type end end