Class: Virtus::Attribute::Set

Inherits:
Collection show all
Includes:
Collection::MemberCoercion
Defined in:
lib/virtus/attribute/set.rb

Overview

Set

Examples:

class Post
  include Virtus

  attribute :tags, Set
end

post = Post.new(:tags => %w(red green blue))

Constant Summary

Constants included from TypeLookup

TypeLookup::TYPE_FORMAT

Instance Attribute Summary

Attributes inherited from Collection

#member_type

Attributes inherited from Virtus::Attribute

#coercion_method, #default, #name, #options

Method Summary

Methods included from Collection::MemberCoercion

#coerce_and_append_member

Methods inherited from Collection

#coerce, #coerce_and_append_member, #initialize, merge_options, #new_collection

Methods inherited from Virtus::Attribute

build, #coerce, #define_accessor_methods, #define_reader_method, #define_writer_method, determine_type, #get, #get!, #initialize, #inspect, merge_options, #public_reader?, #public_writer?, #set, #set!, #value_coerced?

Methods included from DescendantsTracker

#add_descendant, #descendants

Methods included from TypeLookup

#determine_type, extended, #primitive

Methods included from Options

#accept_options, #accepted_options, #options

Constructor Details

This class inherits a constructor from Virtus::Attribute::Collection