~ubuntu-branches/ubuntu/oneiric/codeblocks/oneiric

« back to all changes in this revision

Viewing changes to src/plugins/astyle/asstreamiterator.h

  • Committer: Bazaar Package Importer
  • Author(s): Michael Casadevall
  • Date: 2008-07-17 04:39:23 UTC
  • Revision ID: james.westby@ubuntu.com-20080717043923-gmsy5cwkdjswghkm
Tags: upstream-8.02
ImportĀ upstreamĀ versionĀ 8.02

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * This file is part of the Code::Blocks IDE and licensed under the GNU General Public License, version 3
 
3
 * http://www.gnu.org/licenses/gpl-3.0.html
 
4
 */
 
5
 
 
6
#ifndef ASSTREAMITERATOR_H
 
7
#define ASSTREAMITERATOR_H
 
8
 
 
9
#include <iostream>
 
10
#include <wx/string.h>
 
11
#include <cbeditor.h>
 
12
#include <vector>
 
13
#include "./astyle/astyle.h"
 
14
 
 
15
class ASStreamIterator : public astyle::ASSourceIterator
 
16
{
 
17
        public:
 
18
                ASStreamIterator(cbEditor *cbe, const wxChar *in);
 
19
                virtual ~ASStreamIterator();
 
20
 
 
21
    bool hasMoreLines() const;
 
22
    std::string nextLine();
 
23
    bool FoundBookmark() const { return m_foundBookmark; }
 
24
    void ClearFoundBookmark() { m_foundBookmark = false; }
 
25
 
 
26
        protected:
 
27
        bool IsEOL(wxChar ch);
 
28
        cbEditor *m_cbe;
 
29
        const wxChar *m_In;
 
30
        std::vector<wxChar> m_buffer;
 
31
        int m_curline;
 
32
        bool m_foundBookmark;
 
33
        private:
 
34
};
 
35
 
 
36
#endif // ASSTREAMITERATOR_H