MeVisLab Toolbox Reference
mlSphereList.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#ifndef ML_SPHERE_LIST_H
14#define ML_SPHERE_LIST_H
15
16
18
19//ML-includes
20#include "mlBaseInit.h"
21#include <mlModuleIncludes.h>
22#include <mlSphere.h>
23
25
26// ------------------------------------------------------------------
28// ------------------------------------------------------------------
30
31public:
33 ~SphereList() override {};
34
37
39 void getValue(MLssize_t index, Sphere& obj) const;
40
43
45 Sphere* getPtr(MLssize_t index = -1);
46
48 void addValue(const Sphere& obj);
49
51 void setValue(MLssize_t index, const Sphere& obj);
52
54 void removeValue(MLssize_t index = -1);
55
57 void clear();
58
60 void print(const char* txt);
61
62private:
63
66
68 std::vector<Sphere> objects;
69};
70
72
73#endif // __mlSphereList
Class representing general ML objects that support import/export via strings (setPersistentState() an...
Definition mlBase.h:59
Base object managing a list of Sphere objects.
void clear()
clear all entries
void addValue(const Sphere &obj)
add Sphere at end of list
~SphereList() override
Sphere getValue(MLssize_t index) const
get Sphere at given index
void getValue(MLssize_t index, Sphere &obj) const
get Sphere at given index
void removeValue(MLssize_t index=-1)
remove Sphere from list, if index is -1, last element is removed
void print(const char *txt)
debug print
Sphere * getPtr(MLssize_t index=-1)
get Pointer to Sphere at given index, if index is -1, last element is given
MLssize_t getNum() const
returns the number of contained Spheres
void setValue(MLssize_t index, const Sphere &obj)
set value at index
Defines the class to handle the geometry primitive "Sphere" with a radius and a center point.
Definition mlSphere.h:29
#define MLBASEEXPORT
defined Header file mlBaseInit.h
Definition mlBaseInit.h:22
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
#define ML_CLASS_HEADER(className)
Same like ML_CLASS_HEADER_EXPORTED with a non existing export symbol.
SSIZE_T MLssize_t
The signed ML size type which is a signed 32 bit size_t on 32 bit platforms and 64 bit one on 64 bit ...
Definition mlTypeDefs.h:566