Class: TonClient::Debot
- Includes:
- CommonInstanceHelpers
- Defined in:
- lib/everscale-client-ruby/Client/Debot.rb
Constant Summary collapse
- MODULE =
self.to_s.downcase.gsub(/^(.+::|)(\w+)$/, '\2').freeze
Instance Attribute Summary collapse
-
#context ⇒ Object
readonly
Returns the value of attribute context.
-
#request_id ⇒ Object
readonly
Returns the value of attribute request_id.
-
#requests ⇒ Object
readonly
Returns the value of attribute requests.
Instance Method Summary collapse
-
#execute(payload, &block) ⇒ Object
INPUT: ParamsOfExecute debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
-
#fetch(payload, &block) ⇒ Object
INPUT: ParamsOfFetch address: String - # # Debot smart contract address.
-
#init(payload, &block) ⇒ Object
INPUT: ParamsOfInit address: String - # # Debot smart contract address RESPONSE: RegisteredDebot debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
-
#initialize(context: nil, request_id: nil, requests: nil) ⇒ Debot
constructor
A new instance of Debot.
-
#remove(payload, &block) ⇒ Object
INPUT: ParamsOfRemove debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
-
#send(payload, &block) ⇒ Object
INPUT: ParamsOfSend debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
-
#start(payload, &block) ⇒ Object
INPUT: ParamsOfStart debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
Methods included from CommonInstanceHelpers
#base64?, #encode_to_base64, #full_method_name
Constructor Details
#initialize(context: nil, request_id: nil, requests: nil) ⇒ Debot
9 10 11 12 13 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 9 def initialize(context: nil, request_id: nil, requests: nil) @context = context @request_id = request_id @requests = requests end |
Instance Attribute Details
#context ⇒ Object (readonly)
Returns the value of attribute context.
6 7 8 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 6 def context @context end |
#request_id ⇒ Object (readonly)
Returns the value of attribute request_id.
6 7 8 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 6 def request_id @request_id end |
#requests ⇒ Object (readonly)
Returns the value of attribute requests.
6 7 8 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 6 def requests @requests end |
Instance Method Details
#execute(payload, &block) ⇒ Object
INPUT: ParamsOfExecute debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine. action: DebotAction - # # Debot Action that must be executed.
42 43 44 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 42 def execute(payload, &block) TonBinding.requestLibrary(context: context, request_id: request_id, requests: requests, method_name: full_method_name(MODULE, __method__.to_s), payload: payload, &block) end |
#fetch(payload, &block) ⇒ Object
INPUT: ParamsOfFetch address: String - # # Debot smart contract address. RESPONSE: ResultOfFetch info: DebotInfo - # # Debot metadata.
35 36 37 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 35 def fetch(payload, &block) TonBinding.requestLibrary(context: context, request_id: request_id, requests: requests, method_name: full_method_name(MODULE, __method__.to_s), payload: payload, &block) end |
#init(payload, &block) ⇒ Object
INPUT: ParamsOfInit address: String - # # Debot smart contract address RESPONSE: RegisteredDebot debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine. debot_abi: String - # # Debot abi as json string. info: DebotInfo - # # Debot metadata.
21 22 23 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 21 def init(payload, &block) TonBinding.requestLibrary(context: context, request_id: request_id, requests: requests, method_name: full_method_name(MODULE, __method__.to_s), payload: payload, &block) end |
#remove(payload, &block) ⇒ Object
INPUT: ParamsOfRemove debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
55 56 57 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 55 def remove(payload, &block) TonBinding.requestLibrary(context: context, request_id: request_id, requests: requests, method_name: full_method_name(MODULE, __method__.to_s), payload: payload, &block) end |
#send(payload, &block) ⇒ Object
INPUT: ParamsOfSend debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine. message: String - # # BOC of internal message to debot encoded in base64 format.
49 50 51 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 49 def send(payload, &block) TonBinding.requestLibrary(context: context, request_id: request_id, requests: requests, method_name: full_method_name(MODULE, __method__.to_s), payload: payload, &block) end |
#start(payload, &block) ⇒ Object
INPUT: ParamsOfStart debot_handle: DebotHandle - # # Debot handle which references an instance of debot engine.
27 28 29 |
# File 'lib/everscale-client-ruby/Client/Debot.rb', line 27 def start(payload, &block) TonBinding.requestLibrary(context: context, request_id: request_id, requests: requests, method_name: full_method_name(MODULE, __method__.to_s), payload: payload, &block) end |