Class: Proxy::RemoteExecution::Ssh::CommandUpdate::Data
- Inherits:
-
Object
- Object
- Proxy::RemoteExecution::Ssh::CommandUpdate::Data
- Defined in:
- lib/smart_proxy_remote_execution_ssh/command_update.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
-
#timestamp ⇒ Object
readonly
Returns the value of attribute timestamp.
Instance Method Summary collapse
- #data_type ⇒ Object
-
#initialize(data, timestamp = Time.now) ⇒ Data
constructor
A new instance of Data.
- #to_hash ⇒ Object
Constructor Details
#initialize(data, timestamp = Time.now) ⇒ Data
Returns a new instance of Data.
33 34 35 36 |
# File 'lib/smart_proxy_remote_execution_ssh/command_update.rb', line 33 def initialize(data, = Time.now) @data = data = end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
31 32 33 |
# File 'lib/smart_proxy_remote_execution_ssh/command_update.rb', line 31 def data @data end |
#timestamp ⇒ Object (readonly)
Returns the value of attribute timestamp.
31 32 33 |
# File 'lib/smart_proxy_remote_execution_ssh/command_update.rb', line 31 def end |
Instance Method Details
#data_type ⇒ Object
38 39 40 |
# File 'lib/smart_proxy_remote_execution_ssh/command_update.rb', line 38 def data_type raise NotImplemented end |
#to_hash ⇒ Object
42 43 44 45 46 |
# File 'lib/smart_proxy_remote_execution_ssh/command_update.rb', line 42 def to_hash { :output_type => data_type, :output => data, :timestamp => .to_f } end |