2 Copyright (C) 2000-2003 SKYRIX Software AG
4 This file is part of OGo
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
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.
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
23 #ifndef __NGMimeGenerator_NGMimeGeneratorProtocols_H__
24 #define __NGMimeGenerator_NGMimeGeneratorProtocols_H__
26 #import <Foundation/NSObject.h>
27 #import <NGMime/NGPart.h>
29 @class NSData, NGMutableHashMap;
31 @protocol NGMimePartGenerator <NSObject>
33 /* generate mime from part and store it in _file */
34 - (NSString *)generateMimeFromPartToFile:(id<NGMimePart>)_part;
36 - (NSData *)generateMimeFromPart:(id<NGMimePart>)_part;
37 - (void)setDelegate:(id)_delegate;
39 - (void)setUseMimeData:(BOOL)_useMimeData;
43 @protocol NGMimeBodyGenerator < NSObject >
45 - (NSData *)generateBodyOfPart:(id<NGMimePart>)_part
46 additionalHeaders:(NGMutableHashMap *)_addHeaders
47 delegate:(id)_delegate;
49 - (NSData *)encodeData:(NSData *)_data
50 forPart:(id<NGMimePart>)_part
51 additionalHeaders:(NGMutableHashMap *)_addHeaders;
53 /* use mime data objects to store mime objects on disk instead in memory */
55 - (void)setUseMimeData:(BOOL)_useMimeData;
58 @protocol NGMimeHeaderFieldGenerator < NSObject >
60 - (NSData *)generateDataForHeaderFieldNamed:(NSString *)_headerField
65 #endif // __NGMimeGenerator_NGMimeGeneratorProtocols_H__