MCPcopy Create free account
hub / github.com/ceramicnetwork/rust-ceramic / build_fencepost

Method build_fencepost

core/src/peer.rs:223–225  ·  view source on GitHub ↗

Finish the build producing a partial [`PeerKey`].

(self)

Source from the content-addressed store, hash-verified

221impl Builder<WithExpiration> {
222 /// Finish the build producing a partial [`PeerKey`].
223 pub fn build_fencepost(self) -> PeerKey {
224 PeerKey(format!("{:0>11}", self.state.expiration))
225 }
226 /// Set the peer id. Note, a NodeKey is required so the [`PeerEntry`] can be signed.
227 pub fn with_id(self, id: &NodeKey) -> Builder<WithId<'_>> {
228 Builder {

Callers 15

random_interest_minFunction · 0.45
random_interest_maxFunction · 0.45
do_tickFunction · 0.45
get_interestsFunction · 0.45
get_interests_for_peerFunction · 0.45
all_peersMethod · 0.45
random_peer_key_minFunction · 0.45

Calls 1

PeerKeyClass · 0.85

Tested by 12

random_interest_minFunction · 0.36
random_interest_maxFunction · 0.36
get_interestsFunction · 0.36
get_interests_for_peerFunction · 0.36
random_peer_key_minFunction · 0.36
random_peer_key_maxFunction · 0.36
event_id_minFunction · 0.36
event_id_maxFunction · 0.36