public override string ToString() { string peer = isHub ? "Hub" : "Peer"; string seen = LastSeen.ToString(); //connection == null ? "Connection Not Set" : (connection.Connected ? "Connected " : "Non Connected"); return("[" + peer + ": " + Address + ":" + Port + " " + seen + " ]"); }
public override string ToString() { var movieSB = new StringBuilder(); movieSB.AppendLine($"ID: {TitleId.ToString()}"); movieSB.AppendLine($"LastSeen: {LastSeen.ToString()}"); movieSB.AppendLine($"Soon: {Soon}"); return(movieSB.ToString()); }
protected override string[] GetContent() { return(new[] { ID.ToString("X"), ClientStatuses.GetStatusName(Status), LastSeen.ToString(), SentMsgCount.ToString(), ReceivedMsgCount.ToString() }); }
public List <Claim> ToClaims() { var claims = new List <Claim>(); claims.Add(new Claim("username", UserName)); claims.Add(new Claim("creation-date", CreationDate.ToString("o"))); claims.Add(new Claim("last-seen", LastSeen.ToString("o"))); claims.Add(new Claim("last-edit", LastEdit.ToString("o"))); claims.Add(new Claim("account-type", AccountType.ToString())); claims.Add(new Claim("account-status", AccountStatus.ToString())); claims.Add(new Claim("recovery-email", Email ?? string.Empty)); claims.Add(new Claim("recovery-verified", EmailConfirmed.ToString())); claims.Add(new Claim("2fa-enabled", TwoFactorEnabled.ToString())); claims.Add(new Claim("pgp-public-key", PGPPublicKey ?? string.Empty)); return(claims); }