Sha256: 7a767a530c58ccc5cacf54a3e1711de660c8ddf7b131f58a1716f9d93646cc17

Contents?: true

Size: 459 Bytes

Versions: 32

Compression:

Stored size: 459 Bytes

Contents

require 'set'

module Cuboid
module Support::Filter

# Filter based on a Set.
#
# @author Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
class Set < Base

    # @param    (see Base#initialize)
    def initialize(*)
        super
        @collection = ::Set.new
    end

    def to_rpc_data
        [@options, @collection.to_a]
    end

    def self.from_rpc_data( data )
        options, items = data
        new( options ).merge items
    end

end

end
end

Version data entries

32 entries across 32 versions & 1 rubygems

Version Path
cuboid-0.1.5 lib/cuboid/support/filter/set.rb
cuboid-0.1.4 lib/cuboid/support/filter/set.rb
cuboid-0.1.3 lib/cuboid/support/filter/set.rb
cuboid-0.1.2 lib/cuboid/support/filter/set.rb
cuboid-0.1.1 lib/cuboid/support/filter/set.rb
cuboid-0.1.0 lib/cuboid/support/filter/set.rb
cuboid-0.0.5 lib/cuboid/support/filter/set.rb
cuboid-0.0.4 lib/cuboid/support/filter/set.rb
cuboid-0.0.3 lib/cuboid/support/filter/set.rb
cuboid-0.0.3alpha lib/cuboid/support/filter/set.rb
cuboid-0.0.2alpha lib/cuboid/support/filter/set.rb
cuboid-0.0.1alpha lib/cuboid/support/filter/set.rb