[−][src]Struct transit_model_relations::OneToMany
A one to many relation, i.e. to one T
corresponds many U
,
and a U
has one corresponding T
.
Methods
impl<T, U> OneToMany<T, U> where
T: Id<T>,
U: Id<U> + Id<T>,
[src]
T: Id<T>,
U: Id<U> + Id<T>,
pub fn new(
one: &CollectionWithId<T>,
many: &CollectionWithId<U>,
rel_name: &str
) -> Result<Self, Error>
[src]
one: &CollectionWithId<T>,
many: &CollectionWithId<U>,
rel_name: &str
) -> Result<Self, Error>
Construct the relation automatically from the 2 given
CollectionWithId
s.
Trait Implementations
impl<T: Debug, U: Debug> Debug for OneToMany<T, U>
[src]
impl<T, U> Default for OneToMany<T, U>
[src]
impl<T, U> Relation for OneToMany<T, U>
[src]
Auto Trait Implementations
impl<T, U> RefUnwindSafe for OneToMany<T, U> where
T: RefUnwindSafe,
U: RefUnwindSafe,
T: RefUnwindSafe,
U: RefUnwindSafe,
impl<T, U> Send for OneToMany<T, U> where
T: Send,
U: Send,
T: Send,
U: Send,
impl<T, U> Sync for OneToMany<T, U> where
T: Sync,
U: Sync,
T: Sync,
U: Sync,
impl<T, U> Unpin for OneToMany<T, U> where
T: Unpin,
U: Unpin,
T: Unpin,
U: Unpin,
impl<T, U> UnwindSafe for OneToMany<T, U> where
T: RefUnwindSafe + UnwindSafe,
U: RefUnwindSafe + UnwindSafe,
T: RefUnwindSafe + UnwindSafe,
U: RefUnwindSafe + UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,