struct WebPageParameters;
struct WebPageVariable
{
WebPageVariable() {}
WebPageVariable(const String &_Name, const String &_Value)
{
Name = _Name;
Value = _Value;
}
String Name;
String Value;
};
class WebPageParser
{
public:
void ParseLine(const WebPageParameters &PageParameters, const String &Line, ofstream &OutputFile);
private:
void HandleInclude(const WebPageParameters &PageParameters, const String &Filename, ofstream &OutputFile);
void HandleCode(const WebPageParameters &PageParameters, const String &ParameterString, ofstream &OutputFile);
void HandleSingleCodeFile(const WebPageParameters &PageParameters, const String &CodeDirectory, const String &CodeFilename,
const String &FormattedFile, const String &OutputDirectory, UINT IndentCount, ofstream &OutputFile);
void HandleAssignment(const String &VariableName, const String &Value);
void SubstituteVariables(const String &Line, String &Result);
bool IsCodeFile(const String &Filename);
WebPageVariable* GetVariable(const String &Name);
Vector<WebPageVariable> _Variables;
};