Sha256: d2484cd5fc624e804edcea50dd7cf2b8c2cec921eda8d273a756b302daf34a2b
Contents?: true
Size: 1.3 KB
Versions: 4
Compression:
Stored size: 1.3 KB
Contents
# encoding: utf-8 # # This file is part of the bovem gem. Copyright (C) 2013 and above Shogun <shogun@cowtech.it>. # Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php. # module Bovem # Exceptions for {Bovem Bovem}. module Errors # This exception is raised if a {Configuration Configuration} is invalid. class InvalidConfiguration < ::ArgumentError end # This exception is raised if a {Logger Logger} is invalid. class InvalidLogger < ::ArgumentError end # This exception is raised when something goes wrong. # # @attribute [r] target # @return [Object] The target of this error. # @attribute [r] reason # @return [Symbol] The reason of failure. # @attribute [r] message # @return [String] A human readable message. class Error < ArgumentError attr_reader :target attr_reader :reason attr_reader :message # Initializes a new error # # @param target [Object] The target of this error. # @param reason [Symbol] The reason of failure. # @param message [String] A human readable message. def initialize(target, reason, message) super(message) @target = target @reason = reason @message = message end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
bovem-3.0.5 | lib/bovem/errors.rb |
bovem-3.0.4 | lib/bovem/errors.rb |
bovem-3.0.3 | lib/bovem/errors.rb |
bovem-3.0.2 | lib/bovem/errors.rb |