Crate pandora_api_derive
source ·Expand description
Derive macros for automatically adding an implementation of pandora_api::Pandora<Json|Rest>ApiRequest to a struct.
The name of the Pandora API method that will be called defaults to the result of converting the struct name to lower camel case (GetFoo -> getFoo). This may be overridden using the #[pandora_request(method_name = getFOOBar) struct attribute.
The default error type is Error. If a different type name is required, this may be overridden using the #[pandora_request(error_type = FooError)] struct attribute.
The default return type of the request is
The default for a request is to send it unencrypted. If the request must be encrypted, this may be overridden using the #[pandora_request(encrypted = true)] struct attribute.
Derive Macros§
- Derive macro for adding implementation of pandora_api::PandoraJsonApiRequest trait to a struct.
- Derive macro for adding implementation of pandora_api::PandoraRestApiRequest trait to a struct.