Struct xmlrpc::Request[][src]

pub struct Request<'a> { /* fields omitted */ }
Expand description

A request to call a procedure.

Implementations

Creates a new request to call a function named name.

By default, no arguments are passed. Use the arg method to append arguments.

Creates a “multicall” request that will perform multiple requests at once.

This requires that the server supports the system.multicall method.

Appends an argument to be passed to the current list of arguments.

Performs the request using a Transport.

If you want to send the request using an HTTP POST request, you can also use call_url, which creates a suitable Transport internally.

Errors

Any errors that occur while sending the request using the Transport will be returned to the caller. Additionally, if the response is malformed (invalid XML), or indicates that the method call failed, an error will also be returned.

Performs the request on a URL.

You can pass a &str or an already parsed reqwest URL.

This is a convenience method that will internally create a new reqwest::Client and send an HTTP POST request to the given URL. If you only use this method to perform requests, you don’t need to depend on reqwest yourself.

This method is only available when the http feature is enabled (this is the default).

Errors

Since this is just a convenience wrapper around Request::call, the same error conditions apply.

Any reqwest errors will be propagated to the caller.

Formats this Request as a UTF-8 encoded XML document.

Errors

Any errors reported by the writer will be propagated to the caller. If the writer never returns an error, neither will this method.

👎 Deprecated since 0.11.2:

use Request::multicall instead

Serialize this Request into an XML-RPC struct that can be passed to the system.multicall XML-RPC method, specifically a struct with two fields:

  • methodName: the request name
  • params: the request arguments

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more