3 // BaseRepository.xh is a part of ThePEG - Toolkit for HEP Event Generation
4 // Copyright (C) 1999-2011 Leif Lonnblad
6 // ThePEG is licenced under version 2 of the GPL, see COPYING for details.
7 // Please respect the MCnet academic guidelines, see GUIDELINES for details.
9 #ifndef ThePEG_BaseRepository_XH
10 #define ThePEG_BaseRepository_XH
12 // This is the declarations of the exception classes used by the
13 // BaseRepository class.
16 #include "ThePEG/Interface/InterfaceBase.xh"
20 /** @cond EXCEPTIONCLASSES */
21 /** Exception class used by BaseRepository if an object does not
22 implement the InterfacedBase::clone() function properly. */
23 struct BadClassClone: public InterfaceException {
24 /** Standard constructor. */
25 BadClassClone(const InterfacedBase &);
28 /** Exception class used by BaseRepository if an objects
29 InterfacedBase::clone() function throws an exception. */
30 struct BadClone: public InterfaceException {
31 /** Standard constructor. */
32 BadClone(const InterfacedBase &);
35 /** Exception class used by BaseRepository if the name of an object in
36 the repository has been changed outside the repository. */
37 struct RepoNameException: public InterfaceException {
38 /** Standard constructor. */
39 RepoNameException(string);
42 /** Exception class used by BaseRepository when trying to access a
43 non-existing directory. */
44 struct RepositoryNoDirectory: public InterfaceException {
45 /** Standard constructor. */
46 RepositoryNoDirectory(string);
49 /** Exception class used by BaseRepository when trying to access a
50 non-existent object. */
51 struct RepositoryNotFound: public InterfaceException {
52 /** Standard constructor. */
53 RepositoryNotFound(string name);
56 /** Exception class used by BaseRepository if a specified object was
57 not of the expected class. */
58 struct RepositoryClassMisMatch: public InterfaceException {
59 /** Standard constructor. */
60 RepositoryClassMisMatch(const InterfacedBase & o, string name);
66 #endif /* ThePEG_BaseRepository_XH */