Struct makepad_widgets::HttpRequest
pub struct HttpRequest {
pub metadata_id: LiveId,
pub url: String,
pub method: HttpMethod,
pub headers: BTreeMap<String, Vec<String, Global>, Global>,
pub body: Option<Vec<u8, Global>>,
}
Fields§
§metadata_id: LiveId
§url: String
§method: HttpMethod
§headers: BTreeMap<String, Vec<String, Global>, Global>
§body: Option<Vec<u8, Global>>
Implementations§
§impl HttpRequest
impl HttpRequest
pub fn new(url: String, method: HttpMethod) -> HttpRequest
pub fn set_metadata_id(&mut self, id: LiveId)
pub fn set_header(&mut self, name: String, value: String)
pub fn get_headers_string(&self) -> String
pub fn set_body(&mut self, body: Vec<u8, Global>)
pub fn set_body_string(&mut self, v: &str)
pub fn set_json_body<T>(&mut self, body: T)where T: SerJson,
pub fn set_string_body(&mut self, body: String)
Trait Implementations§
§impl Debug for HttpRequest
impl Debug for HttpRequest
§impl PartialEq<HttpRequest> for HttpRequest
impl PartialEq<HttpRequest> for HttpRequest
§fn eq(&self, other: &HttpRequest) -> bool
fn eq(&self, other: &HttpRequest) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for HttpRequest
Auto Trait Implementations§
impl RefUnwindSafe for HttpRequest
impl Send for HttpRequest
impl Sync for HttpRequest
impl Unpin for HttpRequest
impl UnwindSafe for HttpRequest
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more