method
compute_type
compute_type()
protected
Hide source
# File activemodel/lib/active_model/serializers/xml.rb, line 35 def compute_type return if value.nil? type = ActiveSupport::XmlMini::TYPE_NAMES[value.class.name] type ||= :string if value.respond_to?(:to_str) type ||= :yaml type end