lyx_mirror/src/ParagraphList.h
Lars Gullik Bjønnes 9973bb7aa1 add some cut and paste bugs (disguised as cleanups)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6373 a592a061-630c-0410-9148-cb99ea01b6c8
2003-03-06 21:01:04 +00:00

91 lines
1.4 KiB
C++

// -*- C++ -*-
#ifndef PARAGRAPH_LIST_H
#define PARAGRAPH_LIST_H
#include <iterator>
class Paragraph;
///
class ParagraphList {
public:
///
class iterator {
public:
///
typedef std::bidirectional_iterator_tag iterator_category;
///
typedef Paragraph * value_type;
///
typedef ptrdiff_t difference_type;
///
typedef Paragraph * pointer;
///
typedef Paragraph & reference;
///
iterator();
///
iterator(value_type);
///
reference operator*();
///
pointer operator->();
///
iterator & operator++();
///
iterator operator++(int);
///
iterator & operator--();
///
iterator operator--(int);
private:
///
Paragraph * ptr;
};
///
ParagraphList();
///
iterator insert(iterator it, Paragraph * par);
///
void clear();
///
void erase(iterator it);
///
iterator begin();
///
iterator begin() const;
///
iterator end();
///
iterator end() const;
///
void set(Paragraph *);
///
void push_back(Paragraph *);
///
Paragraph const & front() const;
///
Paragraph & front();
///
Paragraph const & back() const;
///
Paragraph & back();
///
int size() const;
///
bool empty() const;
private:
///
Paragraph * parlist;
};
///
bool operator==(ParagraphList::iterator const & i1,
ParagraphList::iterator const & i2);
///
bool operator!=(ParagraphList::iterator const & i1,
ParagraphList::iterator const & i2);
#endif