12345678910111213141516171819202122232425262728 |
- using System.ComponentModel.DataAnnotations;
- using System.ComponentModel.DataAnnotations.Schema;
- using Microsoft.EntityFrameworkCore;
- namespace PCC2.Data.Entity;
- [Index(nameof(PublicKeyHash), IsUnique = true)]
- public class LocalPeer
- {
- [Key]
- [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
- public int Id { get; set; }
- public int DisplayOrder { get; set; }
- [Required]
- [MaxLength(128)]
- [Column(TypeName = "VARCHAR(128)")]
- public string? DisplayName { get; set; }
- [Required]
- public byte[]? PublicKeyHash { get; set; }
- [Required]
- public byte[]? PrivateKey { get; set; }
- public List<RemotePeer> RemotePeers { get; set; } = new();
- }
|