Trait OdooApiMethod

Source
pub trait OdooApiMethod
where Self: Sized + Debug + Serialize + JsonRpcParams<Container<Self> = OdooApiContainer<Self>>, Self::Container<Self>: Debug + Serialize,
{ // Required methods fn describe(&self) -> (&'static str, &'static str); fn endpoint(&self) -> &'static str; // Provided method fn _build(self, id: JsonRpcId) -> JsonRpcRequest<Self> { ... } }
Expand description

An Odoo “API” (JSON-RPC) request type

Required Methods§

Source

fn describe(&self) -> (&'static str, &'static str)

Describe the JSON-RPC service and method for this type

Source

fn endpoint(&self) -> &'static str

Describe method endpoint (e.g., “/web/session/authenticate”)

Provided Methods§

Source

fn _build(self, id: JsonRpcId) -> JsonRpcRequest<Self>

Build self into a full JsonRpcRequest

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§