Module: CgminerApiClient::Miner::Commands::ReadOnly
- Included in:
- CgminerApiClient::Miner::Commands
- Defined in:
- lib/cgminer_api_client/miner/commands.rb
Instance Method Summary collapse
- #asc(number) ⇒ Object
- #asccount ⇒ Object
- #check(command) ⇒ Object
- #coin ⇒ Object
- #config ⇒ Object
- #devdetails ⇒ Object
- #devs ⇒ Object
- #notify ⇒ Object
- #pga(number) ⇒ Object
- #pgacount ⇒ Object
- #pools ⇒ Object
- #privileged ⇒ Object
- #stats ⇒ Object
- #summary ⇒ Object
- #usbstats ⇒ Object
- #version ⇒ Object
Instance Method Details
#asc(number) ⇒ Object
7 8 9 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 7 def asc(number) query(:asc, number) end |
#asccount ⇒ Object
11 12 13 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 11 def asccount query(:asccount) end |
#check(command) ⇒ Object
15 16 17 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 15 def check(command) query(:check, command)[0] end |
#coin ⇒ Object
19 20 21 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 19 def coin query(:coin)[0] end |
#config ⇒ Object
23 24 25 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 23 def config query(:config)[0] end |
#devdetails ⇒ Object
27 28 29 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 27 def devdetails query(:devdetails) end |
#devs ⇒ Object
31 32 33 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 31 def devs query(:devs) end |
#notify ⇒ Object
58 59 60 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 58 def notify query(:notify) end |
#pga(number) ⇒ Object
35 36 37 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 35 def pga(number) query(:pga, number) end |
#pgacount ⇒ Object
39 40 41 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 39 def pgacount query(:pgacount) end |
#pools ⇒ Object
43 44 45 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 43 def pools query(:pools) end |
#privileged ⇒ Object
47 48 49 50 51 52 53 54 55 56 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 47 def privileged query(:privileged) true rescue CgminerApiClient::ApiError # The miner answered and rejected: not privileged. false # ConnectionError and any other StandardError propagate so # callers don't misinterpret a transient network blip as # "access denied". end |
#stats ⇒ Object
62 63 64 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 62 def stats query(:stats) end |
#summary ⇒ Object
66 67 68 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 66 def summary query(:summary)[0] end |
#usbstats ⇒ Object
70 71 72 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 70 def usbstats query(:usbstats) end |
#version ⇒ Object
74 75 76 |
# File 'lib/cgminer_api_client/miner/commands.rb', line 74 def version query(:version)[0] end |