source: icGREP/icgrep-0.8/icgrep/re_seq.cpp @ 3972

Last change on this file since 3972 was 3850, checked in by cameron, 5 years ago

icgrep-0.8 distribution

File size: 666 bytes
Line 
1/*
2 *  Copyright (c) 2014 International Characters.
3 *  This software is licensed to the public under the Open Software License 3.0.
4 *  icgrep is a trademark of International Characters.
5 */
6
7#include "re_seq.h"
8
9Seq::Seq()
10{
11    mList = new std::list<RE*>();
12}
13
14Seq::Seq(std::list<RE*>* lst)
15{
16    mList = new std::list<RE*>();
17    std::list<RE*>::iterator it;
18    it=lst->begin();
19    mList->assign(it, lst->end());
20    mList->reverse();
21}
22
23Seq::~Seq()
24{
25    while(!mList->empty()) delete mList->back(), mList->pop_back();
26    delete mList;
27}
28
29std::list<RE*>* Seq::GetREList()
30{
31    return mList;
32}
33
34void Seq::AddREListItem(RE *re)
35{
36    mList->push_back(re);
37}
38
Note: See TracBrowser for help on using the repository browser.