# -*- coding: iso-8859-1 -*-
#-----------------------------------------------------------------------------
# Modeling Framework: an Object-Relational Bridge for python
#
# Copyright (c) 2001-2004 Sbastien Bigaret <sbigaret@users.sourceforge.net>
# All rights reserved.
#
# This file is part of the Modeling Framework.
#
# This code is distributed under a "3-clause BSD"-style license;
# see the LICENSE file for details.
#-----------------------------------------------------------------------------
""" ... describe me please I feel alone...
CVS information
$Id: Exceptions.py 932 2004-07-20 06:21:57Z sbigaret $
"""
__version__='$Revision: 932 $'[11:-2]
# python
import types
# Compatibility
from Modeling.Validation import REQUIRED,\
TYPE_MISMATCH, \
CUSTOM_KEY_VALIDATION, \
CUSTOM_OBJECT_VALIDATION, \
LOWER_BOUND, \
UPPER_BOUND, \
MODEL_ERROR
from Modeling.Validation import ValidationException
class ObjectValidationError(Exception):
def __init__(self, aKey=None, anErrorType=''):
import warnings # PEP 230
warnings.warn("Exceptions.ObjectValidationError is deprecated.\n"\
"Please use Modeling.Validation.ValidationException instead",
DeprecationWarning)
Exception.__init__.im_func(self, aKey, anErrorType)
class ModelValidationError(Exception):
"""
Raised by model-related validation methods on ModelSet, Model, Entity,
Attributes and Relationships when they fail
"""
pass
|