Mercurial > repos > jpayne > bioproject_to_srr_2
comparison urllib3/contrib/emscripten/request.py @ 7:5eb2d5e3bf22
planemo upload for repository https://toolrepo.galaxytrakr.org/view/jpayne/bioproject_to_srr_2/556cac4fb538
author | jpayne |
---|---|
date | Sun, 05 May 2024 23:32:17 -0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
6:b2745907b1eb | 7:5eb2d5e3bf22 |
---|---|
1 from __future__ import annotations | |
2 | |
3 from dataclasses import dataclass, field | |
4 | |
5 from ..._base_connection import _TYPE_BODY | |
6 | |
7 | |
8 @dataclass | |
9 class EmscriptenRequest: | |
10 method: str | |
11 url: str | |
12 params: dict[str, str] | None = None | |
13 body: _TYPE_BODY | None = None | |
14 headers: dict[str, str] = field(default_factory=dict) | |
15 timeout: float = 0 | |
16 decode_content: bool = True | |
17 | |
18 def set_header(self, name: str, value: str) -> None: | |
19 self.headers[name.capitalize()] = value | |
20 | |
21 def set_body(self, body: _TYPE_BODY | None) -> None: | |
22 self.body = body |