godot/core/object/object.cpp

/**************************************************************************/
/*  object.cpp                                                            */
/**************************************************************************/
/*                         This file is part of:                          */
/*                             GODOT ENGINE                               */
/*                        https://godotengine.org                         */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur.                  */
/*                                                                        */
/* Permission is hereby granted, free of charge, to any person obtaining  */
/* a copy of this software and associated documentation files (the        */
/* "Software"), to deal in the Software without restriction, including    */
/* without limitation the rights to use, copy, modify, merge, publish,    */
/* distribute, sublicense, and/or sell copies of the Software, and to     */
/* permit persons to whom the Software is furnished to do so, subject to  */
/* the following conditions:                                              */
/*                                                                        */
/* The above copyright notice and this permission notice shall be         */
/* included in all copies or substantial portions of the Software.        */
/*                                                                        */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,        */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF     */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY   */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,   */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE      */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.                 */
/**************************************************************************/

#include "object.h"
#include "object.compat.inc"

#include "core/extension/gdextension_manager.h"
#include "core/io/resource.h"
#include "core/object/class_db.h"
#include "core/object/message_queue.h"
#include "core/object/script_language.h"
#include "core/os/os.h"
#include "core/string/print_string.h"
#include "core/string/translation_server.h"
#include "core/templates/local_vector.h"
#include "core/variant/typed_array.h"

#ifdef DEBUG_ENABLED

struct _ObjectDebugLock {};

#define OBJ_DEBUG_LOCK

#else

#define OBJ_DEBUG_LOCK

#endif

operator Dictionary()

PropertyInfo PropertyInfo::from_dict(const Dictionary &p_dict) {}

TypedArray<Dictionary> convert_property_list(const List<PropertyInfo> *p_list) {}

operator Dictionary()

MethodInfo MethodInfo::from_dict(const Dictionary &p_dict) {}

operator Variant()

bool Object::Connection::operator<(const Connection &p_conn) const {}

Object::Connection::Connection(const Variant &p_variant) {}

bool Object::_predelete() {}

void Object::cancel_free() {}

void Object::_initialize() {}

void Object::_postinitialize() {}

void Object::get_valid_parents_static(List<String> *p_parents) {}

void Object::_get_valid_parents_static(List<String> *p_parents) {}

void Object::set(const StringName &p_name, const Variant &p_value, bool *r_valid) {}

Variant Object::get(const StringName &p_name, bool *r_valid) const {}

void Object::set_indexed(const Vector<StringName> &p_names, const Variant &p_value, bool *r_valid) {}

Variant Object::get_indexed(const Vector<StringName> &p_names, bool *r_valid) const {}

void Object::get_property_list(List<PropertyInfo> *p_list, bool p_reversed) const {}

void Object::validate_property(PropertyInfo &p_property) const {}

bool Object::property_can_revert(const StringName &p_name) const {}

Variant Object::property_get_revert(const StringName &p_name) const {}

void Object::get_method_list(List<MethodInfo> *p_list) const {}

Variant Object::_call_bind(const Variant **p_args, int p_argcount, Callable::CallError &r_error) {}

Variant Object::_call_deferred_bind(const Variant **p_args, int p_argcount, Callable::CallError &r_error) {}

bool Object::has_method(const StringName &p_method) const {}

int Object::_get_method_argument_count_bind(const StringName &p_method) const {}

int Object::get_method_argument_count(const StringName &p_method, bool *r_is_valid) const {}

Variant Object::getvar(const Variant &p_key, bool *r_valid) const {}

void Object::setvar(const Variant &p_key, const Variant &p_value, bool *r_valid) {}

Variant Object::callv(const StringName &p_method, const Array &p_args) {}

Variant Object::callp(const StringName &p_method, const Variant **p_args, int p_argcount, Callable::CallError &r_error) {}

Variant Object::call_const(const StringName &p_method, const Variant **p_args, int p_argcount, Callable::CallError &r_error) {}

void Object::notification(int p_notification, bool p_reversed) {}

String Object::to_string() {}

void Object::set_script_and_instance(const Variant &p_script, ScriptInstance *p_instance) {}

void Object::set_script(const Variant &p_script) {}

void Object::set_script_instance(ScriptInstance *p_instance) {}

Variant Object::get_script() const {}

bool Object::has_meta(const StringName &p_name) const {}

void Object::set_meta(const StringName &p_name, const Variant &p_value) {}

Variant Object::get_meta(const StringName &p_name, const Variant &p_default) const {}

void Object::remove_meta(const StringName &p_name) {}

void Object::merge_meta_from(const Object *p_src) {}

TypedArray<Dictionary> Object::_get_property_list_bind() const {}

TypedArray<Dictionary> Object::_get_method_list_bind() const {}

TypedArray<StringName> Object::_get_meta_list_bind() const {}

void Object::get_meta_list(List<StringName> *p_list) const {}

void Object::add_user_signal(const MethodInfo &p_signal) {}

bool Object::_has_user_signal(const StringName &p_name) const {}

void Object::_remove_user_signal(const StringName &p_name) {}

Error Object::_emit_signal(const Variant **p_args, int p_argcount, Callable::CallError &r_error) {}

Error Object::emit_signalp(const StringName &p_name, const Variant **p_args, int p_argcount) {}

void Object::_add_user_signal(const String &p_name, const Array &p_args) {}

TypedArray<Dictionary> Object::_get_signal_list() const {}

TypedArray<Dictionary> Object::_get_signal_connection_list(const StringName &p_signal) const {}

TypedArray<Dictionary> Object::_get_incoming_connections() const {}

bool Object::has_signal(const StringName &p_name) const {}

void Object::get_signal_list(List<MethodInfo> *p_signals) const {}

void Object::get_all_signal_connections(List<Connection> *p_connections) const {}

void Object::get_signal_connection_list(const StringName &p_signal, List<Connection> *p_connections) const {}

int Object::get_persistent_signal_connection_count() const {}

void Object::get_signals_connected_to_this(List<Connection> *p_connections) const {}

Error Object::connect(const StringName &p_signal, const Callable &p_callable, uint32_t p_flags) {}

bool Object::is_connected(const StringName &p_signal, const Callable &p_callable) const {}

void Object::disconnect(const StringName &p_signal, const Callable &p_callable) {}

bool Object::_disconnect(const StringName &p_signal, const Callable &p_callable, bool p_force) {}

void Object::_set_bind(const StringName &p_set, const Variant &p_value) {}

Variant Object::_get_bind(const StringName &p_name) const {}

void Object::_set_indexed_bind(const NodePath &p_name, const Variant &p_value) {}

Variant Object::_get_indexed_bind(const NodePath &p_name) const {}

void Object::initialize_class() {}

String Object::tr(const StringName &p_message, const StringName &p_context) const {}

String Object::tr_n(const StringName &p_message, const StringName &p_message_plural, int p_n, const StringName &p_context) const {}

void Object::_clear_internal_resource_paths(const Variant &p_var) {}

#ifdef TOOLS_ENABLED
void Object::editor_set_section_unfold(const String &p_section, bool p_unfolded) {}

bool Object::editor_is_section_unfolded(const String &p_section) {}

#endif

void Object::clear_internal_resource_paths() {}

void Object::notify_property_list_changed() {}

void Object::_bind_methods() {}

void Object::set_deferred(const StringName &p_property, const Variant &p_value) {}

void Object::set_block_signals(bool p_block) {}

bool Object::is_blocking_signals() const {}

Variant::Type Object::get_static_property_type(const StringName &p_property, bool *r_valid) const {}

Variant::Type Object::get_static_property_type_indexed(const Vector<StringName> &p_path, bool *r_valid) const {}

bool Object::is_queued_for_deletion() const {}

#ifdef TOOLS_ENABLED
void Object::set_edited(bool p_edited) {}

bool Object::is_edited() const {}

uint32_t Object::get_edited_version() const {}
#endif

StringName Object::get_class_name_for_extension(const GDExtension *p_library) const {}

void Object::set_instance_binding(void *p_token, void *p_binding, const GDExtensionInstanceBindingCallbacks *p_callbacks) {}

void *Object::get_instance_binding(void *p_token, const GDExtensionInstanceBindingCallbacks *p_callbacks) {}

bool Object::has_instance_binding(void *p_token) {}

void Object::free_instance_binding(void *p_token) {}

#ifdef TOOLS_ENABLED
void Object::clear_internal_extension() {}

void Object::reset_internal_extension(ObjectGDExtension *p_extension) {}
#endif

void Object::_construct_object(bool p_reference) {}

Object::Object(bool p_reference) {}

Object::Object() {}

void Object::detach_from_objectdb() {}

Object::~Object() {}

bool predelete_handler(Object *p_object) {}

void postinitialize_handler(Object *p_object) {}

void ObjectDB::debug_objects(DebugFunc p_func) {}

#ifdef TOOLS_ENABLED
void Object::get_argument_options(const StringName &p_function, int p_idx, List<String> *r_options) const {}
#endif

SpinLock ObjectDB::spin_lock;
uint32_t ObjectDB::slot_count =;
uint32_t ObjectDB::slot_max =;
ObjectDB::ObjectSlot *ObjectDB::object_slots =;
uint64_t ObjectDB::validator_counter =;

int ObjectDB::get_object_count() {}

ObjectID ObjectDB::add_instance(Object *p_object) {}

void ObjectDB::remove_instance(Object *p_object) {}

void ObjectDB::setup() {}

void ObjectDB::cleanup() {}