Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
Authorization.cs
Go to the documentation of this file.
1namespace System.Net;
2
3public class Authorization
4{
5 private string[] _protectionRealm;
6
7 private bool _mutualAuth;
8
9 public string? Message { get; }
10
11 public string? ConnectionGroupId { get; }
12
13 public bool Complete { get; internal set; }
14
15 public string[]? ProtectionRealm
16 {
17 get
18 {
19 return _protectionRealm;
20 }
21 set
22 {
23 _protectionRealm = ((value != null && value.Length != 0) ? value : null);
24 }
25 }
26
28 {
29 get
30 {
31 if (Complete)
32 {
33 return _mutualAuth;
34 }
35 return false;
36 }
37 set
38 {
40 }
41 }
42
43 public Authorization(string? token)
44 : this(token, finished: true)
45 {
46 }
47
48 public Authorization(string? token, bool finished)
49 : this(token, finished, null)
50 {
51 }
52
53 public Authorization(string? token, bool finished, string? connectionGroupId)
54 : this(token, finished, connectionGroupId, mutualAuth: false)
55 {
56 }
57
58 internal Authorization(string token, bool finished, string connectionGroupId, bool mutualAuth)
59 {
60 Message = (string.IsNullOrEmpty(token) ? null : token);
61 ConnectionGroupId = (string.IsNullOrEmpty(connectionGroupId) ? null : connectionGroupId);
62 Complete = finished;
63 _mutualAuth = mutualAuth;
64 }
65}
Authorization(string token, bool finished, string connectionGroupId, bool mutualAuth)
Authorization(string? token)
Authorization(string? token, bool finished, string? connectionGroupId)
Authorization(string? token, bool finished)