pub struct NodeDragPlan {
pub node: NodeId,
pub from: CanvasPoint,
pub to: CanvasPoint,
/* private fields */
}Expand description
Planned node drag transaction.
Fields§
§node: NodeIdPrimary node being moved.
from: CanvasPointCurrent primary-node position.
to: CanvasPointTarget primary-node position.
Implementations§
Source§impl NodeDragPlan
impl NodeDragPlan
Sourcepub fn items(&self) -> &[NodeDragItem]
pub fn items(&self) -> &[NodeDragItem]
Returns ordered drag items. Items are sorted by node id for deterministic transactions.
Sourcepub fn transaction(&self) -> &GraphTransaction
pub fn transaction(&self) -> &GraphTransaction
Returns the transaction that applies this drag update.
Sourcepub fn into_transaction(self) -> GraphTransaction
pub fn into_transaction(self) -> GraphTransaction
Consumes the plan and returns its transaction.
Trait Implementations§
Source§impl Clone for NodeDragPlan
impl Clone for NodeDragPlan
Source§fn clone(&self) -> NodeDragPlan
fn clone(&self) -> NodeDragPlan
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for NodeDragPlan
impl RefUnwindSafe for NodeDragPlan
impl Send for NodeDragPlan
impl Sync for NodeDragPlan
impl Unpin for NodeDragPlan
impl UnsafeUnpin for NodeDragPlan
impl UnwindSafe for NodeDragPlan
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