/************************************************************************* * * HTCd - Copyright (C) 1998-2006 Henrik Rydberg * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef MSMAPH #define MSMAPH #include #include struct rrstring { sref first,second; rrstring() : first(),second() {} explicit rrstring(const sref& a) : first(a),second() {} rrstring(const sref& a,const sref& b) : first(a),second(b) {} }; inline bool operator<(const rrstring& a,const rrstring& b) { return a.first rrpile; struct rrmap : public rrpile { typedef rrpile::iterator iterator; typedef rrpile::const_iterator const_iterator; const sref* get(const sref& t) const; const sref* add(const sref& t,const sref& s); void sort(); }; ////////////////////////////////////////////////////////////////// struct rimap_t { sref name; int at; rimap_t() : name(),at(0) {} explicit rimap_t(const sref& a) : name(a),at(0) {} rimap_t(const sref& a,int p) : name(a),at(p) {} }; inline bool operator<(const rimap_t& a,const rimap_t& b) { return a.name { typedef mrvec::iterator iterator; typedef mrvec::const_iterator const_iterator; int get(const sref& t) const; int add(const sref& t,int at); void sort(); }; ////////////////////////////////////////////////////////////////// struct sstring { mstring first,second; sstring() : first(),second() {} explicit sstring(const mstring& a) : first(a),second() {} sstring(const mstring& a,const mstring& b) : first(a),second(b) {} }; inline bool operator<(const sstring& a,const sstring& b) { return a.first sspile; struct ssmap : public sspile { typedef sspile::iterator iterator; typedef sspile::const_iterator const_iterator; const mstring* get(const mstring& t) const; const mstring* add(const mstring& t,const mstring& s); void sort(); }; #endif