Sha256: 8e2912c38686c272934000e8f659bd672f9edf7adcd924b191d0969e337a6bdf
Contents?: true
Size: 732 Bytes
Versions: 21
Compression:
Stored size: 732 Bytes
Contents
module ApiResource module Conditions extend ActiveSupport::Autoload extend ActiveSupport::Concern autoload :AbstractCondition autoload :AssociationCondition autoload :SingleObjectAssociationCondition autoload :MultiObjectAssociationCondition autoload :IncludeCondition autoload :ScopeCondition module ClassMethods def includes(*args) self.load_resource_definition # everything in args must be an association args.each do |arg| unless self.association?(arg) raise ArgumentError, "Unknown association #{arg} to eager load" end end # Everything looks good so just create the scope ApiResource::Conditions::IncludeCondition.new(self, args) end end end end
Version data entries
21 entries across 21 versions & 1 rubygems