Struct edgedb_composable_query::Ref
source · pub struct Ref<T: EdgedbObject> {
pub id: Uuid,
pub known_value: Option<T>,
}
Expand description
Basically a Uuid
and an Option<T>
. Use this instead of adding id: Uuid
field to your structs.
Fields§
§id: Uuid
§known_value: Option<T>
Trait Implementations§
source§impl<T: EdgedbComposableSelector + EdgedbObject> EdgedbComposableSelector for Ref<T>
impl<T: EdgedbComposableSelector + EdgedbObject> EdgedbComposableSelector for Ref<T>
const RESULT_TYPE: ComposableQueryResultKind = ComposableQueryResultKind::Selector
source§fn format_selector(fmt: &mut impl Write) -> Result<(), Error>
fn format_selector(fmt: &mut impl Write) -> Result<(), Error>
should’t add
{
and }
around the selectorfn format_subquery(fmt: &mut impl Write) -> Result<(), Error>
source§impl<T: EdgedbObject> EdgedbValue for Ref<T>
impl<T: EdgedbObject> EdgedbValue for Ref<T>
§type NativeArgType = Value
type NativeArgType = Value
use Value by default
fn from_edgedb_value(value: Value) -> Result<Self>
source§impl<T: PartialEq + EdgedbObject> PartialEq for Ref<T>
impl<T: PartialEq + EdgedbObject> PartialEq for Ref<T>
impl<T: Eq + EdgedbObject> Eq for Ref<T>
impl<T: EdgedbObject> StructuralEq for Ref<T>
impl<T: EdgedbObject> StructuralPartialEq for Ref<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for Ref<T>where
T: RefUnwindSafe,
impl<T> Send for Ref<T>where
T: Send,
impl<T> Sync for Ref<T>where
T: Sync,
impl<T> Unpin for Ref<T>where
T: Unpin,
impl<T> UnwindSafe for Ref<T>where
T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more