Sha256: 06fc9b0d3f4a9fe97e6979254ea68806afcb54a491e4e6aaf34012797140f208

Contents?: true

Size: 767 Bytes

Versions: 69

Compression:

Stored size: 767 Bytes

Contents

# frozen_string_literal: true

module Cryptum
  # Cryptum::Event Namespace
  module Event
    # This Module is used to Exit Cryptum Gracefully When the "x" Key is Pressed
    module Exit
      # Supported Method Parameters::
      # Cryptum::Event::Exit.gracefully(
      # )
      public_class_method def self.gracefully(opts = {})
        event_history = opts[:event_history]

        Cryptum::UI::Exit.gracefully(event_history: event_history)
      rescue Interrupt, StandardError => e
        Cryptum::Log.append(level: :error, msg: e, which_self: self, event_history: event_history)
      end

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

Version data entries

69 entries across 69 versions & 1 rubygems

Version Path
cryptum-0.0.426 lib/cryptum/event/exit.rb
cryptum-0.0.425 lib/cryptum/event/exit.rb
cryptum-0.0.424 lib/cryptum/event/exit.rb
cryptum-0.0.423 lib/cryptum/event/exit.rb
cryptum-0.0.422 lib/cryptum/event/exit.rb
cryptum-0.0.421 lib/cryptum/event/exit.rb
cryptum-0.0.420 lib/cryptum/event/exit.rb
cryptum-0.0.419 lib/cryptum/event/exit.rb
cryptum-0.0.418 lib/cryptum/event/exit.rb
cryptum-0.0.417 lib/cryptum/event/exit.rb
cryptum-0.0.416 lib/cryptum/event/exit.rb
cryptum-0.0.415 lib/cryptum/event/exit.rb
cryptum-0.0.414 lib/cryptum/event/exit.rb
cryptum-0.0.413 lib/cryptum/event/exit.rb
cryptum-0.0.412 lib/cryptum/event/exit.rb
cryptum-0.0.411 lib/cryptum/event/exit.rb
cryptum-0.0.410 lib/cryptum/event/exit.rb
cryptum-0.0.409 lib/cryptum/event/exit.rb
cryptum-0.0.408 lib/cryptum/event/exit.rb
cryptum-0.0.407 lib/cryptum/event/exit.rb