Sha256: 9254a6a45e4b7ef785383494de2e77f2fe06e6e53d81efab753188c848f0e447

Contents?: true

Size: 417 Bytes

Versions: 32

Compression:

Stored size: 417 Bytes

Contents

module Cuboid
module Support::Cache

# Least Recently Pushed cache implementation.
#
# Discards the least recently pushed entries, in order to make room for newer ones.
#
# This is the cache with best performance across the board.
#
# @author Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>
class LeastRecentlyPushed < Base

    private

    def prune
        @cache.delete( @cache.first.first )
    end

end
end
end

Version data entries

32 entries across 32 versions & 1 rubygems

Version Path
cuboid-0.2.11 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.10 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.9 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.8 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.7 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.6 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.5 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.4.2 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.4.1 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.4 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.3 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.2 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2.1 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.2 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.1.9.1 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.1.9 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.1.8 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.1.7 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.1.6.1 lib/cuboid/support/cache/least_recently_pushed.rb
cuboid-0.1.6 lib/cuboid/support/cache/least_recently_pushed.rb