IntaRNA 3.4.1
RNA-RNA interaction prediction | C++ API
Loading...
Searching...
No Matches
OutputHandlerInteractionList.h
Go to the documentation of this file.
1
2#ifndef OUTPUTHANDLERINTERACTIONLIST_H_
3#define OUTPUTHANDLERINTERACTIONLIST_H_
4
5#include "OutputHandler.h"
6
7#include <list>
8
9namespace IntaRNA
10{
11
19{
20protected:
21
23 typedef std::list<Interaction*> StorageContainer;
24
25public:
26
28 typedef StorageContainer::const_iterator const_iterator;
30 typedef StorageContainer::iterator iterator;
31
32public:
33
41 , const size_t maxToStore);
42
45
51 virtual
52 void
53 add( const Interaction & interaction );
54
57 bool empty() const;
58
61 const_iterator begin() const;
62
65 const_iterator end() const;
66
70
73 iterator end();
74
75protected:
76
79
82
84 const size_t maxToStore;
85
87 static
89 , const Interaction * const b )
90 { return *a < *b; }
91};
92
94
95inline
96bool
98empty() const {
99 return storage.empty();
100}
101
103
104inline
108begin() const {
109 return storage.begin();
110}
111
113
114inline
118end() const {
119 return storage.end();
120}
121
123
124inline
128begin() {
129 return storage.begin();
130}
131
133
134inline
138end() {
139 return storage.end();
140}
141
143
145
147
148} /* namespace IntaRNA */
149
150#endif /* OUTPUTHANDLERINTERACTIONLIST_H_ */
Definition Interaction.h:28
Definition OutputConstraint.h:19
Definition OutputHandlerInteractionList.h:19
StorageContainer::iterator iterator
iterator on stored interactions
Definition OutputHandlerInteractionList.h:30
virtual void add(const Interaction &interaction)
StorageContainer::const_iterator const_iterator
const iterator on stored interactions
Definition OutputHandlerInteractionList.h:28
bool empty() const
Definition OutputHandlerInteractionList.h:98
const size_t maxToStore
number of elements to store within storage (only maxToStore best)
Definition OutputHandlerInteractionList.h:84
const_iterator end() const
Definition OutputHandlerInteractionList.h:118
StorageContainer storage
container where interactions are stored
Definition OutputHandlerInteractionList.h:81
static bool lessThan_StorageContainer(const Interaction *const a, const Interaction *const b)
'less-than' comparison struct dereferencing storage pointer
Definition OutputHandlerInteractionList.h:88
OutputHandlerInteractionList(const OutputConstraint &outConstraint, const size_t maxToStore)
const_iterator begin() const
Definition OutputHandlerInteractionList.h:108
std::list< Interaction * > StorageContainer
the container used internally for storing interactions
Definition OutputHandlerInteractionList.h:23
virtual ~OutputHandlerInteractionList()
destruction
Definition OutputHandler.h:20
const OutputConstraint outConstraint
the output constraints to be applied
Definition OutputHandler.h:103
size_t reportedInteractions
number of reported interactions
Definition OutputHandler.h:106
Definition Accessibility.h:13