]> err.no Git - sope/blob - sope-xml/STXSaxDriver/STXSaxDriver.h
renamed packages as discussed in the developer list
[sope] / sope-xml / STXSaxDriver / STXSaxDriver.h
1 /*
2   Copyright (C) 2000-2004 SKYRIX Software AG
3
4   This file is part of OpenGroupware.org.
5
6   OGo is free software; you can redistribute it and/or modify it under
7   the terms of the GNU Lesser General Public License as published by the
8   Free Software Foundation; either version 2, or (at your option) any
9   later version.
10
11   OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12   WARRANTY; without even the implied warranty of MERCHANTABILITY or
13   FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
14   License for more details.
15
16   You should have received a copy of the GNU Lesser General Public
17   License along with OGo; see the file COPYING.  If not, write to the
18   Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
19   02111-1307, USA.
20 */
21 // $Id$
22
23 #ifndef __ExtraSTX_STXSaxDriver_H__
24 #define __ExtraSTX_STXSaxDriver_H__
25
26 #import <Foundation/NSObject.h>
27 #include <SaxObjC/SaxObjC.h>
28
29 @class NSArray, NSDictionary;
30 @class SaxAttributes;
31 @class StructuredTextParagraph, StructuredTextList, StructuredTextListItem;
32 @class StructuredTextLiteralBlock, StructuredTextHeader;
33
34 @interface STXSaxDriver : NSObject < SaxXMLReader >
35 {
36   id<NSObject,SaxContentHandler> contentHandler;
37   id<NSObject,SaxErrorHandler>   errorHandler;
38   id<NSObject,SaxLexicalHandler> lexicalHandler;
39   id<NSObject,SaxEntityResolver> entityResolver;
40
41   NSDictionary  *context;
42   SaxAttributes *attrs;
43 }
44
45 /* handlers */
46
47 - (void)setContentHandler:(id<NSObject,SaxContentHandler>)_handler;
48 - (void)setDTDHandler:(id<NSObject,SaxDTDHandler>)_handler;
49 - (void)setErrorHandler:(id<NSObject,SaxErrorHandler>)_handler;
50 - (void)setEntityResolver:(id<NSObject,SaxEntityResolver>)_handler;
51 - (id<NSObject,SaxContentHandler>)contentHandler;
52 - (id<NSObject,SaxDTDHandler>)dtdHandler;
53 - (id<NSObject,SaxErrorHandler>)errorHandler;
54 - (id<NSObject,SaxEntityResolver>)entityResolver;
55
56 /* parsing */
57
58 - (void)parseFromSource:(id)_source systemId:(NSString *)_sysId;
59
60 /* generating events */
61
62 - (void)produceSaxEventsForParagraph:(StructuredTextParagraph *)_p;
63 - (void)produceSaxEventsForList:(StructuredTextList *)_list;
64 - (void)produceSaxEventsForListItem:(StructuredTextListItem *)_item;
65 - (void)produceSaxEventsForLiteralBlock:(StructuredTextLiteralBlock *)_block;
66 - (void)produceSaxEventsForHeader:(StructuredTextHeader *)_header;
67
68 - (void)produceSaxEventsForElement:(id)_element;
69 - (void)produceSaxEventsForElements:(NSArray *)_elems;
70
71 @end
72
73 #endif /* __ExtraSTX_STXSaxDriver_H__ */