pub struct Vecx<T> { /* private fields */ }Implementations
sourceimpl<T: ValueEnDe> Vecx<T>
impl<T: ValueEnDe> Vecx<T>
pub fn new() -> Self
pub fn get(&self, idx: usize) -> Option<T>
pub fn get_mut(&self, idx: usize) -> Option<ValueMut<'_, T>>
pub fn last(&self) -> Option<T>
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn push(&self, v: T)
pub fn push_ref(&self, v: &T)
pub fn insert(&self, idx: usize, v: T)
pub fn insert_ref(&self, idx: usize, v: &T)
pub fn pop(&self) -> Option<T>
pub fn remove(&self, idx: usize) -> T
pub fn swap_remove(&self, idx: usize) -> T
pub fn update(&self, idx: usize, v: T) -> Option<T>
pub fn update_ref(&self, idx: usize, v: &T) -> Option<T>
pub fn iter(&self) -> VecxIter<T>ⓘNotable traits for VecxIter<T>impl<T: ValueEnDe> Iterator for VecxIter<T> type Item = T;
pub fn clear(&self)
Trait Implementations
sourceimpl<'de, T> Deserialize<'de> for Vecx<T>
impl<'de, T> Deserialize<'de> for Vecx<T>
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<V> VsMgmt for Vecx<V>
impl<V> VsMgmt for Vecx<V>
sourcefn version_create(&self, _: VersionName<'_>) -> Result<()>
fn version_create(&self, _: VersionName<'_>) -> Result<()>
Create a new version on the default branch.
sourcefn version_create_by_branch(
&self,
_: VersionName<'_>,
__: BranchName<'_>
) -> Result<()>
fn version_create_by_branch(
&self,
_: VersionName<'_>,
__: BranchName<'_>
) -> Result<()>
Create a new version on a specified branch, NOTE: the branch must has been created. Read more
sourcefn version_exists(&self, _: VersionName<'_>) -> bool
fn version_exists(&self, _: VersionName<'_>) -> bool
Check if a verison exists on default branch.
sourcefn version_exists_on_branch(
&self,
_: VersionName<'_>,
__: BranchName<'_>
) -> bool
fn version_exists_on_branch(
&self,
_: VersionName<'_>,
__: BranchName<'_>
) -> bool
Check if a version exists on a specified branch(include its parents).
sourcefn version_pop(&self) -> Result<()>
fn version_pop(&self) -> Result<()>
Remove the newest version on the default branch. Read more
sourcefn version_pop_by_branch(&self, _: BranchName<'_>) -> Result<()>
fn version_pop_by_branch(&self, _: BranchName<'_>) -> Result<()>
Remove the newest version on a specified branch. Read more
sourceunsafe fn version_rebase(&self, _: VersionName<'_>) -> Result<()>
unsafe fn version_rebase(&self, _: VersionName<'_>) -> Result<()>
Merge all changes made by new versions after the base version into the base version. Read more
sourceunsafe fn version_rebase_by_branch(
&self,
_: VersionName<'_>,
_: BranchName<'_>
) -> Result<()>
unsafe fn version_rebase_by_branch(
&self,
_: VersionName<'_>,
_: BranchName<'_>
) -> Result<()>
Merge all changes made by new versions after the base version into the base version. Read more
fn version_exists_globally(&self, _: VersionName<'_>) -> bool
sourcefn version_list(&self) -> Result<Vec<VersionNameOwned>>
fn version_list(&self) -> Result<Vec<VersionNameOwned>>
NOTE Read more
sourcefn version_list_by_branch(
&self,
_: BranchName<'_>
) -> Result<Vec<VersionNameOwned>>
fn version_list_by_branch(
&self,
_: BranchName<'_>
) -> Result<Vec<VersionNameOwned>>
NOTE Read more
sourcefn version_list_globally(&self) -> Vec<VersionNameOwned>
fn version_list_globally(&self) -> Vec<VersionNameOwned>
NOTE Read more
fn version_has_change_set(&self, _: VersionName<'_>) -> Result<bool>
fn version_clean_up_globally(&self) -> Result<()>
sourceunsafe fn version_revert_globally(&self, _: VersionName<'_>) -> Result<()>
unsafe fn version_revert_globally(&self, _: VersionName<'_>) -> Result<()>
Safety Read more
sourcefn branch_create(
&self,
_: BranchName<'_>,
_: VersionName<'_>,
_: bool
) -> Result<()>
fn branch_create(
&self,
_: BranchName<'_>,
_: VersionName<'_>,
_: bool
) -> Result<()>
Create a new branch based on the head of the default branch.
sourcefn branch_create_by_base_branch(
&self,
_: BranchName<'_>,
_: VersionName<'_>,
_: ParentBranchName<'_>,
_: bool
) -> Result<()>
fn branch_create_by_base_branch(
&self,
_: BranchName<'_>,
_: VersionName<'_>,
_: ParentBranchName<'_>,
_: bool
) -> Result<()>
Create a new branch based on the head of a specified branch.
sourcefn branch_create_by_base_branch_version(
&self,
_: BranchName<'_>,
_: VersionName<'_>,
_: ParentBranchName<'_>,
_: VersionName<'_>,
_: bool
) -> Result<()>
fn branch_create_by_base_branch_version(
&self,
_: BranchName<'_>,
_: VersionName<'_>,
_: ParentBranchName<'_>,
_: VersionName<'_>,
_: bool
) -> Result<()>
Create a new branch based on a specified version of a specified branch.
sourceunsafe fn branch_create_without_new_version(
&self,
_: BranchName<'_>,
_: bool
) -> Result<()>
unsafe fn branch_create_without_new_version(
&self,
_: BranchName<'_>,
_: bool
) -> Result<()>
Safety Read more
sourceunsafe fn branch_create_by_base_branch_without_new_version(
&self,
_: BranchName<'_>,
_: ParentBranchName<'_>,
_: bool
) -> Result<()>
unsafe fn branch_create_by_base_branch_without_new_version(
&self,
_: BranchName<'_>,
_: ParentBranchName<'_>,
_: bool
) -> Result<()>
Safety Read more
sourceunsafe fn branch_create_by_base_branch_version_without_new_version(
&self,
_: BranchName<'_>,
_: ParentBranchName<'_>,
_: VersionName<'_>,
_: bool
) -> Result<()>
unsafe fn branch_create_by_base_branch_version_without_new_version(
&self,
_: BranchName<'_>,
_: ParentBranchName<'_>,
_: VersionName<'_>,
_: bool
) -> Result<()>
Safety Read more
sourcefn branch_exists(&self, _: BranchName<'_>) -> bool
fn branch_exists(&self, _: BranchName<'_>) -> bool
Check if a branch exists or not.
sourcefn branch_has_versions(&self, _: BranchName<'_>) -> bool
fn branch_has_versions(&self, _: BranchName<'_>) -> bool
Check if a branch exists and has versions on it.
sourcefn branch_remove(&self, _: BranchName<'_>) -> Result<()>
fn branch_remove(&self, _: BranchName<'_>) -> Result<()>
Remove a branch, remove all changes directly made by this branch. Read more
sourcefn branch_truncate(&self, _: BranchName<'_>) -> Result<()>
fn branch_truncate(&self, _: BranchName<'_>) -> Result<()>
Remove all changes directly made by versions(bigger than last_version_id) of this branch. Read more
sourcefn branch_truncate_to(
&self,
_: BranchName<'_>,
_: VersionName<'_>
) -> Result<()>
fn branch_truncate_to(
&self,
_: BranchName<'_>,
_: VersionName<'_>
) -> Result<()>
Remove all changes directly made by versions(bigger than last_version_id) of this branch. Read more
sourcefn branch_pop_version(&self, _: BranchName<'_>) -> Result<()>
fn branch_pop_version(&self, _: BranchName<'_>) -> Result<()>
Remove the newest version on a specified branch. Read more
sourcefn branch_merge_to(&self, _: BranchName<'_>, _: BranchName<'_>) -> Result<()>
fn branch_merge_to(&self, _: BranchName<'_>, _: BranchName<'_>) -> Result<()>
Merge a branch into another.
sourceunsafe fn branch_merge_to_force(
&self,
_: BranchName<'_>,
_: BranchName<'_>
) -> Result<()>
unsafe fn branch_merge_to_force(
&self,
_: BranchName<'_>,
_: BranchName<'_>
) -> Result<()>
Merge a branch into another, even if new different versions have been created on the target branch. Read more
sourcefn branch_set_default(&mut self, _: BranchName<'_>) -> Result<()>
fn branch_set_default(&mut self, _: BranchName<'_>) -> Result<()>
Make a branch to be default, all default operations will be applied to it. Read more
fn branch_is_empty(&self, _: BranchName<'_>) -> Result<bool>
sourcefn branch_list(&self) -> Vec<BranchNameOwned>
fn branch_list(&self) -> Vec<BranchNameOwned>
NOTE Read more
fn branch_get_default(&self) -> BranchNameOwned
sourceunsafe fn branch_swap(
&mut self,
_: BranchName<'_>,
_: BranchName<'_>
) -> Result<()>
unsafe fn branch_swap(
&mut self,
_: BranchName<'_>,
_: BranchName<'_>
) -> Result<()>
Logically similar to std::ptr::swap Read more
impl<T: Copy> Copy for Vecx<T>
impl<T: Eq> Eq for Vecx<T>
impl<T> StructuralEq for Vecx<T>
impl<T> StructuralPartialEq for Vecx<T>
Auto Trait Implementations
impl<T> RefUnwindSafe for Vecx<T> where
T: RefUnwindSafe,
impl<T> Send for Vecx<T> where
T: Send,
impl<T> Sync for Vecx<T> where
T: Sync,
impl<T> Unpin for Vecx<T> where
T: Unpin,
impl<T> UnwindSafe for Vecx<T> where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more