Struct identity_iota::did::ServiceBuilder
source · [−]pub struct ServiceBuilder<D = CoreDID, T = BTreeMap<String, Value, Global>> where
D: DID, { /* private fields */ }
Expand description
A ServiceBuilder
is used to generate a customized Service
.
Implementations
sourceimpl<D, T> ServiceBuilder<D, T> where
D: DID,
impl<D, T> ServiceBuilder<D, T> where
D: DID,
sourcepub fn new(properties: T) -> ServiceBuilder<D, T>
pub fn new(properties: T) -> ServiceBuilder<D, T>
Creates a new ServiceBuilder
.
sourcepub fn id(self, value: DIDUrl<D>) -> ServiceBuilder<D, T>
pub fn id(self, value: DIDUrl<D>) -> ServiceBuilder<D, T>
Sets the id
value of the generated Service
.
sourcepub fn type_(self, value: impl Into<String>) -> ServiceBuilder<D, T>
pub fn type_(self, value: impl Into<String>) -> ServiceBuilder<D, T>
Sets the type
value of the generated Service
.
sourcepub fn service_endpoint(self, value: ServiceEndpoint) -> ServiceBuilder<D, T>
pub fn service_endpoint(self, value: ServiceEndpoint) -> ServiceBuilder<D, T>
Sets the serviceEndpoint
value of the generated Service
.
Trait Implementations
sourceimpl<D, T> Clone for ServiceBuilder<D, T> where
D: Clone + DID,
T: Clone,
impl<D, T> Clone for ServiceBuilder<D, T> where
D: Clone + DID,
T: Clone,
sourcefn clone(&self) -> ServiceBuilder<D, T>
fn clone(&self) -> ServiceBuilder<D, T>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<D, T> Default for ServiceBuilder<D, T> where
D: DID,
T: Default,
impl<D, T> Default for ServiceBuilder<D, T> where
D: DID,
T: Default,
sourcefn default() -> ServiceBuilder<D, T>
fn default() -> ServiceBuilder<D, T>
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl<D, T> RefUnwindSafe for ServiceBuilder<D, T> where
D: RefUnwindSafe,
T: RefUnwindSafe,
impl<D, T> Send for ServiceBuilder<D, T> where
D: Send,
T: Send,
impl<D, T> Sync for ServiceBuilder<D, T> where
D: Sync,
T: Sync,
impl<D, T> Unpin for ServiceBuilder<D, T> where
D: Unpin,
T: Unpin,
impl<D, T> UnwindSafe for ServiceBuilder<D, T> where
D: UnwindSafe,
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
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more