Sha256: 288af9a9b77d4ae32cd8220dc628bc8285f314d1f604d02175401350328f54fe

Contents?: true

Size: 559 Bytes

Versions: 7

Compression:

Stored size: 559 Bytes

Contents

class RubyPropertyReflector < JSObjectionRuntimePropertyReflector
  def propertyForClass(klass, andProperty: property)
    if klass.respondsToSelector :objectionTypeMappings
      dependency_type = klass.send(:objectionTypeMappings)[property]
      unless dependency_type.is_a? Class
        dependency_type = dependency_type.objection_constantize
      end
      property_info = JSObjectionPropertyInfo.new
      property_info.value = dependency_type
      property_info.type = JSObjectionTypeClass
      property_info
    else
      super
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
motion-objection-0.8.6 lib/motion-objection/ruby_property_reflector.rb
motion-objection-0.8.5 lib/motion-objection/ruby_property_reflector.rb
motion-objection-0.8.4 lib/motion-objection/ruby_property_reflector.rb
motion-objection-0.8.3 lib/motion-objection/ruby_property_reflector.rb
motion-objection-0.8.2 lib/motion-objection/ruby_property_reflector.rb
motion-objection-0.8.1 lib/motion-objection/ruby_property_reflector.rb
motion-objection-0.8 lib/motion-objection/ruby_property_reflector.rb