00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef DELIMITEDLANGELEM_H
00013 #define DELIMITEDLANGELEM_H
00014
00015 #include "statestartlangelem.h"
00016
00017 namespace srchilite {
00018
00019 class StringDef;
00020
00026
00027 class HighlightState;
00028 class HighlightStateBuilder;
00029
00030
00031 class DelimitedLangElem : public StateStartLangElem
00032 {
00033 private:
00034 StringDef *start;
00035 StringDef *end;
00036 StringDef *escape;
00037 bool multiline;
00038 bool nested;
00039
00040 public:
00049 DelimitedLangElem(const std::string &n, StringDef *s, StringDef *e,
00050 StringDef *es, bool multi, bool nes);
00051
00052 ~DelimitedLangElem();
00053
00058 virtual const std::string toString() const;
00059
00065 virtual const std::string toStringOriginal() const;
00066
00070 StringDef *getStart() const {
00071 return start;
00072 }
00073
00077 StringDef *getEnd() const {
00078 return end;
00079 }
00080
00084 StringDef *getEscape() const {
00085 return escape;
00086 }
00087
00091 bool isMultiline() const {
00092 return multiline;
00093 }
00094
00098 bool isNested() const {
00099 return nested;
00100 }
00101
00102 public:
00103 virtual void dispatch_build(HighlightStateBuilder *, HighlightState * state);
00104
00105 };
00106
00107 }
00108
00109 #endif