Remove old DowncastReturnedValue policy

It is replaced by ToWeakPtrWithDowncast & ToSharedPtrWithDowncast policies.
The DowncastRegistry now maps DataItem::id strings to the interfaces classes
that the DataItem obejects should be cast to when returning to Python
Refs #8996
Add a class to do all required registration for a DataItem subclass

It encapsulates everything required for pointer & downcast registration.
Refs #8996
Remove the SharedPtrToPython macro.

It's unnecessary now as a direct boost::python call is clearer.
Refs #8996
Remove DowncastReturnedValue from CMakeLists.txt

Refs #8996
Remove SharedPtrToPythonMacro from CmakeLists

Refs #8996
Refactor TypeRegistry to use a static class like the DowncastRegistry.

Refs #8996
Use new RegisterDataItemInterface class in place of macro

This now does the required additional registration for workspace types.
Refs #8996
Put back ADS raising KeyError rather than RuntimeError.

Refs #8996
Remove redundant code.

The SingleValueTypeHandler is now replaced everywhere by the
TypedPropertyValueHandler.
Refs #8996
Tidy up PropertyWithValueFactory.

Remove macro usage and store shared_ptrs in map.
Refs #8996
Dynamic cast when setting property from weak_ptr in python

This accounts for multiple-inheritance scenarios where a static_cast
cannot detect that a cast is actually possible.
Refs #8996
Add missing include for exception type.

Refs #8996
Fix type for map insertion in TypeRegistry

Refs #8996
Fix Python function tests.

They were calling getProperty().value on a non-child algorithm where the
internal workspace pointer is null.
Refs #8996
Check for null pointer in DowncastingPolicies.

The return is now just the PyNone object.
Refs #8996
Fix passing weak_ptrs back to C++ from Python layer.

Refs #8996
Rename RegisterDataItemInterface to DataItemInterface.

Refs #8996
Remove a macro in favour of direct WorkspacePropertyExporter usage.

Refs #8996
Remove another macro in favour of a templated static class

Refs #8996
Remove another macro in a header in favour of template class

Refs #8996