pub struct WorktreePlan {
pub schema_version: String,
pub operation: String,
pub operations: Vec<RefactorOperation>,
pub completeness: Option<Completeness>,
pub evidence: PlanEvidence,
}Expand description
A bounded, versioned collection of logical refactor operations and evidence.
Fields§
§schema_version: String§operation: String§operations: Vec<RefactorOperation>One simultaneous transition set; array order is identity, not execution order.
completeness: Option<Completeness>§evidence: PlanEvidenceImplementations§
Source§impl RefactorPlan
impl RefactorPlan
pub fn new( operation: impl Into<String>, operations: Vec<RefactorOperation>, ) -> RefactorPlan
pub fn validate(&self) -> Result<ValidatedConsumerPlan<'_>, PlanError>
pub fn validate_with( &self, limits: RefactorPlanLimits, ) -> Result<ValidatedConsumerPlan<'_>, PlanError>
pub fn fingerprint(&self) -> Result<PlanFingerprint, PlanError>
Sourcepub fn from_text_edit_plan(plan: EditPlan) -> Result<RefactorPlan, PlanError>
pub fn from_text_edit_plan(plan: EditPlan) -> Result<RefactorPlan, PlanError>
Converts a legacy edit envelope without losing text edits or extensions.
Sourcepub fn try_into_text_edit_plan(self) -> Result<EditPlan, PlanError>
pub fn try_into_text_edit_plan(self) -> Result<EditPlan, PlanError>
Converts to a legacy edit envelope if every operation is a text modify.
Trait Implementations§
Source§impl Clone for RefactorPlan
impl Clone for RefactorPlan
Source§fn clone(&self) -> RefactorPlan
fn clone(&self) -> RefactorPlan
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 moreSource§impl Debug for RefactorPlan
impl Debug for RefactorPlan
Source§impl<'de> Deserialize<'de> for RefactorPlan
impl<'de> Deserialize<'de> for RefactorPlan
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<RefactorPlan, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<RefactorPlan, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for RefactorPlan
impl PartialEq for RefactorPlan
Source§impl Serialize for RefactorPlan
impl Serialize for RefactorPlan
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for RefactorPlan
Auto Trait Implementations§
impl Freeze for RefactorPlan
impl RefUnwindSafe for RefactorPlan
impl Send for RefactorPlan
impl Sync for RefactorPlan
impl Unpin for RefactorPlan
impl UnsafeUnpin for RefactorPlan
impl UnwindSafe for RefactorPlan
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