3#ifndef HORIZON_CORE_STRUCTURES_REFERENCE_HPP
4#define HORIZON_CORE_STRUCTURES_REFERENCE_HPP
26template <
class TO,
class FROM>
49 void link(TO *toObj, FROM *fromObj)
58 if (toObj !=
nullptr) {
This class is used to manage a linked list of Elements. It is not intended to be used directly....
Definition: Element.hpp:18
Element * next()
Returns the next Element in the list.
Definition: Element.hpp:36
void delink()
Removes this Element from the list.
Definition: Element.hpp:50
Element * nocheck_prev()
Returns the previous Element in the list without checking if it exists.
Definition: Element.hpp:46
Element * prev()
Returns the previous Element in the list.
Definition: Element.hpp:39
Element * nocheck_next()
Returns the next Element in the list without checking if it exists.
Definition: Element.hpp:43
Definition: Reference.hpp:28
void invalidate()
Definition: Reference.hpp:77
void link(TO *toObj, FROM *fromObj)
Links the Reference to the specified object by adding it to the front of the list.
Definition: Reference.hpp:49
TO * target() const
Definition: Reference.hpp:100
Reference< TO, FROM > const * next() const
Definition: Reference.hpp:90
FROM * _ref_from
Definition: Reference.hpp:31
virtual void target_object_destroy_link()=0
Reference< TO, FROM > * prev()
Definition: Reference.hpp:91
Reference< TO, FROM > const * prev() const
Definition: Reference.hpp:92
virtual void source_object_destroy_link()=0
FROM * source() const
Definition: Reference.hpp:102
Reference< TO, FROM > * nocheck_next()
Definition: Reference.hpp:94
bool is_valid() const
Definition: Reference.hpp:84
Reference< TO, FROM > const * nocheck_prev() const
Definition: Reference.hpp:97
void remove()
Definition: Reference.hpp:67
TO * _ref_to
Definition: Reference.hpp:30
TO * operator->() const
Definition: Reference.hpp:99
Reference< TO, FROM > * next()
Definition: Reference.hpp:89
virtual ~Reference()
Definition: Reference.hpp:44
Reference()
Definition: Reference.hpp:43
Reference & operator=(Reference const &)=delete
Reference< TO, FROM > const * nocheck_next() const
Definition: Reference.hpp:95
Reference(Reference const &)=delete
Reference< TO, FROM > * nocheck_prev()
Definition: Reference.hpp:96
virtual void target_object_build_link()=0
Definition: Element.hpp:7