Sha256: 0f3c6ec74890776361e93b831e70069c1addea2e8e6eaff67e8583017f6d5522

Contents?: true

Size: 944 Bytes

Versions: 94

Compression:

Stored size: 944 Bytes

Contents

# frozen_string_literal: true

module Cryptum
  # This plugin is used to Reload the Bot Conf When the "C" Key is Pressed
  module Event
    module Cancel
      # Supported Method Parameters::
      # Cryptum::Event::Cancel.open_orders(
      # )
      public_class_method def self.open_orders(opts = {})
        terminal_win = opts[:terminal_win]
        option_choice = opts[:option_choice]
        env = opts[:env]
        # event_history = opts[:event_history]
        # order_type = opts[:order_type]
        # order_action = opts[:order_action]

        terminal_win.key_press_event.key_c = false
        Cryptum::API.cancel_all_open_orders(
          env: env,
          option_choice: option_choice
        )
      rescue StandardError => e
        raise e
      end

      # Display Usage for this Module
      public_class_method def self.help
        puts "USAGE:
          #{self}.open_orders()
        "
      end
    end
  end
end

Version data entries

94 entries across 94 versions & 1 rubygems

Version Path
cryptum-0.0.355 lib/cryptum/event/cancel.rb
cryptum-0.0.354 lib/cryptum/event/cancel.rb
cryptum-0.0.353 lib/cryptum/event/cancel.rb
cryptum-0.0.352 lib/cryptum/event/cancel.rb
cryptum-0.0.351 lib/cryptum/event/cancel.rb
cryptum-0.0.350 lib/cryptum/event/cancel.rb
cryptum-0.0.349 lib/cryptum/event/cancel.rb
cryptum-0.0.348 lib/cryptum/event/cancel.rb
cryptum-0.0.347 lib/cryptum/event/cancel.rb
cryptum-0.0.346 lib/cryptum/event/cancel.rb
cryptum-0.0.345 lib/cryptum/event/cancel.rb
cryptum-0.0.344 lib/cryptum/event/cancel.rb
cryptum-0.0.343 lib/cryptum/event/cancel.rb
cryptum-0.0.342 lib/cryptum/event/cancel.rb
cryptum-0.0.341 lib/cryptum/event/cancel.rb
cryptum-0.0.339 lib/cryptum/event/cancel.rb
cryptum-0.0.338 lib/cryptum/event/cancel.rb
cryptum-0.0.337 lib/cryptum/event/cancel.rb
cryptum-0.0.336 lib/cryptum/event/cancel.rb
cryptum-0.0.335 lib/cryptum/event/cancel.rb