#ifndef H_CORAL_UTIL_CHECK_BIDI_SLOTS
#define H_CORAL_UTIL_CHECK_BIDI_SLOTS
// This file is part of the Coral project.
// Please read the copyright notice in the LICENSE file.

#include <coral/core/Element.h>

namespace coral {
	namespace util {
		/*
		 * Checks and adds the opposite end of a dangling bidi link,
		 * or deletes it if the addition isn't possible.
		 * Note that this can kill the root element,
		 * so use e.g. a coral::TempReference on it before
		 * calling.
		 *
		 * This is really a quite crude hack for XMI
		 * loaders that only set one end of a bidirectional
		 * connection.
		 *
		 * This function deserves to die.
		 */
		void check_bidi_slots(Element* root);
	}
}


#endif
