00001 /* 00002 * PROPRIETARY INFORMATION. This software is proprietary to 00003 * Side Effects Software Inc., and is not to be reproduced, 00004 * transmitted, or disclosed in any way without written permission. 00005 * 00006 * Produced by: 00007 * Mark Elendt 00008 * Side Effects 00009 * 477 Richmond Street West 00010 * Toronto, Ontario 00011 * Canada M5V 3E7 00012 * 416-504-9876 00013 * 00014 * NAME: Stream methods to uuencode & uudecode a stream (C++) 00015 * 00016 * COMMENTS: 00017 * 00018 */ 00019 00020 #ifndef __UT_uuencode_h__ 00021 #define __UT_uuencode_h__ 00022 00023 #include "UT_API.h" 00024 #include <iostream.h> 00025 00026 class UT_IStream; 00027 class UT_String; 00028 00029 // 00030 // Encode a binary istream and write the uuencoded data to os. 00031 // The file permissions are defined by mode. 00032 // This will read from is until it's out of data... 00033 UT_API extern bool UTuuencode(UT_IStream &is, ostream &os, 00034 const char *name, int mode = 0666); 00035 00036 // 00037 // Take a uuencoded istream and write the uudecoded data to os 00038 // the filename is returned in the UT_String. If the mode 00039 // is not a null pointer, it will be set to the mode of the 00040 // file. This will terminate when the "end" statement is reached 00041 UT_API extern bool UTuudecode(UT_IStream &is, ostream &os, 00042 UT_String &name, int *mode = 0); 00043 00044 #endif
1.5.9