Class: Puppet::Util::Profiler::Logging::Sequence Private
- Defined in:
- lib/puppet/util/profiler/logging.rb
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.
Constant Summary collapse
- INITIAL =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
0- SEPARATOR =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
'.'
Instance Method Summary collapse
- #down ⇒ Object private
-
#initialize ⇒ Sequence
constructor
private
A new instance of Sequence.
- #next ⇒ Object private
- #to_s ⇒ Object private
- #up ⇒ Object private
Constructor Details
#initialize ⇒ Sequence
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 Sequence.
27 28 29 |
# File 'lib/puppet/util/profiler/logging.rb', line 27 def initialize @elements = [INITIAL] end |
Instance Method Details
#down ⇒ 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.
35 36 37 |
# File 'lib/puppet/util/profiler/logging.rb', line 35 def down @elements << INITIAL end |
#next ⇒ 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.
31 32 33 |
# File 'lib/puppet/util/profiler/logging.rb', line 31 def next @elements[-1] += 1 end |
#to_s ⇒ 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.
43 44 45 |
# File 'lib/puppet/util/profiler/logging.rb', line 43 def to_s @elements.join(SEPARATOR) end |
#up ⇒ 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.
39 40 41 |
# File 'lib/puppet/util/profiler/logging.rb', line 39 def up @elements.pop end |