[−][src]Enum webext_storage::sync::incoming::IncomingState
pub enum IncomingState { IncomingOnlyData { ext_id: String, data: Map<String, Value>, }, IncomingOnlyTombstone, HasLocal { ext_id: String, incoming: DataState, local: DataState, }, NotLocal { ext_id: String, incoming: DataState, mirror: DataState, }, Everywhere { ext_id: String, incoming: DataState, mirror: DataState, local: DataState, }, }
The "state" we find ourselves in when considering an incoming/staging record. This "state" is the input to calculating the IncomingAction and carries all the data we need to make the required local changes.
Variants
There's an incoming item, but data for that extension doesn't exist either in our local data store or in the local mirror. IOW, this is the very first time we've seen this extension.
An incoming tombstone that doesn't exist locally. Because tombstones don't carry the ext-id, it means it's not in our mirror. We are just going to ignore it, but we track the state for consistency.
There's an incoming item and we have data for the same extension in our local store - but not in our mirror. This should be relatively uncommon as it means:
- Some other profile has recently installed an extension and synced.
- This profile has recently installed the same extension.
- This is the first sync for this profile since both those events happened.
There's an incoming item and there's an item for the same extension in the mirror. The addon probably doesn't exist locally, or if it does, the last time we synced we synced the deletion of all data.
This will be the most common "incoming" case - there's data incoming, in the mirror and in the local store for an addon.
Trait Implementations
impl Debug for IncomingState
[src][+]
impl PartialEq<IncomingState> for IncomingState
[src][+]
impl StructuralPartialEq for IncomingState
[src]
Auto Trait Implementations
impl RefUnwindSafe for IncomingState
impl Send for IncomingState
impl Sync for IncomingState
impl Unpin for IncomingState
impl UnwindSafe for IncomingState
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src][+]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> From<T> for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[+]
V: MultiLane<T>,