summaryrefslogtreecommitdiff
path: root/modules/mono/mono_gd/gd_mono_class.cpp
diff options
context:
space:
mode:
authorIgnacio Etcheverry <ignalfonsore@gmail.com>2019-03-05 18:52:19 +0100
committerIgnacio Etcheverry <ignalfonsore@gmail.com>2019-04-06 12:14:37 +0200
commit187e6ae26d88ab0975de6011d00e41a846bcb6fa (patch)
tree7570d10203d67528e61fbf24e2da2a082c35d6af /modules/mono/mono_gd/gd_mono_class.cpp
parent92b02cb027a5f87b7ebe069ed1ba7648b6db19bd (diff)
C#: Add marshalling support for IEnumerable and IDictionary
Added constructor that takes IEnumerable for Array and IEnumerable<T> for Array<T>. Added constructor that takes IDictionary for Dictionary and IDictionary<TKey, TValue> for Dictionary<TKey, TValue>.
Diffstat (limited to 'modules/mono/mono_gd/gd_mono_class.cpp')
-rw-r--r--modules/mono/mono_gd/gd_mono_class.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/mono/mono_gd/gd_mono_class.cpp b/modules/mono/mono_gd/gd_mono_class.cpp
index 92324d73f9..d58f675d19 100644
--- a/modules/mono/mono_gd/gd_mono_class.cpp
+++ b/modules/mono/mono_gd/gd_mono_class.cpp
@@ -260,6 +260,11 @@ bool GDMonoClass::has_fetched_method_unknown_params(const StringName &p_name) {
return get_fetched_method_unknown_params(p_name) != NULL;
}
+bool GDMonoClass::implements_interface(GDMonoClass *p_interface) {
+
+ return mono_class_implements_interface(mono_class, p_interface->get_mono_ptr());
+}
+
GDMonoMethod *GDMonoClass::get_method(const StringName &p_name, int p_params_count) {
MethodKey key = MethodKey(p_name, p_params_count);