'Produce this message.
@param msg: The message I am to produce.
@type msg: L{IMessage}
@param buffer: A buffer to hold the message in.  If None, I will
use a L{tempfile.TemporaryFile}.
@type buffer: file-like'

def __init__(self, msg, buffer=None, scheduler=None):

    self.msg = msg
    if (buffer is None):
        buffer = tempfile.TemporaryFile()
    self.buffer = buffer
    if (scheduler is None):
        scheduler = iterateInReactor
    self.scheduler = scheduler
    self.write = self.buffer.write
