com.tensegrity.generic.constraint
Class ConstraintViolationException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended bycom.tensegrity.generic.util.StaticException
              extended bycom.tensegrity.generic.constraint.ConstraintViolationException
All Implemented Interfaces:
java.io.Serializable

public class ConstraintViolationException
extends StaticException

This exception is thrown if an Attribute or an AttributeCollection is associated with Constraint which has determined a validation failure.

Version:
$Id: ConstraintViolationException.java,v 1.7 2005/09/30 09:41:17 BurkhardWick Exp $
Author:
M. Kegel
See Also:
Serialized Form

Constructor Summary
ConstraintViolationException(java.lang.String message)
          Deprecated. Please use ConstraintViolationException(String, Constraint), so the user is able to retrieve the corresponding constraint.
ConstraintViolationException(java.lang.String message, Constraint constraint)
          Constructor specifying a description.
 
Method Summary
 Constraint getConstraint()
          Returns the constraint that has risen the exception.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ConstraintViolationException

public ConstraintViolationException(java.lang.String message)
Deprecated. Please use ConstraintViolationException(String, Constraint), so the user is able to retrieve the corresponding constraint.

Constructor specifying a description.

Parameters:
message - a detailed message for the exception.

ConstraintViolationException

public ConstraintViolationException(java.lang.String message,
                                    Constraint constraint)
Constructor specifying a description.

Parameters:
message - a detailed message for the exception.
constraint - the constraint that has risen the exception
Method Detail

getConstraint

public Constraint getConstraint()
Returns the constraint that has risen the exception. Be aware that this might be null, because of code using the old constructor of this exception.

Returns:
the constraint that has risen the exception


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.