17 return Identity is
null ||
18 Identity.State == IdentityState.Compromised ||
19 Identity.State == IdentityState.Obsoleted ||
30 return Identity is not
null && Identity.State ==
IdentityState.Approved;
40 if (Identity?.Attachments is
null)
43 if (!Identity.IsApproved())
46 bool HasFirstName =
false;
47 bool HasLastName =
false;
48 bool HasPersonalNumber =
false;
50 foreach (
Property P
in Identity.Properties)
63 HasPersonalNumber =
true;
68 if (!(HasFirstName && HasLastName && HasPersonalNumber))
71 Attachment? Photo = Identity.Attachments.GetFirstImageAttachment();
88 if (legalIdentity is not
null && legalIdentity.
Properties?.Length > 0)
91 return !
string.IsNullOrWhiteSpace(Jid) ? Jid : defaultValueIfNotFound;
101 if (Identity?.Properties is
null)
104 foreach (
Property P
in Identity.Properties)
133 return !Identity.IsOrganizational();
XMPP Protocol Properties.
const string PersonalNumber
Personal number
const string OrgAddress2
Organization Address line 2
const string OrgArea
Organization Area
const string OrgRegion
Organization Region
const string OrgCity
Organization City
const string OrgRole
Organization Role
const string OrgZipCode
Organization Zip Code
const string OrgCountry
Organization Country
const string OrgDepartment
Organization Department
const string Jid
Jabber ID
const string OrgAddress
Organization Address line 1
const string LastNames
Last names
const string OrgNumber
Organization number
const string FirstName
First name
const string OrgName
Organization name
A set of never changing property constants and helpful values.
Extensions for the LegalIdentity class.
static bool HasApprovedPersonalInformation(this LegalIdentity? Identity)
If the Legal Identity has an approved identity with personal information.
static bool IsPersonal(this LegalIdentity Identity)
Returns true if the legal identity does not have organizational properties.
static string GetJid(this LegalIdentity legalIdentity, string defaultValueIfNotFound="")
Returns the JID if the LegalIdentity has one, or the empty string otherwise.
static bool IsOrganizational(this LegalIdentity Identity)
Returns true if the legal identity has organizational properties.
static bool IsDiscarded(this LegalIdentity Identity)
Returns true if the legal identity is either null or is in a 'bad' state (rejected,...
static bool IsApproved(this LegalIdentity Identity)
Returns true if the legal identity has been approved.
Contains a reference to an attachment assigned to a legal object.
Property[] Properties
Properties detailing the legal identity.
string Name
Name of property
string Value
Property value
IdentityState
Lists recognized legal identity states.