Class: Gauge::GaugeMessages Private

Inherits:
Object
  • Object
show all
Defined in:
lib/gauge_messages.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.

API:

  • private

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize ⇒ GaugeMessages

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 GaugeMessages.

API:

  • private



34
35
36
# File 'lib/gauge_messages.rb', line 34

def initialize
  @messages = []
end

Class Method Details

.instance ⇒ 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.

API:

  • private



38
39
40
# File 'lib/gauge_messages.rb', line 38

def self.instance
  @gauge_messages ||= GaugeMessages.new
end

Instance Method Details

#clear ⇒ 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.

API:

  • private



50
51
52
# File 'lib/gauge_messages.rb', line 50

def clear
  @messages = []
end

#get ⇒ 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.

API:

  • private



46
47
48
# File 'lib/gauge_messages.rb', line 46

def get
  @messages
end

#write(message) ⇒ 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.

API:

  • private



42
43
44
# File 'lib/gauge_messages.rb', line 42

def write(message)
  @messages.push(message)
end