Merge pull request #2394 from Mailaender/patch-1
[mono.git] / mono / metadata / exception.h
index 7f191d1989b9c3371a2dc9a64923b0631d182c34..b9b82dd7427943455cfdd4bd0c4a53638f57f262 100644 (file)
 #ifndef _MONO_METADATA_EXCEPTION_H_
 #define _MONO_METADATA_EXCEPTION_H_
 
-/* here for compat: should not be used anymore */
-#define MONO_ARCH_SAVE_REGS 
-
 #include <mono/metadata/object.h>
 #include <mono/metadata/image.h>
 
-G_BEGIN_DECLS
+MONO_BEGIN_DECLS
 
-extern MonoException *
+extern MONO_API MonoException *
 mono_exception_from_name               (MonoImage *image, 
                                        const char* name_space, 
                                        const char *name);
 
-MonoException *
-mono_exception_from_token              (MonoImage *image, guint32 token);
+MONO_API MonoException *
+mono_exception_from_token              (MonoImage *image, uint32_t token);
 
-MonoException *
+MONO_API MonoException *
 mono_exception_from_name_two_strings (MonoImage *image, const char *name_space,
                                      const char *name, MonoString *a1, MonoString *a2);
 
-MonoException *
+MONO_API MonoException *
 mono_exception_from_name_msg          (MonoImage *image, const char *name_space,
                                        const char *name, const char *msg);
 
-extern MonoException *
+MONO_API MonoException *
+mono_exception_from_token_two_strings (MonoImage *image, uint32_t token,
+                                                  MonoString *a1, MonoString *a2);
+
+extern MONO_API MonoException *
 mono_exception_from_name_domain        (MonoDomain *domain, MonoImage *image, 
                                        const char* name_space, 
                                        const char *name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_divide_by_zero      (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_security            (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_arithmetic          (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_overflow            (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_null_reference      (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_execution_engine    (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_thread_abort        (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_thread_state        (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_thread_interrupted  (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_serialization       (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_invalid_cast        (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_invalid_operation (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_index_out_of_range  (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_array_type_mismatch (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_type_load           (MonoString *class_name, char *assembly_name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_missing_method      (const char *class_name, const char *member_name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_missing_field       (const char *class_name, const char *member_name);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_not_implemented     (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_not_supported       (const char *msg);
 
-MonoException*
+MONO_API MonoException*
 mono_get_exception_argument_null       (const char *arg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_argument            (const char *arg, const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_argument_out_of_range (const char *arg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_io                    (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_file_not_found        (MonoString *fname);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_file_not_found2       (const char *msg, MonoString *fname);
 
-MonoException *
-mono_get_exception_type_initialization (const gchar *type_name, MonoException *inner);
+MONO_RT_EXTERNAL_ONLY
+MONO_API MonoException *
+mono_get_exception_type_initialization (const char *type_name, MonoException *inner);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_synchronization_lock (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_cannot_unload_appdomain (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_appdomain_unloaded (void);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_bad_image_format (const char *msg);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_bad_image_format2 (const char *msg, MonoString *fname);
 
-MonoException *
+MONO_API MonoException *
 mono_get_exception_stack_overflow (void);
 
-MonoException *
+MONO_API MonoException *
+mono_get_exception_out_of_memory (void);
+
+MONO_API MonoException *
+mono_get_exception_field_access (void);
+
+MONO_API MonoException *
+mono_get_exception_method_access (void);
+
+MONO_RT_EXTERNAL_ONLY
+MONO_API MonoException *
 mono_get_exception_reflection_type_load (MonoArray *types, MonoArray *exceptions);
 
-G_END_DECLS
+MONO_RT_EXTERNAL_ONLY
+MONO_API MonoException *
+mono_get_exception_runtime_wrapped (MonoObject *wrapped_exception);
+
+MONO_END_DECLS
 
 #endif /* _MONO_METADATA_EXCEPTION_H_ */