public MultipartRequestContent(RequestContent content, Dictionary <string, string> headers)
 {
     RequestContent = content;
     Headers        = headers;
 }
 public Utf8JsonRequestContent()
 {
     _stream    = new MemoryStream();
     _content   = Create(_stream);
     JsonWriter = new Utf8JsonWriter(_stream);
 }
 /// <summary>
 ///  Add HTTP content to a collection of RequestContent objects that
 ///  get serialized to multipart/form-data MIME type.
 /// </summary>
 /// <param name="content">The Request content to add to the collection.</param>
 public void Add(RequestContent content)
 {
     Argument.AssertNotNull(content, nameof(content));
     AddInternal(content, null, null, null);
 }
Beispiel #4
0
 public XmlWriterContent()
 {
     _stream   = new MemoryStream();
     _content  = Create(_stream);
     XmlWriter = new XmlTextWriter(_stream, Encoding.UTF8);
 }