Skip to main content

Deployment

Struct Deployment 

Source
pub struct Deployment<I> {
    pub generation: u64,
    pub registry: Registry,
    pub plugin: Arc<I>,
}
Expand description

One consistent view of registration metadata and executable code. 注册元数据与可执行代码的一致视图。

Fields§

§generation: u64

Monotonic counter; compare successive snapshots to notice a swap. Starts at 0. 单调递增的计数器;比较前后快照即可察觉替换。初始为 0。

§registry: Registry

Registry snapshot that matches plugin. 与 plugin 相匹配的注册树快照。

§plugin: Arc<I>

Plugin instance serving this snapshot; the Arc keeps it alive for readers. 服务该快照的插件实例;Arc 让读者持有期间其保持存活。

Auto Trait Implementations§

§

impl<I> Freeze for Deployment<I>
where Arc<I>: Freeze,

§

impl<I> RefUnwindSafe for Deployment<I>
where Arc<I>: RefUnwindSafe,

§

impl<I> Send for Deployment<I>
where Arc<I>: Send,

§

impl<I> Sync for Deployment<I>
where Arc<I>: Sync,

§

impl<I> Unpin for Deployment<I>
where Arc<I>: Unpin,

§

impl<I> UnsafeUnpin for Deployment<I>
where Arc<I>: UnsafeUnpin,

§

impl<I> UnwindSafe for Deployment<I>
where Arc<I>: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.