Class: Envandle::GemspecCache::Reserved
- Inherits:
-
Object
- Object
- Envandle::GemspecCache::Reserved
- Defined in:
- lib/envandle/gemspec_cache.rb
Instance Attribute Summary collapse
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
-
#initialize(cache_path) ⇒ Reserved
constructor
A new instance of Reserved.
- #save ⇒ Object
- #url=(v) ⇒ Object
Constructor Details
#initialize(cache_path) ⇒ Reserved
Returns a new instance of Reserved.
48 49 50 51 |
# File 'lib/envandle/gemspec_cache.rb', line 48 def initialize(cache_path) @cache_path = cache_path @path = Envandle.tmpdir(nil, cache_path) end |
Instance Attribute Details
#path ⇒ Object (readonly)
Returns the value of attribute path.
53 54 55 |
# File 'lib/envandle/gemspec_cache.rb', line 53 def path @path end |
Instance Method Details
#save ⇒ Object
59 60 61 |
# File 'lib/envandle/gemspec_cache.rb', line 59 def save GemspecCache.new(@cache_path).append @url, @path[(@cache_path.size+1)..-1] end |
#url=(v) ⇒ Object
55 56 57 |
# File 'lib/envandle/gemspec_cache.rb', line 55 def url=(v) @url = v end |