playrho::d2::DestructionListener Class Referenceabstract

#include <WorldCallbacks.hpp>

Public Member Functions

virtual ~DestructionListener () noexcept=default
 
virtual void SayGoodbye (const Joint &joint) noexcept=0
 Called just before destroying a joint. More...
 
virtual void SayGoodbye (const Fixture &fixture) noexcept=0
 Called just before destroying a fixture. More...
 

Detailed Description

Joints and fixtures are destroyed when their associated body is destroyed. Implement this listener so that you may nullify references to these joints and shapes.

Examples
World.cpp.

Definition at line 38 of file WorldCallbacks.hpp.

Constructor & Destructor Documentation

◆ ~DestructionListener()

virtual playrho::d2::DestructionListener::~DestructionListener ( )
virtualdefaultnoexcept

Member Function Documentation

◆ SayGoodbye() [1/2]

virtual void playrho::d2::DestructionListener::SayGoodbye ( const Joint joint)
pure virtualnoexcept

Called just before destroying a joint.

Called when any joint is about to be destroyed due to the destruction of one of its attached bodies.

Note
Implementations of this method should not throw any exceptions.

◆ SayGoodbye() [2/2]

virtual void playrho::d2::DestructionListener::SayGoodbye ( const Fixture fixture)
pure virtualnoexcept

Called just before destroying a fixture.

Called when any fixture is about to be destroyed due to the destruction of its parent body.

Note
Implementations of this method should not throw any exceptions.

The documentation for this class was generated from the following file: