local w=require(script.AllSelector)local O=require(script.AnySelector)local T=require(script.ComponentSelector)return function(I)local q={}function q.isa(w)assert(type(w)=="\115\116\114\105\110\103")return function(O)return O:IsA(w)end end function q.any(...)return O.new(I,...)end function q.all(...)return w.new(I,...)end function q.has(w,O,q)assert(type(w)=="\115\116\114\105\110\103")assert(O==nil or type(O)=="\116\097\098\108\101")assert(q==nil or type(q)=="\116\097\098\108\101")return T.new(I,w,O,q)end return q end
local AllSelector = require(script.AllSelector)
local AnySelector = require(script.AnySelector)
local ComponentSelector = require(script.ComponentSelector)

return function(rocs)
	local Selectors = {}

	function Selectors.isa(class)
		assert(type(class) == "string")

		return function(instance)
			return instance:IsA(class)
		end
	end

	function Selectors.any(...)
		return AnySelector.new(rocs, ...)
	end

	function Selectors.all(...)
		return AllSelector.new(rocs, ...)
	end

	function Selectors.has(name, properties, metacomponents)
		assert(type(name) == "string")
		assert(properties == nil or type(properties) == "table")
		assert(metacomponents == nil or type(metacomponents) == "table")

		return ComponentSelector.new(rocs, name, properties, metacomponents)
	end

	return Selectors
end
