Class: SSHKit::LogMessage

Inherits:
Object
  • Object
show all
Defined in:
lib/sshkit/log_message.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(verbosity, message) ⇒ LogMessage

Returns a new instance of LogMessage


5
6
7
# File 'lib/sshkit/log_message.rb', line 5

def initialize(verbosity, message)
  @verbosity, @message = verbosity, message
end

Instance Attribute Details

#messageObject (readonly)

Returns the value of attribute message


4
5
6
# File 'lib/sshkit/log_message.rb', line 4

def message
  @message
end

#verbosityObject (readonly)

Returns the value of attribute verbosity


4
5
6
# File 'lib/sshkit/log_message.rb', line 4

def verbosity
  @verbosity
end

Instance Method Details

#to_sObject


8
9
10
# File 'lib/sshkit/log_message.rb', line 8

def to_s
  @message.to_s.strip
end