MeVisLab Toolbox Reference
mlVTKMLBaseWrapper.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2007, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#pragma once
14
17
19#include <mlModuleIncludes.h>
20
21#include <vtkObject.h>
22#include <vtkSmartPointer.h>
23
25
26//----------------------------------------------------------------------------------
30//----------------------------------------------------------------------------------
32{
33public:
35
37
39
40 template <class T> T* object()
41 {
42 return T::SafeDownCast(wrappedObject());
43 }
44
45 std::string detailString() const override;
46
47protected:
49
52};
53
55
@ T
RefCountedBase class adds intrusive reference counting support to the Base class.
Helper class to have a common base class for all derived wrapper.
ML_ABSTRACT_CLASS_HEADER(VTKObjectWrapper)
Register this class abstractly.
VTKObjectWrapper(vtkObject *obj)
std::string detailString() const override
Return a string describing this object.
vtkObject * wrappedObject()
#define MLVTK_SUPPORT_EXPORT
When included by other libraries MLVTK_SUPPORT_EXPORT is compiled as import symbol.
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
#define ML_REFCOUNTED_PTR(CLASSNAME)
Macro that defines convenience Ptr/ConstPtr typedefs to be used instead of intrusive_ptr templates.