FileDocCategorySizeDatePackage
UUMailer.javaAPI DocApache Ant 1.701810Wed Dec 13 06:16:18 GMT 2006org.apache.tools.ant.taskdefs.email

UUMailer

public class UUMailer extends PlainMailer
An emailer that uuencodes attachments.
since
Ant 1.5

Fields Summary
Constructors Summary
Methods Summary
protected voidattach(java.io.File file, java.io.PrintStream out)

        if (!file.exists() || !file.canRead()) {
            throw new BuildException("File \"" + file.getName()
                 + "\" does not exist or is not "
                 + "readable.");
        }

        FileInputStream finstr = new FileInputStream(file);

        try {
            BufferedInputStream in = new BufferedInputStream(finstr);
            UUEncoder encoder = new UUEncoder(file.getName());

            encoder.encode(in, out);

        } finally {
            finstr.close();
        }