libcommonc++  0.7
JavaException.h++
Go to the documentation of this file.
1 /* ---------------------------------------------------------------------------
2  commonc++ - A C++ Common Class Library
3  Copyright (C) 2005-2014 Mark A Lindner
4 
5  This file is part of commonc++.
6 
7  This library is free software; you can redistribute it and/or
8  modify it under the terms of the GNU Library General Public
9  License as published by the Free Software Foundation; either
10  version 2 of the License, or (at your option) any later version.
11 
12  This library is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  Library General Public License for more details.
16 
17  You should have received a copy of the GNU Library General Public
18  License along with this library; if not, write to the Free
19  Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20  ---------------------------------------------------------------------------
21 */
22 
23 #ifndef __ccxx_JavaException_hxx
24 #define __ccxx_JavaException_hxx
25 
26 #include <commonc++/Common.h++>
27 #include <commonc++/Exception.h++>
28 
29 namespace ccxx {
30 
37 {
38  public:
39 
42 
43  inline virtual void write(std::ostream& stream) const
44  { _write(stream, "JavaException"); }
45 };
46 
52 {
53  public:
54 
56 
57  inline void write(std::ostream& stream) const
58  { _write(stream, "JavaSignatureException"); }
59 };
60 
67 {
68  public:
69 
71 
72  inline void write(std::ostream& stream) const
73  { _write(stream, "JavaClassNotFoundException"); }
74 };
75 
83 {
84  public:
85 
87 
88  inline void write(std::ostream& stream) const
89  { _write(stream, "JavaMethodNotFoundException"); }
90 };
91 
99 {
100  public:
101 
103 
104  inline void write(std::ostream& stream) const
105  { _write(stream, "JavaFieldNotFoundException"); }
106 };
107 
115 {
116  public:
117 
119 
120  inline void write(std::ostream& stream) const
121  { _write(stream, "JavaInstantiationException"); }
122 };
123 
131 {
132  public:
133 
135 
136  inline void write(std::ostream& stream) const
137  { _write(stream, "JavaInvocationException"); }
138 };
139 
146 {
147  public:
148 
150 
151  inline void write(std::ostream& stream) const
152  { _write(stream, "JavaFieldAccessException"); }
153 };
154 
162 {
163  public:
164 
166 
167  inline void write(std::ostream& stream) const
168  { _write(stream, "JavaArrayAccessException"); }
169 };
170 
178 {
179  public:
180 
182 
183  inline void write(std::ostream& stream) const
184  { _write(stream, "JavaOutOfMemoryException"); }
185 };
186 
193 {
194  public:
195 
197 
198  inline void write(std::ostream& stream) const
199  { _write(stream, "JavaMonitorException"); }
200 };
201 
209 {
210  public:
211 
213 
214  inline void write(std::ostream& stream) const
215  { _write(stream, "JavaThreadException"); }
216 };
217 
225 {
226  public:
227 
229 
230  inline void write(std::ostream& stream) const
231  { _write(stream, "JavaNotAttachedException"); }
232 };
233 
242 {
243  public:
244 
250 
251  inline void write(std::ostream& stream) const
252  { _write(stream, "JavaClassLoaderException"); }
253 };
254 
255 } // namespace ccxx
256 
257 #endif // __ccxx_JavaException_hxx
An exception indicating that a requested method of a Java class was not found.
Definition: JavaException.h++:82
An exception indicating that a requested Java class was not found.
Definition: JavaException.h++:66
#define COMMONCPPJVM_API
Definition: Common.h++:128
static const String empty
The empty string.
Definition: String.h++:1134
An exception indicating a native thread attach or detach operation failed.
Definition: JavaException.h++:208
A base class for all Java Virtual Machine exceptions.
Definition: JavaException.h++:36
An exception indicating an illegal monitor state.
Definition: JavaException.h++:192
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:214
An exception indicating that a call was made from a native thread that is not attached to the JVM...
Definition: JavaException.h++:224
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:151
An exception indicating exhaustion of heap space in the Java Virtual Machine.
Definition: JavaException.h++:177
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:167
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:136
An exception indicating that a requested field of a Java class was not found.
Definition: JavaException.h++:98
An exception indicating that a Java exception occurred while invoking a Java method.
Definition: JavaException.h++:130
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:198
An exception indicating that a Java method signature string was malformed.
Definition: JavaException.h++:51
virtual void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:43
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:251
An exception indicating an attempt to store a value of an inappropriate type into a Java array...
Definition: JavaException.h++:161
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:104
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:230
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:57
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:88
A flexible, reference counted, copy-on-write, thread-safe, nullable string.
Definition: String.h++:50
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:120
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:183
An exception indicating that an error occurred while instantiating a Java class.
Definition: JavaException.h++:114
void write(std::ostream &stream) const
Write a textual representation of the exception to a stream.
Definition: JavaException.h++:72
An exception indicating that the raw bytecode for a class could not be loaded because of a class form...
Definition: JavaException.h++:241
Definition: AllocationMap.c++:25
An exception indicating an attempt at an invalid field access.
Definition: JavaException.h++:145
A general-purpose exception.
Definition: Exception.h++:39