/usr/share/cruisecontrol-bin-2.6.1/projects/qpid-trunk/cpp/src/gen/qpid/amqp_0_10/exceptions.h

00001 #ifndef QPID_AMQP_0_10_EXCEPTIONS_H
00002 #define QPID_AMQP_0_10_EXCEPTIONS_H
00003 /*
00004  *
00005  * Licensed to the Apache Software Foundation (ASF) under one
00006  * or more contributor license agreements.  See the NOTICE file
00007  * distributed with this work for additional information
00008  * regarding copyright ownership.  The ASF licenses this file
00009  * to you under the Apache License, Version 2.0 (the
00010  * "License"); you may not use this file except in compliance
00011  * with the License.  You may obtain a copy of the License at
00012  *
00013  *   http://www.apache.org/licenses/LICENSE-2.0
00014  *
00015  * Unless required by applicable law or agreed to in writing,
00016  * software distributed under the License is distributed on an
00017  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
00018  * KIND, either express or implied.  See the License for the
00019  * specific language governing permissions and limitations
00020  * under the License.
00021  *
00022  */
00023 
00028 
00029 
00030 #include "qpid/amqp_0_10/Exception.h"
00031 
00032 namespace qpid {
00033 namespace amqp_0_10 {
00034 
00035 
00042 struct UnauthorizedAccessException:
00043     public SessionAbortedException
00044 {
00045     UnauthorizedAccessException(const std::string& msg=std::string())
00046         : SessionAbortedException(execution::UNAUTHORIZED_ACCESS, msg) {}
00047   protected:
00048     std::string getPrefix() const { return "UnauthorizedAccessException"; }
00049 };
00050 
00056 struct NotFoundException:
00057     public SessionAbortedException
00058 {
00059     NotFoundException(const std::string& msg=std::string())
00060         : SessionAbortedException(execution::NOT_FOUND, msg) {}
00061   protected:
00062     std::string getPrefix() const { return "NotFoundException"; }
00063 };
00064 
00071 struct ResourceLockedException:
00072     public SessionAbortedException
00073 {
00074     ResourceLockedException(const std::string& msg=std::string())
00075         : SessionAbortedException(execution::RESOURCE_LOCKED, msg) {}
00076   protected:
00077     std::string getPrefix() const { return "ResourceLockedException"; }
00078 };
00079 
00085 struct PreconditionFailedException:
00086     public SessionAbortedException
00087 {
00088     PreconditionFailedException(const std::string& msg=std::string())
00089         : SessionAbortedException(execution::PRECONDITION_FAILED, msg) {}
00090   protected:
00091     std::string getPrefix() const { return "PreconditionFailedException"; }
00092 };
00093 
00099 struct ResourceDeletedException:
00100     public SessionAbortedException
00101 {
00102     ResourceDeletedException(const std::string& msg=std::string())
00103         : SessionAbortedException(execution::RESOURCE_DELETED, msg) {}
00104   protected:
00105     std::string getPrefix() const { return "ResourceDeletedException"; }
00106 };
00107 
00113 struct IllegalStateException:
00114     public SessionAbortedException
00115 {
00116     IllegalStateException(const std::string& msg=std::string())
00117         : SessionAbortedException(execution::ILLEGAL_STATE, msg) {}
00118   protected:
00119     std::string getPrefix() const { return "IllegalStateException"; }
00120 };
00121 
00127 struct CommandInvalidException:
00128     public SessionAbortedException
00129 {
00130     CommandInvalidException(const std::string& msg=std::string())
00131         : SessionAbortedException(execution::COMMAND_INVALID, msg) {}
00132   protected:
00133     std::string getPrefix() const { return "CommandInvalidException"; }
00134 };
00135 
00141 struct ResourceLimitExceededException:
00142     public SessionAbortedException
00143 {
00144     ResourceLimitExceededException(const std::string& msg=std::string())
00145         : SessionAbortedException(execution::RESOURCE_LIMIT_EXCEEDED, msg) {}
00146   protected:
00147     std::string getPrefix() const { return "ResourceLimitExceededException"; }
00148 };
00149 
00156 struct NotAllowedException:
00157     public SessionAbortedException
00158 {
00159     NotAllowedException(const std::string& msg=std::string())
00160         : SessionAbortedException(execution::NOT_ALLOWED, msg) {}
00161   protected:
00162     std::string getPrefix() const { return "NotAllowedException"; }
00163 };
00164 
00172 struct IllegalArgumentException:
00173     public SessionAbortedException
00174 {
00175     IllegalArgumentException(const std::string& msg=std::string())
00176         : SessionAbortedException(execution::ILLEGAL_ARGUMENT, msg) {}
00177   protected:
00178     std::string getPrefix() const { return "IllegalArgumentException"; }
00179 };
00180 
00186 struct NotImplementedException:
00187     public SessionAbortedException
00188 {
00189     NotImplementedException(const std::string& msg=std::string())
00190         : SessionAbortedException(execution::NOT_IMPLEMENTED, msg) {}
00191   protected:
00192     std::string getPrefix() const { return "NotImplementedException"; }
00193 };
00194 
00201 struct InternalErrorException:
00202     public SessionAbortedException
00203 {
00204     InternalErrorException(const std::string& msg=std::string())
00205         : SessionAbortedException(execution::INTERNAL_ERROR, msg) {}
00206   protected:
00207     std::string getPrefix() const { return "InternalErrorException"; }
00208 };
00209 
00217 struct InvalidArgumentException:
00218     public SessionAbortedException
00219 {
00220     InvalidArgumentException(const std::string& msg=std::string())
00221         : SessionAbortedException(execution::INVALID_ARGUMENT, msg) {}
00222   protected:
00223     std::string getPrefix() const { return "InvalidArgumentException"; }
00224 };
00225 
00226 
00232 struct NormalDetachedException:
00233     public SessionDetachedException
00234 {
00235     NormalDetachedException(const std::string& msg=std::string())
00236         : SessionDetachedException(session::NORMAL, msg) {}
00237   protected:
00238     std::string getPrefix() const { return "NormalDetachedException"; }
00239 };
00240 
00246 struct SessionBusyDetachedException:
00247     public SessionDetachedException
00248 {
00249     SessionBusyDetachedException(const std::string& msg=std::string())
00250         : SessionDetachedException(session::SESSION_BUSY, msg) {}
00251   protected:
00252     std::string getPrefix() const { return "SessionBusyDetachedException"; }
00253 };
00254 
00260 struct TransportBusyDetachedException:
00261     public SessionDetachedException
00262 {
00263     TransportBusyDetachedException(const std::string& msg=std::string())
00264         : SessionDetachedException(session::TRANSPORT_BUSY, msg) {}
00265   protected:
00266     std::string getPrefix() const { return "TransportBusyDetachedException"; }
00267 };
00268 
00274 struct NotAttachedDetachedException:
00275     public SessionDetachedException
00276 {
00277     NotAttachedDetachedException(const std::string& msg=std::string())
00278         : SessionDetachedException(session::NOT_ATTACHED, msg) {}
00279   protected:
00280     std::string getPrefix() const { return "NotAttachedDetachedException"; }
00281 };
00282 
00288 struct UnknownIdsDetachedException:
00289     public SessionDetachedException
00290 {
00291     UnknownIdsDetachedException(const std::string& msg=std::string())
00292         : SessionDetachedException(session::UNKNOWN_IDS, msg) {}
00293   protected:
00294     std::string getPrefix() const { return "UnknownIdsDetachedException"; }
00295 };
00296 
00297 
00303 struct NormalExpiredException:
00304     public SessionExpiredException
00305 {
00306     NormalExpiredException(const std::string& msg=std::string())
00307         : SessionExpiredException(session::NORMAL, msg) {}
00308   protected:
00309     std::string getPrefix() const { return "NormalExpiredException"; }
00310 };
00311 
00317 struct SessionBusyExpiredException:
00318     public SessionExpiredException
00319 {
00320     SessionBusyExpiredException(const std::string& msg=std::string())
00321         : SessionExpiredException(session::SESSION_BUSY, msg) {}
00322   protected:
00323     std::string getPrefix() const { return "SessionBusyExpiredException"; }
00324 };
00325 
00331 struct TransportBusyExpiredException:
00332     public SessionExpiredException
00333 {
00334     TransportBusyExpiredException(const std::string& msg=std::string())
00335         : SessionExpiredException(session::TRANSPORT_BUSY, msg) {}
00336   protected:
00337     std::string getPrefix() const { return "TransportBusyExpiredException"; }
00338 };
00339 
00345 struct NotAttachedExpiredException:
00346     public SessionExpiredException
00347 {
00348     NotAttachedExpiredException(const std::string& msg=std::string())
00349         : SessionExpiredException(session::NOT_ATTACHED, msg) {}
00350   protected:
00351     std::string getPrefix() const { return "NotAttachedExpiredException"; }
00352 };
00353 
00359 struct UnknownIdsExpiredException:
00360     public SessionExpiredException
00361 {
00362     UnknownIdsExpiredException(const std::string& msg=std::string())
00363         : SessionExpiredException(session::UNKNOWN_IDS, msg) {}
00364   protected:
00365     std::string getPrefix() const { return "UnknownIdsExpiredException"; }
00366 };
00367 
00368 
00374 struct NormalException:
00375     public ConnectionException
00376 {
00377     NormalException(const std::string& msg=std::string())
00378         : ConnectionException(connection::NORMAL, msg) {}
00379   protected:
00380     std::string getPrefix() const { return "NormalException"; }
00381 };
00382 
00389 struct ConnectionForcedException:
00390     public ConnectionException
00391 {
00392     ConnectionForcedException(const std::string& msg=std::string())
00393         : ConnectionException(connection::CONNECTION_FORCED, msg) {}
00394   protected:
00395     std::string getPrefix() const { return "ConnectionForcedException"; }
00396 };
00397 
00403 struct InvalidPathException:
00404     public ConnectionException
00405 {
00406     InvalidPathException(const std::string& msg=std::string())
00407         : ConnectionException(connection::INVALID_PATH, msg) {}
00408   protected:
00409     std::string getPrefix() const { return "InvalidPathException"; }
00410 };
00411 
00417 struct FramingErrorException:
00418     public ConnectionException
00419 {
00420     FramingErrorException(const std::string& msg=std::string())
00421         : ConnectionException(connection::FRAMING_ERROR, msg) {}
00422   protected:
00423     std::string getPrefix() const { return "FramingErrorException"; }
00424 };
00425 
00426 }} // namespace qpid::amqp_0_10
00427 
00428 #endif  

Generated on Thu Apr 10 11:08:15 2008 for Qpid by  doxygen 1.4.7