DGtal
2.2.0
Toggle main menu visibility
Loading...
Searching...
No Matches
BackInsertionSequenceToStackAdapter.h
1
16
17
#pragma once
18
30
31
#if defined(BackInsertionSequenceToStackAdapter_RECURSES)
32
#error Recursive header files inclusion detected in BackInsertionSequenceToStackAdapter.h
33
#else
// defined(BackInsertionSequenceToStackAdapter_RECURSES)
35
#define BackInsertionSequenceToStackAdapter_RECURSES
36
37
#if !defined BackInsertionSequenceToStackAdapter_h
39
#define BackInsertionSequenceToStackAdapter_h
40
42
// Inclusions
43
#include <iostream>
44
#include "DGtal/base/Common.h"
45
#include "DGtal/base/Alias.h"
47
48
namespace
DGtal
49
{
50
52
// template class BackInsertionSequenceToStackAdapter
61
template
<
typename
TSequence>
62
class
BackInsertionSequenceToStackAdapter
63
{
64
65
// ----------------------- Inner types ------------------------------------
66
public
:
67
71
typedef
TSequence
Container
;
72
BOOST_CONCEPT_ASSERT
((
boost::BackInsertionSequence<Container>
));
73
77
typedef
typename
Container::value_type
value_type
;
81
typedef
typename
Container::value_type
Value
;
82
86
typedef
typename
Container::size_type
size_type
;
90
typedef
typename
Container::size_type
Size
;
91
92
93
// ----------------------- Standard services ------------------------------
94
public
:
95
100
BackInsertionSequenceToStackAdapter
(
Alias<Container>
aContainer);
101
106
Size
size
()
const
;
107
112
bool
empty
()
const
;
113
121
Value
&
top
();
129
const
Value
&
top
()
const
;
130
137
void
push
(
const
Value
& aValue);
138
144
void
pop
();
145
146
// ----------------------- Interface --------------------------------------
147
public
:
148
153
void
selfDisplay
( std::ostream & out )
const
;
154
159
bool
isValid
()
const
;
160
161
// ------------------------- Private Data --------------------------------
162
private
:
166
Container
*
myContainerPtr
;
167
168
169
170
};
// end of class BackInsertionSequenceToStackAdapter
171
172
179
template
<
typename
TSequence>
180
std::ostream&
181
operator<<
( std::ostream & out,
const
BackInsertionSequenceToStackAdapter<TSequence>
&
object
);
182
189
template
<
typename
TSequence>
190
BackInsertionSequenceToStackAdapter<TSequence>
191
backStack
( TSequence& aSequence );
192
193
}
// namespace DGtal
194
195
197
// Includes inline functions.
198
#include "DGtal/base/BackInsertionSequenceToStackAdapter.ih"
199
200
// //
202
203
#endif
// !defined BackInsertionSequenceToStackAdapter_h
204
205
#undef BackInsertionSequenceToStackAdapter_RECURSES
206
#endif
// else defined(BackInsertionSequenceToStackAdapter_RECURSES)
DGtal::Alias
Aim: This class encapsulates its parameter class so that to indicate to the user that the object/poin...
Definition
Alias.h:183
DGtal::BackInsertionSequenceToStackAdapter
Aim: This class implements a dynamic adapter to an instance of a model of back insertion sequence in ...
Definition
BackInsertionSequenceToStackAdapter.h:63
DGtal::BackInsertionSequenceToStackAdapter::top
const Value & top() const
DGtal::BackInsertionSequenceToStackAdapter::top
Value & top()
DGtal::BackInsertionSequenceToStackAdapter::size
Size size() const
DGtal::BackInsertionSequenceToStackAdapter::value_type
Container::value_type value_type
Definition
BackInsertionSequenceToStackAdapter.h:77
DGtal::BackInsertionSequenceToStackAdapter::myContainerPtr
Container * myContainerPtr
Definition
BackInsertionSequenceToStackAdapter.h:166
DGtal::BackInsertionSequenceToStackAdapter::size_type
Container::size_type size_type
Definition
BackInsertionSequenceToStackAdapter.h:86
DGtal::BackInsertionSequenceToStackAdapter::BackInsertionSequenceToStackAdapter
BackInsertionSequenceToStackAdapter(Alias< Container > aContainer)
DGtal::BackInsertionSequenceToStackAdapter::pop
void pop()
DGtal::BackInsertionSequenceToStackAdapter::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((boost::BackInsertionSequence< Container >))
DGtal::BackInsertionSequenceToStackAdapter::Container
TSequence Container
Definition
BackInsertionSequenceToStackAdapter.h:71
DGtal::BackInsertionSequenceToStackAdapter::selfDisplay
void selfDisplay(std::ostream &out) const
DGtal::BackInsertionSequenceToStackAdapter::isValid
bool isValid() const
DGtal::BackInsertionSequenceToStackAdapter::push
void push(const Value &aValue)
DGtal::BackInsertionSequenceToStackAdapter::empty
bool empty() const
DGtal::BackInsertionSequenceToStackAdapter::Size
Container::size_type Size
Definition
BackInsertionSequenceToStackAdapter.h:90
DGtal::BackInsertionSequenceToStackAdapter::Value
Container::value_type Value
Definition
BackInsertionSequenceToStackAdapter.h:81
DGtal
DGtal is the top-level namespace which contains all DGtal functions and types.
Definition
ClosedIntegerHalfPlane.h:49
DGtal::backStack
BackInsertionSequenceToStackAdapter< TSequence > backStack(TSequence &aSequence)
DGtal::operator<<
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)
boost::BackInsertionSequence
Go to http://www.sgi.com/tech/stl/BackInsertionSequence.html.
Definition
Boost.dox:134
src
DGtal
base
BackInsertionSequenceToStackAdapter.h
Generated on
for DGtal by
1.18.0