Class: Puppet::Environments::Cached::Entry Private
- Defined in:
- lib/puppet/environments.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Never evicting entry
Direct Known Subclasses
Instance Attribute Summary collapse
- #value ⇒ Object readonly private
Instance Method Summary collapse
- #expired?(now) ⇒ Boolean private
- #guard ⇒ Object private
-
#guarded? ⇒ Boolean
private
These are not protected with a lock, because all of the Cached methods are protected.
-
#initialize(value) ⇒ Entry
constructor
private
A new instance of Entry.
- #label ⇒ Object private
- #touch ⇒ Object private
- #unguard ⇒ Object private
Constructor Details
#initialize(value) ⇒ Entry
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Entry.
534 535 536 537 |
# File 'lib/puppet/environments.rb', line 534 def initialize(value) @value = value @guards = 0 end |
Instance Attribute Details
#value ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
532 533 534 |
# File 'lib/puppet/environments.rb', line 532 def value @value end |
Instance Method Details
#expired?(now) ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
542 543 544 |
# File 'lib/puppet/environments.rb', line 542 def expired?(now) false end |
#guard ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
556 557 558 |
# File 'lib/puppet/environments.rb', line 556 def guard @guards += 1 end |
#guarded? ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
These are not protected with a lock, because all of the Cached methods are protected.
552 553 554 |
# File 'lib/puppet/environments.rb', line 552 def guarded? @guards > 0 end |
#label ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
546 547 548 |
# File 'lib/puppet/environments.rb', line 546 def label "" end |
#touch ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
539 540 |
# File 'lib/puppet/environments.rb', line 539 def touch end |
#unguard ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
560 561 562 |
# File 'lib/puppet/environments.rb', line 560 def unguard @guards -= 1 end |