class Virtus::PendingAttribute
Attribute
placeholder used when type constant is passed as a string or symbol
@private
Attributes
name[R]
options[R]
type[R]
Public Class Methods
new(type, options)
click to toggle source
@api private
# File lib/virtus/attribute/builder.rb, line 10 def initialize(type, options) @type, @options = type.to_s, options @name = options[:name] end
Public Instance Methods
determine_type()
click to toggle source
@api private
# File lib/virtus/attribute/builder.rb, line 26 def determine_type if type.include?('::') Virtus.constantize(type) else Object.const_get(type) end end
finalize()
click to toggle source
@api private
# File lib/virtus/attribute/builder.rb, line 16 def finalize Attribute::Builder.call(determine_type, options).finalize end
finalized?()
click to toggle source
@api private
# File lib/virtus/attribute/builder.rb, line 21 def finalized? false end