| IOLink 1.11.0

Loading...
Searching...
No Matches
MetadataNodeIterator.h
1#pragma once
2
3#include <memory>
4
5#include <iolink/IOLinkAPI.h>
6
7 namespace iolink
8{
9 class MetadataIteratorObject;
10 class MetadataNode;
11
15 class IOLINK_API MetadataNodeIterator
16{
17 public:
18 MetadataNodeIterator();
19 explicit MetadataNodeIterator(MetadataIteratorObject* it);
20 MetadataNodeIterator(const MetadataNodeIterator& mit);
21
22 ~MetadataNodeIterator();
23
24 MetadataNodeIterator& operator=(const MetadataNodeIterator& it);
25
26 bool next();
27 std::shared_ptr<MetadataNode> value();
28
29 MetadataNodeIterator& operator++();
30 MetadataNodeIterator operator++(int);
31 bool operator==(const MetadataNodeIterator& rhs) const;
32 bool operator!=(const MetadataNodeIterator& rhs) const;
33 std::shared_ptr<MetadataNode> operator*();
34 std::shared_ptr<MetadataNode> operator->();
35
36 private:
37 MetadataIteratorObject* m_object;
38};
39
40 class ConstMetadataIteratorObject;
41
45 class IOLINK_API ConstMetadataNodeIterator
46{
47 public:
48 ConstMetadataNodeIterator();
49 explicit ConstMetadataNodeIterator(ConstMetadataIteratorObject* it);
50 ConstMetadataNodeIterator(const ConstMetadataNodeIterator& mit);
51
52 ~ConstMetadataNodeIterator();
53
54 ConstMetadataNodeIterator& operator=(const ConstMetadataNodeIterator& it);
55
56 bool next();
57 std::shared_ptr<const MetadataNode> value();
58
59 ConstMetadataNodeIterator& operator++();
60 ConstMetadataNodeIterator operator++(int);
61 bool operator==(const ConstMetadataNodeIterator& rhs) const;
62 bool operator!=(const ConstMetadataNodeIterator& rhs) const;
63 std::shared_ptr<const MetadataNode> operator*();
64 std::shared_ptr<const MetadataNode> operator->();
65
66 private:
67 ConstMetadataIteratorObject* m_object;
68};
69
70} // namespace iolink
iolink::ConstMetadataNodeIterator
Class represents a const iterator on a list of Metadata nodes.
Definition MetadataNodeIterator.h:46
iolink::MetadataNodeIterator
Class represents an iterator on a list of Metadata nodes.
Definition MetadataNodeIterator.h:16
iolink
All IOLink symbols are enclosed in this namespace.
Definition ArrayX.h:8