This is MSMail.m in view mode; [Download] [Up]
#import "MSMail.h" #import "FileName.h" #import "support.h" #include <sys/file.h> #define START_STR "#<begin uuencode>\n" #define END_STR "#<end uuencode>\n\n" @implementation MSMail - buildBody { int x, cnt, startLen, endLen; id aFile; [super buildBody]; startLen = strlen(START_STR); endLen = strlen(END_STR); for(x = 0, cnt = [attachments count]; x < cnt; x++) { fwrite(START_STR, 1, startLen, fp); aFile = [attachments objectAt: x]; uuencode([aFile basename],[aFile stringValue], fp, 0666); fwrite(END_STR, 1, endLen, fp); } return self; } +(BOOL)supportsAttachments { return YES; } @end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.