version 1.11, 2004/06/16 19:51:54
|
version 1.17, 2006/01/30 16:17:04
|
|
|
//%2003//////////////////////////////////////////////////////////////////////// |
//%2006//////////////////////////////////////////////////////////////////////// |
// | // |
// Copyright (c) 2000, 2001, 2002 BMC Software, Hewlett-Packard Development |
// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development |
// Company, L. P., IBM Corp., The Open Group, Tivoli Systems. |
// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems. |
// Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.; | // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.; |
// IBM Corp.; EMC Corporation, The Open Group. | // IBM Corp.; EMC Corporation, The Open Group. |
|
// Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.; |
|
// IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group. |
|
// Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.; |
|
// EMC Corporation; VERITAS Software Corporation; The Open Group. |
|
// Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.; |
|
// EMC Corporation; Symantec Corporation; The Open Group. |
// | // |
// Permission is hereby granted, free of charge, to any person obtaining a copy | // Permission is hereby granted, free of charge, to any person obtaining a copy |
// of this software and associated documentation files (the "Software"), to | // of this software and associated documentation files (the "Software"), to |
|
|
#include <Pegasus/Common/Config.h> | #include <Pegasus/Common/Config.h> |
#include <Pegasus/Common/Linkage.h> | #include <Pegasus/Common/Linkage.h> |
#include <Pegasus/Common/Exception.h> | #include <Pegasus/Common/Exception.h> |
|
#include <Pegasus/Common/PegasusAssert.h> |
|
|
|
|
| |
PEGASUS_NAMESPACE_BEGIN | PEGASUS_NAMESPACE_BEGIN |
| |
|
|
const String& message); | const String& message); |
}; | }; |
| |
/** define PEGASUS_ASSERT assertion statement. This statement tests the |
|
condition defined by the parameters and if not True executes an |
|
|
|
<pre> |
|
throw AssertionFailureException |
|
</pre> |
|
|
|
defining the file, line and condition that was tested. |
|
*/ |
|
#ifdef NDEBUG |
|
#define PEGASUS_ASSERT(COND) |
|
#else |
|
#define PEGASUS_ASSERT(COND) \ |
|
do \ |
|
{ \ |
|
if (!(COND)) \ |
|
{ \ |
|
throw AssertionFailureException(__FILE__, __LINE__, #COND); \ |
|
} \ |
|
} while (0) |
|
#endif |
|
| |
/* Macro to Create the equivalent of an assert but without the | /* Macro to Create the equivalent of an assert but without the |
termination. This can be used as a temporary marker for asserts | termination. This can be used as a temporary marker for asserts |
|
|
| |
// l10n | // l10n |
TraceableCIMException( | TraceableCIMException( |
const ContentLanguages& langs, |
const ContentLanguageList& langs, |
CIMStatusCode code, | CIMStatusCode code, |
const String& message, | const String& message, |
const String& file, | const String& file, |
|
|
| |
String getFile() const; | String getFile() const; |
Uint32 getLine() const; | Uint32 getLine() const; |
const ContentLanguages& getContentLanguages() const; |
const ContentLanguageList& getContentLanguages() const; |
}; | }; |
| |
#define PEGASUS_CIM_EXCEPTION(CODE, EXTRA_MESSAGE) \ | #define PEGASUS_CIM_EXCEPTION(CODE, EXTRA_MESSAGE) \ |