pub struct RelationBuilder<'a> { /* private fields */ }Expand description
Builder for CreateRelation operations with full control.
Implementations§
Source§impl<'a> RelationBuilder<'a>
impl<'a> RelationBuilder<'a>
Sourcepub fn relation_type(self, id: Id) -> Self
pub fn relation_type(self, id: Id) -> Self
Sets the relation type.
Sourcepub fn position(self, pos: impl Into<Cow<'a, str>>) -> Self
pub fn position(self, pos: impl Into<Cow<'a, str>>) -> Self
Sets the position string for ordering.
Sourcepub fn from_space(self, space_id: Id) -> Self
pub fn from_space(self, space_id: Id) -> Self
Sets the from_space pin.
Sourcepub fn from_version(self, version_id: Id) -> Self
pub fn from_version(self, version_id: Id) -> Self
Sets the from_version pin.
Sourcepub fn to_version(self, version_id: Id) -> Self
pub fn to_version(self, version_id: Id) -> Self
Sets the to_version pin.
Sourcepub fn build(self) -> Option<CreateRelation<'a>>
pub fn build(self) -> Option<CreateRelation<'a>>
Builds the CreateRelation, returning None if required fields are missing.
Sourcepub fn from_value_ref(self, id: Id) -> Self
pub fn from_value_ref(self, id: Id) -> Self
Sets from as a value ref ID (inline encoding).
Sourcepub fn to_value_ref(self, id: Id) -> Self
pub fn to_value_ref(self, id: Id) -> Self
Sets to as a value ref ID (inline encoding).
Trait Implementations§
Source§impl<'a> Clone for RelationBuilder<'a>
impl<'a> Clone for RelationBuilder<'a>
Source§fn clone(&self) -> RelationBuilder<'a>
fn clone(&self) -> RelationBuilder<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for RelationBuilder<'a>
impl<'a> Debug for RelationBuilder<'a>
Source§impl<'a> Default for RelationBuilder<'a>
impl<'a> Default for RelationBuilder<'a>
Source§fn default() -> RelationBuilder<'a>
fn default() -> RelationBuilder<'a>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<'a> Freeze for RelationBuilder<'a>
impl<'a> RefUnwindSafe for RelationBuilder<'a>
impl<'a> Send for RelationBuilder<'a>
impl<'a> Sync for RelationBuilder<'a>
impl<'a> Unpin for RelationBuilder<'a>
impl<'a> UnwindSafe for RelationBuilder<'a>
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