Sha256: b6ee105738423c4b0f0ece8f968424d0969102be60770de5d596ffe36ed0dff6

Contents?: true

Size: 333 Bytes

Versions: 10

Compression:

Stored size: 333 Bytes

Contents

module Gamefic
  module Query
    class External < Base
      def initialize objects, *args
        super(*args)
        @objects = objects
      end

      def context_from subject
        @objects
      end

      def accept?(entity)
        @objects.include?(entity) && super(entity)
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
gamefic-2.2.3 lib/gamefic/query/external.rb
gamefic-2.2.2 lib/gamefic/query/external.rb
gamefic-2.2.1 lib/gamefic/query/external.rb
gamefic-2.2.0 lib/gamefic/query/external.rb
gamefic-2.1.1 lib/gamefic/query/external.rb
gamefic-2.1.0 lib/gamefic/query/external.rb
gamefic-2.0.3 lib/gamefic/query/external.rb
gamefic-2.0.2 lib/gamefic/query/external.rb
gamefic-2.0.1 lib/gamefic/query/external.rb
gamefic-2.0.0 lib/gamefic/query/external.rb