all: use trait upcasting
This commit is contained in:
parent
f0caafc862
commit
09e5f89174
44 changed files with 90 additions and 269 deletions
|
|
@ -36,11 +36,9 @@ impl Display for ObjectId {
|
|||
}
|
||||
}
|
||||
|
||||
pub trait ObjectBase {
|
||||
pub trait ObjectBase: Any {
|
||||
fn id(&self) -> ObjectId;
|
||||
fn version(&self) -> Version;
|
||||
#[cfg_attr(not(feature = "it"), expect(dead_code))]
|
||||
fn into_any(self: Rc<Self>) -> Rc<dyn Any>;
|
||||
fn handle_request(
|
||||
self: Rc<Self>,
|
||||
client: &Client,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue