xref: /haiku/src/apps/icon-o-matic/import_export/flat_icon/SourceExporter.h (revision 13f2f8de06c44ee9622acb2f42378d467a6aa8da)
1 /*
2  * Copyright 2006-2007, Haiku. All rights reserved.
3  * Distributed under the terms of the MIT License.
4  *
5  * Authors:
6  *		Stephan Aßmus <superstippi@gmx.de>
7  */
8 
9 #ifndef SOURCE_EXPORTER_H
10 #define SOURCE_EXPORTER_H
11 
12 #include "FlatIconExporter.h"
13 
14 /*! Exports HVIF file data into a C/C++ array */
15 class SourceExporter : public FlatIconExporter {
16  public:
17 								SourceExporter();
18 	virtual						~SourceExporter();
19 
20 	// FlatIconExporter interface
21 	virtual	status_t			Export(const Icon* icon,
22 									   BPositionIO* stream);
23 
MIMEType()24 	virtual	const char*			MIMEType() { return "text/x-source-code"; }
25 
26  private:
27 			status_t			_Export(const uint8* source,
28 										size_t sourceSize,
29 										BPositionIO* stream) const;
30 };
31 
32 #endif // SOURCE_EXPORTER_H
33