Miranda Installer - Installs nightlies and Miranda addons.
Copyright (C) 2002-2003 Goblineye Entertainment
Authors: Saar (Tornado) and Kai (kai_b)
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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#pragma once
/*
A basic XML Parser, adapted from Wassup
The parser was revised at some point to be able to handle comments and empty tags
*/
#include "MirandaInstaller.h"
#pragma hdrstop
// notification sent by the parser
#define XMLPARSER_NOTIFY_STARTELEMENT 0 // also "tells" when a an empty tag is found
#define XMLPARSER_NOTIFY_ENDELEMENT 1
#define XMLPARSER_NOTIFY_ARGUMENTS 2 // the arguments of the last element we talked about
#define XMLPARSER_NOTIFY_DATA 3 // data (raw data, no elements)
// byte - notification. char* - the data (depends on the notifcation). unsigned long - length of data that should be touched. LPARAM - defined user data
// this is the handler. receives all sorts of notifications from us.
bool XMLParser_FeedDocument(XMLParse_Handler NotifyFunc,char *lpszDoc,LPARAM lParam); // feed the parser with the document. the document should be whole!! we don't handle semi-documents and such :)