pub struct ProjectMembership {
pub id: String,
pub project_id: String,
pub member_did: String,
pub role: ProjectRole,
pub agreed_at_unix: u32,
pub agreed_at_instant: Option<InstantBridge>,
}Expand description
Membership of a DID in a project, with an agreed role.
Fields§
§id: String§project_id: String§member_did: String§role: ProjectRole§agreed_at_unix: u32§agreed_at_instant: Option<InstantBridge>High-resolution instant (T71 bridge). Preferred over agreed_at_unix
when present; the u32 field is kept for backward-compatible deserialization.
Implementations§
Source§impl ProjectMembership
impl ProjectMembership
Sourcepub fn new(
project_id: impl Into<String>,
member_did: impl Into<String>,
role: ProjectRole,
agreed_at_unix: u32,
) -> ProjectMembership
pub fn new( project_id: impl Into<String>, member_did: impl Into<String>, role: ProjectRole, agreed_at_unix: u32, ) -> ProjectMembership
Creates a new instance.
Sourcepub fn agreed_at(&self) -> InstantBridge
pub fn agreed_at(&self) -> InstantBridge
Resolve the agreed-at instant, preferring the high-resolution
InstantBridge field when present (T71 bridge).
Trait Implementations§
Source§impl Clone for ProjectMembership
impl Clone for ProjectMembership
Source§fn clone(&self) -> ProjectMembership
fn clone(&self) -> ProjectMembership
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ProjectMembership
impl Debug for ProjectMembership
Source§impl<'de> Deserialize<'de> for ProjectMembership
impl<'de> Deserialize<'de> for ProjectMembership
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ProjectMembership, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ProjectMembership, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ProjectMembership
Source§impl PartialEq for ProjectMembership
impl PartialEq for ProjectMembership
Source§impl Serialize for ProjectMembership
impl Serialize for ProjectMembership
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for ProjectMembership
Auto Trait Implementations§
impl Freeze for ProjectMembership
impl RefUnwindSafe for ProjectMembership
impl Send for ProjectMembership
impl Sync for ProjectMembership
impl Unpin for ProjectMembership
impl UnsafeUnpin for ProjectMembership
impl UnwindSafe for ProjectMembership
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more