using System; namespace RecruitmentDAL.DTO.CandidateDemographic { // MCANDIDATEDEMOGRAPHIC — voluntary, self-disclosed DEI/diversity data. One row per Candidate // (CANDIDATEID is UNIQUE on this table — see migration 20260904_Recruitment_Phase5_ // Analytics_Schema_SqlServer.sql's header comment for the full isolation rationale). This // table is deliberately never joined into any Candidate/Application read used during active // screening — the only sanctioned read paths are: // 1. ICandidateDemographicDAL.GetByCandidateId — internal upsert-lookup only, used by // CandidateDemographicBLL.SaveCandidateDemographic to decide insert vs update. NOT // exposed as a Get endpoint (see ICandidateDemographicBLL doc comment). // 2. The aggregated, cell-suppressed DeiSourcingReport (RecruitmentBLL.Reports. // DeiSourcingReport) — the only place individual rows are ever queried in bulk, and // only to produce suppressed group counts, never to surface an individual row. // // GenderIdentity/EthnicityRace: free-text, nullable — candidate's own words, not a closed // enum. DisabilityStatus/VeteranStatus/AgeBand: TINYINT, nullable, 0=PreferNotToSay by // convention (exact label sets are a resource-string/reporting concern, not encoded here). // ConsentToCollect must be true for any of the above to be considered a real disclosure — // see CandidateDemographicBLL.SaveCandidateDemographic's consent guard, the load-bearing // enforcement point for "voluntary" actually meaning voluntary. public class CandidateDemographicDTO { #region PrivateMembers #region CandidateDemographic private int candidatedemographicid; private int candidateid; private string? genderidentity; private string? ethnicityrace; private byte? disabilitystatus; private byte? veteranstatus; private byte? ageband; private bool consenttocollect; private DateTime? collectedon; #endregion #region Base private int createdbyid; private DateTime createdon; private string? createdbyname; private int modifiedbyid; private DateTime modifiedon; private string? modifiedbyname; #endregion #region Standard private byte status = 1; private short version; private int tenantid; #endregion #endregion #region PublicMembers #region CandidateDemographic public int CandidateDemographicId { get { return candidatedemographicid; } set { candidatedemographicid = value; } } public int CandidateId { get { return candidateid; } set { candidateid = value; } } public string? GenderIdentity { get { return genderidentity; } set { genderidentity = value; } } public string? EthnicityRace { get { return ethnicityrace; } set { ethnicityrace = value; } } public byte? DisabilityStatus { get { return disabilitystatus; } set { disabilitystatus = value; } } public byte? VeteranStatus { get { return veteranstatus; } set { veteranstatus = value; } } public byte? AgeBand { get { return ageband; } set { ageband = value; } } public bool ConsentToCollect { get { return consenttocollect; } set { consenttocollect = value; } } public DateTime? CollectedOn { get { return collectedon; } set { collectedon = value; } } #endregion #region Base public int CreatedById { get { return createdbyid; } set { createdbyid = value; } } public DateTime CreatedOn { get { return createdon; } set { createdon = value; } } public string? CreatedByName { get { return createdbyname; } set { createdbyname = value; } } public int ModifiedById { get { return modifiedbyid; } set { modifiedbyid = value; } } public DateTime ModifiedOn { get { return modifiedon; } set { modifiedon = value; } } public string? ModifiedByName { get { return modifiedbyname; } set { modifiedbyname = value; } } #endregion #region Standard public byte Status { get { return status; } set { status = value; } } public short Version { get { return version; } set { version = value; } } public int TenantId { get { return tenantid; } set { tenantid = value; } } #endregion #endregion } }