app/helpers/washout_builder_shared_helper.rb
# When displaying a complex type that inherits from WashOut::Type
# we must use its descendant name to properly show the correct Type
# that can we used to make the actual request to the action
#
# @param [Class, String] complex_class the name of the complex type either as a string or a class
# @return [Class, String]
# @api public
When displaying a complex type that inherits from WashOut::Type
we must use its descendant name to properly show the correct Type
that can we used to make the actual request to the action
When displaying a complex type that inherits from WashOut :: Type we must use its descendant name to properly show the correct Type that can we used to make the actual request to the action
def find_correct_complex_type(complex_class)
    real_class = find_class_from_string(complex_class)
    if real_class.present? && real_class.ancestors.include?( WashoutBuilder::Type.base_type_class)
      descendant = WashoutBuilder::Type.base_param_class.parse_def(config, real_class.wash_out_param_map)[0]
      descendant.find_complex_class_name
    else
      complex_class
    end
  end
def find_correct_complex_type ( complex_class ) real_class = find_class_from_string ( complex_class ) if real_class . present? && real_class . ancestors . include? ( WashoutBuilder :: Type . base_type_class ) descendant = WashoutBuilder :: Type . base_param_class . parse_def ( config , real_class . wash_out_param_map ) [ 0 ] descendant . find_complex_class_name else complex_class end end
When displaying a complex type that inherits from WashOut::Type
we must use its descendant name to properly show the correct Type
that can we used to make the actual request to the action
When displaying a complex type that inherits from WashOut :: Type we must use its descendant name to properly show the correct Type that can we used to make the actual request to the action
None
Class, String
complex_class
<not_specific>
<not_specific>
complex_class the name of the complex type either as a string or a class
complex_class the name of the complex type either as a string or a class
api
None