Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
PendingPayment.cs
1using System;
4
5namespace EDaler
6{
10 [TypeName(TypeNameSerialization.FullName)]
11 public class PendingPayment
12 {
13 private Guid id;
14 private DateTime expires = DateTime.MinValue;
15 private string currency = string.Empty;
16 private string from = string.Empty;
17 private string to = string.Empty;
18 private string uri = string.Empty;
19 private decimal amount = 0;
20
25 {
26 }
27
31 public Guid Id
32 {
33 get => this.id;
34 set => this.id = value;
35 }
36
40 public DateTime Expires
41 {
42 get => this.expires;
43 set => this.expires = value;
44 }
45
50 {
51 get => this.currency;
52 set => this.currency = value;
53 }
54
58 public decimal Amount
59 {
60 get => this.amount;
61 set => this.amount = value;
62 }
63
67 public string From
68 {
69 get => this.from;
70 set => this.from = value;
71 }
72
76 public string To
77 {
78 get => this.to;
79 set => this.to = value;
80 }
81
85 public string Uri
86 {
87 get => this.uri;
88 set => this.uri = value;
89 }
90
94 public override bool Equals(object obj)
95 {
96 if (!(obj is PendingPayment O))
97 return false;
98
99 if (this.id != O.id ||
100 this.expires != O.expires ||
101 this.currency != O.currency ||
102 this.amount != O.amount ||
103 this.from != O.from ||
104 this.to != O.to ||
105 this.uri != O.uri)
106 {
107 return false;
108 }
109
110 return true;
111 }
112
116 public override int GetHashCode()
117 {
118 int Result = this.id.GetHashCode();
119 Result ^= Result << 5 ^ this.expires.GetHashCode();
120 Result ^= Result << 5 ^ this.currency.GetHashCode();
121 Result ^= Result << 5 ^ this.amount.GetHashCode();
122 Result ^= Result << 5 ^ this.from.GetHashCode();
123 Result ^= Result << 5 ^ this.to.GetHashCode();
124 Result ^= Result << 5 ^ this.uri.GetHashCode();
125 return Result;
126 }
127
128 }
129}
Contains information about a pending payment.
DateTime Expires
When payment expires
decimal Amount
Amount
Guid Id
ID of payment
override int GetHashCode()
Object.GetHashCode()
override bool Equals(object obj)
Object.Equals(object)
CaseInsensitiveString Currency
Payment Currency
PendingPayment()
Contains information about a pending payment.
Represents a case-insensitive string.
TypeNameSerialization
How the type name should be serialized.