Class: Herve::Cache::Shard

Inherits:
Object
  • Object
show all
Defined in:
lib/herve/cache/shard.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ Shard

Returns a new instance of Shard.



8
9
10
# File 'lib/herve/cache/shard.rb', line 8

def initialize(path)
  @path = path
end

Instance Attribute Details

#pathObject (readonly)

Returns the value of attribute path.



6
7
8
# File 'lib/herve/cache/shard.rb', line 6

def path
  @path
end

Instance Method Details

#entry(file) ⇒ Object



12
13
14
# File 'lib/herve/cache/shard.rb', line 12

def entry(file)
  Entry.new(path, file)
end