Class: DhanHQ::Events::TickUpdated

Inherits:
Base
  • Object
show all
Defined in:
lib/DhanHQ/events/base.rb

Overview

Market data tick event.

Instance Attribute Summary

Attributes inherited from Base

#data, #timestamp

Instance Method Summary collapse

Methods inherited from Base

#initialize, #to_h, #to_prompt

Constructor Details

This class inherits a constructor from DhanHQ::Events::Base

Instance Method Details

#ltpObject



137
138
139
# File 'lib/DhanHQ/events/base.rb', line 137

def ltp
  data[:ltp]
end

#security_idObject



133
134
135
# File 'lib/DhanHQ/events/base.rb', line 133

def security_id
  data[:security_id]
end

#to_sObject



145
146
147
# File 'lib/DhanHQ/events/base.rb', line 145

def to_s
  "TickUpdated(#{security_id}, ltp=#{ltp})"
end

#volumeObject



141
142
143
# File 'lib/DhanHQ/events/base.rb', line 141

def volume
  data[:volume]
end