public static Func <Stream, Task> Create(string text, Encoding encoding) { return(stream => { var textBody = new TextBody(text, encoding); return textBody.Start(stream); }); }
public static Func<Stream, Task> Create(string text, Encoding encoding) { return stream => { var textBody = new TextBody(text, encoding); return textBody.Start(stream); }; }
public static BodyDelegate Create(string text, Encoding encoding) { return (write, end, cancel) => { var textBody = new TextBody(text, encoding); textBody.Start(write, end, cancel); }; }