Sha256: e68bcfab353d8eb9bdda85e4d584cbb6284eae0138d35a62080d688a05c9d0ad

Contents?: true

Size: 949 Bytes

Versions: 28

Compression:

Stored size: 949 Bytes

Contents

# frozen_string_literal: true

module Evostream
  module CodeError
    # Program finished correctly
    class Finished < RuntimeError; end

    # Error 1xx
    module Syntax
      # Syntax to command is invalid
      class CommandInvalid < RuntimeError
        def initialize
          puts 'Command is invalid !!'.red
        end
      end

      # Syntax to option is invalid
      class OptionInvalid < RuntimeError
        def initialize
          puts 'No command executed !! No command precise.'.red
        end
      end
    end

    # Error 2xx
    module Evostream
      # Connection to Evostream failed
      class ConnectionFailed < RuntimeError
        def initialize
          puts 'Connection to Evostream REFUSED !!'.red
        end
      end

      # Response to evostream is empty
      class NoResult < RuntimeError
        def initialize
          puts 'No result for this command.'.yellow
        end
      end
    end
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
evostream-event-2.0.3 lib/evostream/cli/code_error.rb
evostream-event-2.0.3.pre.1265906291 lib/evostream/cli/code_error.rb
evostream-event-2.0.3.pre.1265756691 lib/evostream/cli/code_error.rb
evostream-event-2.0.3.pre.1265752332 lib/evostream/cli/code_error.rb
evostream-event-2.0.2 lib/evostream/cli/code_error.rb
evostream-event-2.0.2.pre.994185738 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.994170151 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.994165179 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.994159616 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.856454391 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.856447460 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.856441003 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.816370746 lib/evostream/cli/code_error.rb
evostream-event-2.0.0.pre.809444619 lib/evostream/cli/code_error.rb
evostream-event-1.0.3 lib/evostream/cli/code_error.rb
evostream-event-1.0.3.pre.95 lib/evostream/cli/code_error.rb
evostream-event-1.0.3.pre.93 lib/evostream/cli/code_error.rb
evostream-event-1.0.3.pre.91 lib/evostream/cli/code_error.rb
evostream-event-1.0.3.pre.83 lib/evostream/cli/code_error.rb
evostream-event-1.0.2 lib/evostream/cli/code_error.rb