Sha256: 5bae9a838ecae7b1da2dcd836673bfb64072606e540be75582d16cb62cd23c36

Contents?: true

Size: 1.32 KB

Versions: 30

Compression:

Stored size: 1.32 KB

Contents

# Copyright (C) 2009-2013 MongoDB, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#   http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

module BSON
  # Generic Mongo Ruby Driver exception class.
  class MongoRubyError < StandardError; end

  # Raised when MongoDB itself has returned an error.
  class MongoDBError < RuntimeError; end

  # This will replace MongoDBError.
  class BSONError < MongoDBError; end

  # Raised when given a string is not valid utf-8 (Ruby 1.8 only).
  class InvalidStringEncoding < BSONError; end

  # Raised when attempting to initialize an invalid ObjectId.
  class InvalidObjectId < BSONError; end

  # Raised when trying to insert a document that exceeds the 4MB limit or
  # when the document contains objects that can't be serialized as BSON.
  class InvalidDocument < BSONError; end

  # Raised when an invalid name is used.
  class InvalidKeyName < BSONError; end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
bson-1.12.5-java lib/bson/exceptions.rb
bson-1.12.5 lib/bson/exceptions.rb
bson-1.12.4-java lib/bson/exceptions.rb
bson-1.12.4 lib/bson/exceptions.rb
bson-1.12.3-java lib/bson/exceptions.rb
bson-1.12.3 lib/bson/exceptions.rb
bson-1.12.2-java lib/bson/exceptions.rb
bson-1.12.2 lib/bson/exceptions.rb
bson-1.12.1-java lib/bson/exceptions.rb
bson-1.12.1 lib/bson/exceptions.rb
bson-1.12.0-java lib/bson/exceptions.rb
bson-1.12.0 lib/bson/exceptions.rb
bson-1.12.0.rc2-java lib/bson/exceptions.rb
bson-1.12.0.rc2 lib/bson/exceptions.rb
bson-1.12.0.rc1-java lib/bson/exceptions.rb
bson-1.12.0.rc1 lib/bson/exceptions.rb
bson-1.12.0.rc0 lib/bson/exceptions.rb
bson-1.12.0.rc0-java lib/bson/exceptions.rb
bson-1.11.1 lib/bson/exceptions.rb
bson-1.11.1-java lib/bson/exceptions.rb