JavaScript is disabled, refresh for a better experience. ambee/giterated

ambee/giterated

Git repository hosting, collaboration, and discovery for the Fediverse.

Before

Amber - ⁨1⁩ year ago

parent: tbd commit: ⁨e432306

⁨giterated-core/src/state.rs⁩ - ⁨381⁩ bytes
Raw
1 pub trait FromOperationState<O, D>: Sized {
2 fn from_operation_state(
3 state: &mut State,
4 object: &O,
5 operation: &D,
6 ) -> Result<Self, OperationError<anyhow::Error>>;
7 }
8
9 pub struct StateExtractor<T>(T);
10
11 impl<T: FromState> FromState for StateExtractor<T> {
12 fn from_state(state: &mut State) -> Result<Self, anyhow::Error> {
13 todo!()
14 }
15 }
16