summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorGreg Roach <greg@subaqua.co.uk>2026-02-06 11:38:07 +0000
committerGreg Roach <greg@subaqua.co.uk>2026-02-06 12:42:24 +0000
commit32648f848c9c5b657c3a3bc7882e0a55ae03f209 (patch)
treecec29123ac372a15632cf1e3c5c5694577c79323 /app
parent1e12bba2ff16616c8813810f50730aa8a0fb7985 (diff)
downloadwebtrees-32648f848c9c5b657c3a3bc7882e0a55ae03f209.tar.gz
webtrees-32648f848c9c5b657c3a3bc7882e0a55ae03f209.tar.bz2
webtrees-32648f848c9c5b657c3a3bc7882e0a55ae03f209.zip
Cleanup census classes
Diffstat (limited to 'app')
-rw-r--r--app/Census/AbstractCensusColumn.php89
-rw-r--r--app/Census/AbstractCensusColumnCondition.php83
-rw-r--r--app/Census/Census.php266
-rw-r--r--app/Census/CensusColumnAge.php13
-rw-r--r--app/Census/CensusColumnAgeFemale.php13
-rw-r--r--app/Census/CensusColumnAgeFemale5Years.php13
-rw-r--r--app/Census/CensusColumnAgeMale.php13
-rw-r--r--app/Census/CensusColumnAgeMale5Years.php13
-rw-r--r--app/Census/CensusColumnAgeMarried.php13
-rw-r--r--app/Census/CensusColumnAgeNextBirthDay.php13
-rw-r--r--app/Census/CensusColumnBirthDate.php13
-rw-r--r--app/Census/CensusColumnBirthDay.php13
-rw-r--r--app/Census/CensusColumnBirthDayDotMonthYear.php13
-rw-r--r--app/Census/CensusColumnBirthDayMonthYear.php13
-rw-r--r--app/Census/CensusColumnBirthDaySlashMonth.php13
-rw-r--r--app/Census/CensusColumnBirthDaySlashMonthYear.php13
-rw-r--r--app/Census/CensusColumnBirthMonth.php13
-rw-r--r--app/Census/CensusColumnBirthMonthDay.php13
-rw-r--r--app/Census/CensusColumnBirthPlace.php13
-rw-r--r--app/Census/CensusColumnBirthPlaceSimple.php27
-rw-r--r--app/Census/CensusColumnBirthYear.php13
-rw-r--r--app/Census/CensusColumnBornForeignParts.php13
-rw-r--r--app/Census/CensusColumnChildrenBornAlive.php13
-rw-r--r--app/Census/CensusColumnChildrenDied.php13
-rw-r--r--app/Census/CensusColumnChildrenLiving.php13
-rw-r--r--app/Census/CensusColumnConditionCanada.php24
-rw-r--r--app/Census/CensusColumnConditionCanadaMarriedSingle.php24
-rw-r--r--app/Census/CensusColumnConditionCanadaMarriedWidowed.php24
-rw-r--r--app/Census/CensusColumnConditionCanadaWidowed.php24
-rw-r--r--app/Census/CensusColumnConditionCanadaWidowedFemale.php24
-rw-r--r--app/Census/CensusColumnConditionCanadaWidowedMale.php24
-rw-r--r--app/Census/CensusColumnConditionDanish.php20
-rw-r--r--app/Census/CensusColumnConditionEnglish.php20
-rw-r--r--app/Census/CensusColumnConditionFrenchFemme.php24
-rw-r--r--app/Census/CensusColumnConditionFrenchFille.php24
-rw-r--r--app/Census/CensusColumnConditionFrenchGarcon.php24
-rw-r--r--app/Census/CensusColumnConditionFrenchHomme.php24
-rw-r--r--app/Census/CensusColumnConditionFrenchVeuf.php24
-rw-r--r--app/Census/CensusColumnConditionFrenchVeuve.php24
-rw-r--r--app/Census/CensusColumnConditionUs.php24
-rw-r--r--app/Census/CensusColumnFatherBirthPlace.php13
-rw-r--r--app/Census/CensusColumnFatherBirthPlaceSimple.php23
-rw-r--r--app/Census/CensusColumnFatherForeign.php13
-rw-r--r--app/Census/CensusColumnFullName.php13
-rw-r--r--app/Census/CensusColumnGivenNameInitial.php13
-rw-r--r--app/Census/CensusColumnGivenNames.php13
-rw-r--r--app/Census/CensusColumnInterface.php36
-rw-r--r--app/Census/CensusColumnMarriedWithinYear.php13
-rw-r--r--app/Census/CensusColumnMonthIfBornWithinYear.php13
-rw-r--r--app/Census/CensusColumnMonthIfMarriedWithinYear.php13
-rw-r--r--app/Census/CensusColumnMotherBirthPlace.php13
-rw-r--r--app/Census/CensusColumnMotherBirthPlaceSimple.php23
-rw-r--r--app/Census/CensusColumnMotherForeign.php13
-rw-r--r--app/Census/CensusColumnNationality.php15
-rw-r--r--app/Census/CensusColumnNull.php14
-rw-r--r--app/Census/CensusColumnOccupation.php13
-rw-r--r--app/Census/CensusColumnRelationToHead.php22
-rw-r--r--app/Census/CensusColumnRelationToHeadEnglish.php19
-rw-r--r--app/Census/CensusColumnRelationToHeadGerman.php19
-rw-r--r--app/Census/CensusColumnReligion.php13
-rw-r--r--app/Census/CensusColumnSexF.php30
-rw-r--r--app/Census/CensusColumnSexM.php30
-rw-r--r--app/Census/CensusColumnSexMF.php30
-rw-r--r--app/Census/CensusColumnSexMK.php16
-rw-r--r--app/Census/CensusColumnSexMZ.php17
-rw-r--r--app/Census/CensusColumnSurname.php13
-rw-r--r--app/Census/CensusColumnSurnameGivenNameInitial.php13
-rw-r--r--app/Census/CensusColumnSurnameGivenNames.php13
-rw-r--r--app/Census/CensusColumnYearsMarried.php13
-rw-r--r--app/Census/CensusInterface.php12
-rw-r--r--app/Census/CensusOfCanada.php17
-rw-r--r--app/Census/CensusOfCanada1851.php9
-rw-r--r--app/Census/CensusOfCanada1861.php14
-rw-r--r--app/Census/CensusOfCanada1871.php14
-rw-r--r--app/Census/CensusOfCanada1881.php14
-rw-r--r--app/Census/CensusOfCanada1891.php14
-rw-r--r--app/Census/CensusOfCanada1901.php14
-rw-r--r--app/Census/CensusOfCanada1911.php14
-rw-r--r--app/Census/CensusOfCanada1921.php14
-rw-r--r--app/Census/CensusOfCanada1931.php9
-rw-r--r--app/Census/CensusOfCanadaPraries1916.php14
-rw-r--r--app/Census/CensusOfCanadaPraries1926.php14
-rw-r--r--app/Census/CensusOfCzechRepublic.php17
-rw-r--r--app/Census/CensusOfCzechRepublic1880.php14
-rw-r--r--app/Census/CensusOfCzechRepublic1890.php14
-rw-r--r--app/Census/CensusOfCzechRepublic1900.php14
-rw-r--r--app/Census/CensusOfCzechRepublic1910.php14
-rw-r--r--app/Census/CensusOfCzechRepublic1921.php14
-rw-r--r--app/Census/CensusOfDenmark.php17
-rw-r--r--app/Census/CensusOfDenmark1787.php14
-rw-r--r--app/Census/CensusOfDenmark1801.php14
-rw-r--r--app/Census/CensusOfDenmark1803.php19
-rw-r--r--app/Census/CensusOfDenmark1834.php14
-rw-r--r--app/Census/CensusOfDenmark1835.php19
-rw-r--r--app/Census/CensusOfDenmark1840.php14
-rw-r--r--app/Census/CensusOfDenmark1845.php14
-rw-r--r--app/Census/CensusOfDenmark1850.php14
-rw-r--r--app/Census/CensusOfDenmark1855.php14
-rw-r--r--app/Census/CensusOfDenmark1860.php14
-rw-r--r--app/Census/CensusOfDenmark1870.php14
-rw-r--r--app/Census/CensusOfDenmark1880.php14
-rw-r--r--app/Census/CensusOfDenmark1885.php19
-rw-r--r--app/Census/CensusOfDenmark1890.php14
-rw-r--r--app/Census/CensusOfDenmark1901.php14
-rw-r--r--app/Census/CensusOfDenmark1906.php14
-rw-r--r--app/Census/CensusOfDenmark1911.php14
-rw-r--r--app/Census/CensusOfDenmark1916.php14
-rw-r--r--app/Census/CensusOfDenmark1921.php14
-rw-r--r--app/Census/CensusOfDenmark1925.php14
-rw-r--r--app/Census/CensusOfDenmark1930.php14
-rw-r--r--app/Census/CensusOfDenmark1940.php14
-rw-r--r--app/Census/CensusOfDeutschland.php17
-rw-r--r--app/Census/CensusOfDeutschland1819.php19
-rw-r--r--app/Census/CensusOfDeutschland1867.php19
-rw-r--r--app/Census/CensusOfDeutschland1900.php19
-rw-r--r--app/Census/CensusOfDeutschland1919.php19
-rw-r--r--app/Census/CensusOfDeutschlandNL1867.php19
-rw-r--r--app/Census/CensusOfEngland.php17
-rw-r--r--app/Census/CensusOfEngland1841.php14
-rw-r--r--app/Census/CensusOfEngland1851.php14
-rw-r--r--app/Census/CensusOfEngland1861.php14
-rw-r--r--app/Census/CensusOfEngland1871.php14
-rw-r--r--app/Census/CensusOfEngland1881.php14
-rw-r--r--app/Census/CensusOfEngland1891.php14
-rw-r--r--app/Census/CensusOfEngland1901.php14
-rw-r--r--app/Census/CensusOfEngland1911.php14
-rw-r--r--app/Census/CensusOfFrance.php17
-rw-r--r--app/Census/CensusOfFrance1831.php14
-rw-r--r--app/Census/CensusOfFrance1836.php14
-rw-r--r--app/Census/CensusOfFrance1841.php14
-rw-r--r--app/Census/CensusOfFrance1846.php14
-rw-r--r--app/Census/CensusOfFrance1851.php14
-rw-r--r--app/Census/CensusOfFrance1856.php14
-rw-r--r--app/Census/CensusOfFrance1861.php14
-rw-r--r--app/Census/CensusOfFrance1866.php14
-rw-r--r--app/Census/CensusOfFrance1872.php14
-rw-r--r--app/Census/CensusOfFrance1876.php14
-rw-r--r--app/Census/CensusOfFrance1881.php14
-rw-r--r--app/Census/CensusOfFrance1886.php14
-rw-r--r--app/Census/CensusOfFrance1891.php14
-rw-r--r--app/Census/CensusOfFrance1896.php14
-rw-r--r--app/Census/CensusOfFrance1901.php14
-rw-r--r--app/Census/CensusOfFrance1906.php14
-rw-r--r--app/Census/CensusOfFrance1911.php14
-rw-r--r--app/Census/CensusOfFrance1921.php14
-rw-r--r--app/Census/CensusOfFrance1926.php14
-rw-r--r--app/Census/CensusOfFrance1931.php14
-rw-r--r--app/Census/CensusOfFrance1936.php14
-rw-r--r--app/Census/CensusOfFrance1946.php14
-rw-r--r--app/Census/CensusOfRhodeIsland.php17
-rw-r--r--app/Census/CensusOfRhodeIsland1905.php14
-rw-r--r--app/Census/CensusOfRhodeIsland1915.php14
-rw-r--r--app/Census/CensusOfRhodeIsland1925.php14
-rw-r--r--app/Census/CensusOfScotland.php17
-rw-r--r--app/Census/CensusOfScotland1841.php14
-rw-r--r--app/Census/CensusOfScotland1851.php14
-rw-r--r--app/Census/CensusOfScotland1861.php14
-rw-r--r--app/Census/CensusOfScotland1871.php14
-rw-r--r--app/Census/CensusOfScotland1881.php14
-rw-r--r--app/Census/CensusOfScotland1891.php14
-rw-r--r--app/Census/CensusOfScotland1901.php14
-rw-r--r--app/Census/CensusOfScotland1911.php14
-rw-r--r--app/Census/CensusOfSlovakia.php17
-rw-r--r--app/Census/CensusOfSlovakia1869.php14
-rw-r--r--app/Census/CensusOfSlovakia1930.php14
-rw-r--r--app/Census/CensusOfSlovakia1940.php14
-rw-r--r--app/Census/CensusOfUnitedStates.php17
-rw-r--r--app/Census/CensusOfUnitedStates1790.php14
-rw-r--r--app/Census/CensusOfUnitedStates1800.php14
-rw-r--r--app/Census/CensusOfUnitedStates1810.php14
-rw-r--r--app/Census/CensusOfUnitedStates1820.php14
-rw-r--r--app/Census/CensusOfUnitedStates1830.php14
-rw-r--r--app/Census/CensusOfUnitedStates1840.php14
-rw-r--r--app/Census/CensusOfUnitedStates1850.php14
-rw-r--r--app/Census/CensusOfUnitedStates1860.php14
-rw-r--r--app/Census/CensusOfUnitedStates1870.php14
-rw-r--r--app/Census/CensusOfUnitedStates1880.php14
-rw-r--r--app/Census/CensusOfUnitedStates1890.php14
-rw-r--r--app/Census/CensusOfUnitedStates1900.php14
-rw-r--r--app/Census/CensusOfUnitedStates1910.php14
-rw-r--r--app/Census/CensusOfUnitedStates1920.php14
-rw-r--r--app/Census/CensusOfUnitedStates1930.php14
-rw-r--r--app/Census/CensusOfUnitedStates1940.php14
-rw-r--r--app/Census/CensusOfUnitedStates1950.php14
-rw-r--r--app/Census/CensusOfWales.php17
-rw-r--r--app/Census/CensusOfWales1841.php14
-rw-r--r--app/Census/CensusOfWales1851.php14
-rw-r--r--app/Census/CensusOfWales1861.php14
-rw-r--r--app/Census/CensusOfWales1871.php14
-rw-r--r--app/Census/CensusOfWales1881.php14
-rw-r--r--app/Census/CensusOfWales1891.php14
-rw-r--r--app/Census/CensusOfWales1901.php14
-rw-r--r--app/Census/CensusOfWales1911.php14
-rw-r--r--app/Census/CensusPlaceInterface.php15
-rw-r--r--app/Census/RegisterOfEngland1939.php14
-rw-r--r--app/Census/RegisterOfScotland1939.php14
-rw-r--r--app/Census/RegisterOfWales1939.php14
197 files changed, 566 insertions, 2880 deletions
diff --git a/app/Census/AbstractCensusColumn.php b/app/Census/AbstractCensusColumn.php
index 96f8c6a2b0..8bd65d6059 100644
--- a/app/Census/AbstractCensusColumn.php
+++ b/app/Census/AbstractCensusColumn.php
@@ -27,45 +27,26 @@ use function array_slice;
use function explode;
use function implode;
-/**
- * Definitions for a census column
- */
-class AbstractCensusColumn
+abstract readonly class AbstractCensusColumn
{
- private CensusInterface $census;
-
- private string $abbr;
-
- private string $title;
+ public function __construct(
+ private CensusInterface $census,
+ private string $abbreviation,
+ private string $title,
+ ) {
+ }
- /**
- * Create a column for a census
- *
- * @param CensusInterface $census The census to which this column forms part.
- * @param string $abbr The abbreviated on-screen name "BiC"
- * @param string $title The full column heading "Born in the county"
- */
- public function __construct(CensusInterface $census, string $abbr, string $title)
+ public function abbreviation(): string
{
- $this->census = $census;
- $this->abbr = $abbr;
- $this->title = $title;
+ return $this->abbreviation;
}
- /**
- * A short version of the column's name.
- *
- * @return string
- */
- public function abbreviation(): string
+ public function title(): string
{
- return $this->abbr;
+ return $this->title;
}
- /**
- * Find the father of an individual
- */
- public function father(Individual $individual): Individual|null
+ protected function father(Individual $individual): Individual|null
{
$family = $individual->childFamilies()->first();
@@ -76,10 +57,7 @@ class AbstractCensusColumn
return null;
}
- /**
- * Find the mother of an individual
- */
- public function mother(Individual $individual): Individual|null
+ protected function mother(Individual $individual): Individual|null
{
$family = $individual->childFamilies()->first();
@@ -90,10 +68,7 @@ class AbstractCensusColumn
return null;
}
- /**
- * Find the current spouse family of an individual
- */
- public function spouseFamily(Individual $individual): Family|null
+ protected function spouseFamily(Individual $individual): Family|null
{
return $individual->spouseFamilies()
// Exclude families that were created after this census date
@@ -103,9 +78,6 @@ class AbstractCensusColumn
}
/**
- * What was an individual's likely name on a given date, allowing
- * for marriages and married names.
- *
* @return array<string>
*/
protected function nameAtCensusDate(Individual $individual): array
@@ -135,31 +107,11 @@ class AbstractCensusColumn
return $name;
}
- /**
- * When did this census occur
- */
- public function date(): Date
+ protected function date(): Date
{
return new Date($this->census->censusDate());
}
- /**
- * The full version of the column's name.
- *
- * @return string
- */
- public function title(): string
- {
- return $this->title;
- }
-
- /**
- * Extract the country (last part) of a place name.
- *
- * @param string $place e.g. "London, England"
- *
- * @return string e.g. "England"
- */
protected function lastPartOfPlace(string $place): string
{
$parts = explode(', ', $place);
@@ -169,10 +121,6 @@ class AbstractCensusColumn
/**
* Remove the country of a place name, where it is the same as the census place
- *
- * @param string $place e.g. "London, England"
- *
- * @return string e.g. "London" (for census of England) and "London, England" elsewhere
*/
protected function notCountry(string $place): string
{
@@ -185,12 +133,7 @@ class AbstractCensusColumn
return $place;
}
- /**
- * Where did this census occur
- *
- * @return string
- */
- public function place(): string
+ protected function place(): string
{
return $this->census->censusPlace();
}
diff --git a/app/Census/AbstractCensusColumnCondition.php b/app/Census/AbstractCensusColumnCondition.php
index d44d83294e..e9899f208e 100644
--- a/app/Census/AbstractCensusColumnCondition.php
+++ b/app/Census/AbstractCensusColumnCondition.php
@@ -23,52 +23,40 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\Date;
use Fisharebest\Webtrees\Individual;
-/**
- * Marital status.
- */
-abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implements CensusColumnInterface
+abstract readonly class AbstractCensusColumnCondition extends AbstractCensusColumn implements CensusColumnInterface
{
- // Text to display for married males
+ // Text to display for married men
protected const string HUSBAND = '';
- // Text to display for married females
+ // Text to display for married women
protected const string WIFE = '';
- // Text to display for married unmarried males
+ // Text to display for married unmarried men
protected const string BACHELOR = '';
- // Text to display for married unmarried females
+ // Text to display for married unmarried women
protected const string SPINSTER = '';
- // Text to display for male children
+ // Text to display for boys
protected const string BOY = '';
- // Text to display for female children
+ // Text to display for girls
protected const string GIRL = '';
- // Text to display for divorced males
+ // Text to display for divorced men
protected const string DIVORCE = '';
- // Text to display for divorced females
+ // Text to display for divorced women
protected const string DIVORCEE = '';
- // Text to display for widowed males
+ // Text to display for widowed men
protected const string WIDOWER = '';
- // Text to display for widowed females
+ // Text to display for widowed women
protected const string WIDOW = '';
- // At what age is this individual recorded as an adult
protected const int AGE_ADULT = 15;
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$family = $this->spouseFamily($individual);
@@ -94,13 +82,6 @@ abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implem
return $this->conditionMarried($sex);
}
- /**
- * Is the individual a child.
- *
- * @param Individual $individual
- *
- * @return bool
- */
private function isChild(Individual $individual): bool
{
$age = new Age($individual->getEstimatedBirthDate(), $this->date());
@@ -108,13 +89,6 @@ abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implem
return $age->ageYears() < static::AGE_ADULT;
}
- /**
- * How is this condition written in a census column.
- *
- * @param string $sex
- *
- * @return string
- */
private function conditionChild(string $sex): string
{
if ($sex === 'F') {
@@ -124,13 +98,6 @@ abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implem
return static::BOY;
}
- /**
- * How is this condition written in a census column.
- *
- * @param string $sex
- *
- * @return string
- */
private function conditionSingle(string $sex): string
{
if ($sex === 'F') {
@@ -140,13 +107,6 @@ abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implem
return static::BACHELOR;
}
- /**
- * How is this condition written in a census column.
- *
- * @param string $sex
- *
- * @return string
- */
private function conditionDivorced(string $sex): string
{
if ($sex === 'F') {
@@ -156,25 +116,11 @@ abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implem
return static::DIVORCE;
}
- /**
- * Is the individual dead.
- *
- * @param Individual $individual
- *
- * @return bool
- */
private function isDead(Individual $individual): bool
{
return $individual->getDeathDate()->isOK() && Date::compare($individual->getDeathDate(), $this->date()) < 0;
}
- /**
- * How is this condition written in a census column.
- *
- * @param string $sex
- *
- * @return string
- */
private function conditionWidowed(string $sex): string
{
if ($sex === 'F') {
@@ -184,13 +130,6 @@ abstract class AbstractCensusColumnCondition extends AbstractCensusColumn implem
return static::WIDOWER;
}
- /**
- * How is this condition written in a census column.
- *
- * @param string $sex
- *
- * @return string
- */
private function conditionMarried(string $sex): string
{
if ($sex === 'F') {
diff --git a/app/Census/Census.php b/app/Census/Census.php
index 9b1b13f4c7..11e0031546 100644
--- a/app/Census/Census.php
+++ b/app/Census/Census.php
@@ -19,154 +19,132 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class Census
+readonly class Census
{
/**
- * @param string $locale
- *
- * @return array<CensusPlaceInterface>
+ * @return list<CensusPlaceInterface>
*/
public static function censusPlaces(string $locale): array
{
- switch ($locale) {
- case 'cs':
- return [
- new CensusOfCzechRepublic(),
- new CensusOfSlovakia(),
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfEngland(),
- new CensusOfFrance(),
- new CensusOfScotland(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfWales(),
- new CensusOfCanada(),
- ];
-
- case 'da':
- return [
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfCzechRepublic(),
- new CensusOfEngland(),
- new CensusOfFrance(),
- new CensusOfScotland(),
- new CensusOfSlovakia(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfWales(),
- new CensusOfCanada(),
- ];
-
- case 'de':
- return [
- new CensusOfDeutschland(),
- new CensusOfCzechRepublic(),
- new CensusOfDenmark(),
- new CensusOfEngland(),
- new CensusOfFrance(),
- new CensusOfScotland(),
- new CensusOfSlovakia(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfWales(),
- new CensusOfCanada(),
- ];
-
- case 'en-AU':
- case 'en-GB':
- return [
- new CensusOfEngland(),
- new CensusOfScotland(),
- new CensusOfWales(),
- new CensusOfCanada(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfCzechRepublic(),
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfFrance(),
- new CensusOfSlovakia(),
- ];
-
- case 'en-US':
- return [
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfCanada(),
- new CensusOfCzechRepublic(),
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfEngland(),
- new CensusOfFrance(),
- new CensusOfScotland(),
- new CensusOfSlovakia(),
- new CensusOfWales(),
- ];
-
- case 'fr':
- return [
- new CensusOfFrance(),
- new CensusOfCanada(),
- new CensusOfCzechRepublic(),
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfEngland(),
- new CensusOfScotland(),
- new CensusOfSlovakia(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfWales(),
- ];
-
- case 'fr-CA':
- return [
- new CensusOfCanada(),
- new CensusOfFrance(),
- new CensusOfCzechRepublic(),
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfEngland(),
- new CensusOfScotland(),
- new CensusOfSlovakia(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfWales(),
- ];
-
- case 'sk':
- return [
- new CensusOfSlovakia(),
- new CensusOfCzechRepublic(),
- new CensusOfDenmark(),
- new CensusOfDeutschland(),
- new CensusOfEngland(),
- new CensusOfFrance(),
- new CensusOfScotland(),
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfWales(),
- new CensusOfCanada(),
- ];
-
- default:
- return [
- new CensusOfUnitedStates(),
- new CensusOfRhodeIsland(),
- new CensusOfEngland(),
- new CensusOfScotland(),
- new CensusOfWales(),
- new CensusOfDeutschland(),
- new CensusOfFrance(),
- new CensusOfCzechRepublic(),
- new CensusOfSlovakia(),
- new CensusOfDenmark(),
- new CensusOfCanada(),
- ];
- }
+ return match ($locale) {
+ 'cs' => [
+ new CensusOfCzechRepublic(),
+ new CensusOfSlovakia(),
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfEngland(),
+ new CensusOfFrance(),
+ new CensusOfScotland(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfWales(),
+ new CensusOfCanada(),
+ ],
+ 'da' => [
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfCzechRepublic(),
+ new CensusOfEngland(),
+ new CensusOfFrance(),
+ new CensusOfScotland(),
+ new CensusOfSlovakia(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfWales(),
+ new CensusOfCanada(),
+ ],
+ 'de' => [
+ new CensusOfDeutschland(),
+ new CensusOfCzechRepublic(),
+ new CensusOfDenmark(),
+ new CensusOfEngland(),
+ new CensusOfFrance(),
+ new CensusOfScotland(),
+ new CensusOfSlovakia(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfWales(),
+ new CensusOfCanada(),
+ ],
+ 'en-AU',
+ 'en-GB' => [
+ new CensusOfEngland(),
+ new CensusOfScotland(),
+ new CensusOfWales(),
+ new CensusOfCanada(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfCzechRepublic(),
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfFrance(),
+ new CensusOfSlovakia(),
+ ],
+ 'en-US' => [
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfCanada(),
+ new CensusOfCzechRepublic(),
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfEngland(),
+ new CensusOfFrance(),
+ new CensusOfScotland(),
+ new CensusOfSlovakia(),
+ new CensusOfWales(),
+ ],
+ 'fr' => [
+ new CensusOfFrance(),
+ new CensusOfCanada(),
+ new CensusOfCzechRepublic(),
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfEngland(),
+ new CensusOfScotland(),
+ new CensusOfSlovakia(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfWales(),
+ ],
+ 'fr-CA' => [
+ new CensusOfCanada(),
+ new CensusOfFrance(),
+ new CensusOfCzechRepublic(),
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfEngland(),
+ new CensusOfScotland(),
+ new CensusOfSlovakia(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfWales(),
+ ],
+ 'sk' => [
+ new CensusOfSlovakia(),
+ new CensusOfCzechRepublic(),
+ new CensusOfDenmark(),
+ new CensusOfDeutschland(),
+ new CensusOfEngland(),
+ new CensusOfFrance(),
+ new CensusOfScotland(),
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfWales(),
+ new CensusOfCanada(),
+ ],
+ default => [
+ new CensusOfUnitedStates(),
+ new CensusOfRhodeIsland(),
+ new CensusOfEngland(),
+ new CensusOfScotland(),
+ new CensusOfWales(),
+ new CensusOfDeutschland(),
+ new CensusOfFrance(),
+ new CensusOfCzechRepublic(),
+ new CensusOfSlovakia(),
+ new CensusOfDenmark(),
+ new CensusOfCanada(),
+ ],
+ };
}
}
diff --git a/app/Census/CensusColumnAge.php b/app/Census/CensusColumnAge.php
index 780fa2b0f4..a4a3b7d832 100644
--- a/app/Census/CensusColumnAge.php
+++ b/app/Census/CensusColumnAge.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's age.
- */
-class CensusColumnAge extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAge extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$age = new Age($individual->getEstimatedBirthDate(), $this->date());
diff --git a/app/Census/CensusColumnAgeFemale.php b/app/Census/CensusColumnAgeFemale.php
index 8f044e5fbd..e819984fc8 100644
--- a/app/Census/CensusColumnAgeFemale.php
+++ b/app/Census/CensusColumnAgeFemale.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The age of a female individual.
- */
-class CensusColumnAgeFemale extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAgeFemale extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
if ($individual->sex() === 'M') {
diff --git a/app/Census/CensusColumnAgeFemale5Years.php b/app/Census/CensusColumnAgeFemale5Years.php
index 27b337cbdc..5d71adb865 100644
--- a/app/Census/CensusColumnAgeFemale5Years.php
+++ b/app/Census/CensusColumnAgeFemale5Years.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The age of a female individual (rounded down to the nearest 5 years).
- */
-class CensusColumnAgeFemale5Years extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAgeFemale5Years extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
if ($individual->sex() === 'M') {
diff --git a/app/Census/CensusColumnAgeMale.php b/app/Census/CensusColumnAgeMale.php
index 3ab10ba598..62837fb456 100644
--- a/app/Census/CensusColumnAgeMale.php
+++ b/app/Census/CensusColumnAgeMale.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The age of a male individual.
- */
-class CensusColumnAgeMale extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAgeMale extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
if ($individual->sex() === 'F') {
diff --git a/app/Census/CensusColumnAgeMale5Years.php b/app/Census/CensusColumnAgeMale5Years.php
index 880a1473c0..9fc039c01f 100644
--- a/app/Census/CensusColumnAgeMale5Years.php
+++ b/app/Census/CensusColumnAgeMale5Years.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The age of a male individual (rounded down to the nearest 5 years).
- */
-class CensusColumnAgeMale5Years extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAgeMale5Years extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
if ($individual->sex() === 'F') {
diff --git a/app/Census/CensusColumnAgeMarried.php b/app/Census/CensusColumnAgeMarried.php
index 86d8678a0d..f49e08b493 100644
--- a/app/Census/CensusColumnAgeMarried.php
+++ b/app/Census/CensusColumnAgeMarried.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * At what age did the individual marry.
- */
-class CensusColumnAgeMarried extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAgeMarried extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
if ($individual->getBirthDate()->isOK()) {
diff --git a/app/Census/CensusColumnAgeNextBirthDay.php b/app/Census/CensusColumnAgeNextBirthDay.php
index 067f682903..68aad54493 100644
--- a/app/Census/CensusColumnAgeNextBirthDay.php
+++ b/app/Census/CensusColumnAgeNextBirthDay.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Age;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's age at their NEXT BirthDay.
- */
-class CensusColumnAgeNextBirthDay extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnAgeNextBirthDay extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$age = new Age($individual->getEstimatedBirthDate(), $this->date());
diff --git a/app/Census/CensusColumnBirthDate.php b/app/Census/CensusColumnBirthDate.php
index 5a4bf3b188..0c318ded1f 100644
--- a/app/Census/CensusColumnBirthDate.php
+++ b/app/Census/CensusColumnBirthDate.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthDate extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthDate extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%j %n %Y');
diff --git a/app/Census/CensusColumnBirthDay.php b/app/Census/CensusColumnBirthDay.php
index 99bd7a9b2e..5b714c8cd7 100644
--- a/app/Census/CensusColumnBirthDay.php
+++ b/app/Census/CensusColumnBirthDay.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthDay extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthDay extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%j');
diff --git a/app/Census/CensusColumnBirthDayDotMonthYear.php b/app/Census/CensusColumnBirthDayDotMonthYear.php
index 661bdbbda6..6eec715fb9 100644
--- a/app/Census/CensusColumnBirthDayDotMonthYear.php
+++ b/app/Census/CensusColumnBirthDayDotMonthYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthDayDotMonthYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthDayDotMonthYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%j. %F %Y');
diff --git a/app/Census/CensusColumnBirthDayMonthYear.php b/app/Census/CensusColumnBirthDayMonthYear.php
index 43fe00e7a1..31914febff 100644
--- a/app/Census/CensusColumnBirthDayMonthYear.php
+++ b/app/Census/CensusColumnBirthDayMonthYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthDayMonthYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthDayMonthYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%j %M %Y');
diff --git a/app/Census/CensusColumnBirthDaySlashMonth.php b/app/Census/CensusColumnBirthDaySlashMonth.php
index 39c70aec10..8512e5c1d8 100644
--- a/app/Census/CensusColumnBirthDaySlashMonth.php
+++ b/app/Census/CensusColumnBirthDaySlashMonth.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthDaySlashMonth extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthDaySlashMonth extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%j/%n');
diff --git a/app/Census/CensusColumnBirthDaySlashMonthYear.php b/app/Census/CensusColumnBirthDaySlashMonthYear.php
index e6b47f0e3f..5c8c699dda 100644
--- a/app/Census/CensusColumnBirthDaySlashMonthYear.php
+++ b/app/Census/CensusColumnBirthDaySlashMonthYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthDaySlashMonthYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthDaySlashMonthYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%j/%n %Y');
diff --git a/app/Census/CensusColumnBirthMonth.php b/app/Census/CensusColumnBirthMonth.php
index 05a857f05a..2292fbe61d 100644
--- a/app/Census/CensusColumnBirthMonth.php
+++ b/app/Census/CensusColumnBirthMonth.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthMonth extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthMonth extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%M');
diff --git a/app/Census/CensusColumnBirthMonthDay.php b/app/Census/CensusColumnBirthMonthDay.php
index 1ae38a9e88..580f058fb3 100644
--- a/app/Census/CensusColumnBirthMonthDay.php
+++ b/app/Census/CensusColumnBirthMonthDay.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's month and date of birth.
- */
-class CensusColumnBirthMonthDay extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthMonthDay extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%M %j');
diff --git a/app/Census/CensusColumnBirthPlace.php b/app/Census/CensusColumnBirthPlace.php
index 9d275010f1..d46e925b58 100644
--- a/app/Census/CensusColumnBirthPlace.php
+++ b/app/Census/CensusColumnBirthPlace.php
@@ -23,19 +23,8 @@ use Fisharebest\Webtrees\Individual;
use function strlen;
-/**
- * The individual's birth place.
- */
-class CensusColumnBirthPlace extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthPlace extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$birth_place = $individual->getBirthPlace()->gedcomName();
diff --git a/app/Census/CensusColumnBirthPlaceSimple.php b/app/Census/CensusColumnBirthPlaceSimple.php
index 3361f5cfe4..68bc53afcd 100644
--- a/app/Census/CensusColumnBirthPlaceSimple.php
+++ b/app/Census/CensusColumnBirthPlaceSimple.php
@@ -21,21 +21,22 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's birth place.
- */
-class CensusColumnBirthPlaceSimple extends CensusColumnBirthPlace
+final readonly class CensusColumnBirthPlaceSimple extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
- return $this->lastPartOfPlace(parent::generate($individual, $head));
+ $birth_place = $individual->getBirthPlace()->gedcomName();
+ $census_place = $this->place();
+
+ // Ignore the census country
+ if ($birth_place === $census_place) {
+ return '';
+ }
+
+ if (substr($birth_place, -strlen($census_place) - 2) === ', ' . $census_place) {
+ $birth_place = substr($birth_place, 0, -strlen($census_place) - 2);
+ }
+
+ return $this->lastPartOfPlace($birth_place);
}
}
diff --git a/app/Census/CensusColumnBirthYear.php b/app/Census/CensusColumnBirthYear.php
index 824b63c5ce..bcf9bfa862 100644
--- a/app/Census/CensusColumnBirthYear.php
+++ b/app/Census/CensusColumnBirthYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's date of birth.
- */
-class CensusColumnBirthYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBirthYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
return $individual->getEstimatedBirthDate()->minimumDate()->format('%Y');
diff --git a/app/Census/CensusColumnBornForeignParts.php b/app/Census/CensusColumnBornForeignParts.php
index 90356313d5..20057c427e 100644
--- a/app/Census/CensusColumnBornForeignParts.php
+++ b/app/Census/CensusColumnBornForeignParts.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * Was the individual born in "foreign parts".
- */
-class CensusColumnBornForeignParts extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnBornForeignParts extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$birth_place = (string) $individual->getBirthPlace()->lastParts(1)->first();
diff --git a/app/Census/CensusColumnChildrenBornAlive.php b/app/Census/CensusColumnChildrenBornAlive.php
index 19023eac3a..2d6d147636 100644
--- a/app/Census/CensusColumnChildrenBornAlive.php
+++ b/app/Census/CensusColumnChildrenBornAlive.php
@@ -22,19 +22,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Date;
use Fisharebest\Webtrees\Individual;
-/**
- * The number of children born alive.
- */
-class CensusColumnChildrenBornAlive extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnChildrenBornAlive extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$family = $this->spouseFamily($individual);
diff --git a/app/Census/CensusColumnChildrenDied.php b/app/Census/CensusColumnChildrenDied.php
index 94f86a3e8d..db318d7797 100644
--- a/app/Census/CensusColumnChildrenDied.php
+++ b/app/Census/CensusColumnChildrenDied.php
@@ -22,19 +22,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Date;
use Fisharebest\Webtrees\Individual;
-/**
- * The number of children who have died.
- */
-class CensusColumnChildrenDied extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnChildrenDied extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$family = $this->spouseFamily($individual);
diff --git a/app/Census/CensusColumnChildrenLiving.php b/app/Census/CensusColumnChildrenLiving.php
index aa2e6e75ea..85dc337c4a 100644
--- a/app/Census/CensusColumnChildrenLiving.php
+++ b/app/Census/CensusColumnChildrenLiving.php
@@ -22,19 +22,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Date;
use Fisharebest\Webtrees\Individual;
-/**
- * The number of children who are still living.
- */
-class CensusColumnChildrenLiving extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnChildrenLiving extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$family = $this->spouseFamily($individual);
diff --git a/app/Census/CensusColumnConditionCanada.php b/app/Census/CensusColumnConditionCanada.php
index b8ca55911c..99b65f4880 100644
--- a/app/Census/CensusColumnConditionCanada.php
+++ b/app/Census/CensusColumnConditionCanada.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionCanada extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionCanada extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = 'M';
-
- // Text to display for married females
protected const string WIFE = 'M';
-
- // Text to display for married unmarried males
protected const string BACHELOR = 'S';
-
- // Text to display for married unmarried females
protected const string SPINSTER = 'S';
-
- // Text to display for male children
protected const string BOY = 'S';
-
- // Text to display for female children
protected const string GIRL = 'S';
-
- // Text to display for divorced males
protected const string DIVORCE = 'D';
-
- // Text to display for divorced females
protected const string DIVORCEE = 'D';
-
- // Text to display for widowed males
protected const string WIDOWER = 'W';
-
- // Text to display for widowed females
protected const string WIDOW = 'W';
}
diff --git a/app/Census/CensusColumnConditionCanadaMarriedSingle.php b/app/Census/CensusColumnConditionCanadaMarriedSingle.php
index b1f1fc29c7..cc9ff6be94 100644
--- a/app/Census/CensusColumnConditionCanadaMarriedSingle.php
+++ b/app/Census/CensusColumnConditionCanadaMarriedSingle.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionCanadaMarriedSingle extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionCanadaMarriedSingle extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = 'M';
-
- // Text to display for married females
protected const string WIFE = 'M';
-
- // Text to display for married unmarried males
protected const string BACHELOR = 'S';
-
- // Text to display for married unmarried females
protected const string SPINSTER = 'S';
-
- // Text to display for male children
protected const string BOY = 'S';
-
- // Text to display for female children
protected const string GIRL = 'S';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionCanadaMarriedWidowed.php b/app/Census/CensusColumnConditionCanadaMarriedWidowed.php
index 2f3b640031..cd7d0c2294 100644
--- a/app/Census/CensusColumnConditionCanadaMarriedWidowed.php
+++ b/app/Census/CensusColumnConditionCanadaMarriedWidowed.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionCanadaMarriedWidowed extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionCanadaMarriedWidowed extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = 'M';
-
- // Text to display for married females
protected const string WIFE = 'M';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = 'W';
-
- // Text to display for widowed females
protected const string WIDOW = 'W';
}
diff --git a/app/Census/CensusColumnConditionCanadaWidowed.php b/app/Census/CensusColumnConditionCanadaWidowed.php
index b1b3c620a9..1f397f708d 100644
--- a/app/Census/CensusColumnConditionCanadaWidowed.php
+++ b/app/Census/CensusColumnConditionCanadaWidowed.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionCanadaWidowed extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionCanadaWidowed extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = 'W';
-
- // Text to display for widowed females
protected const string WIDOW = 'W';
}
diff --git a/app/Census/CensusColumnConditionCanadaWidowedFemale.php b/app/Census/CensusColumnConditionCanadaWidowedFemale.php
index c007026386..14162c7e4b 100644
--- a/app/Census/CensusColumnConditionCanadaWidowedFemale.php
+++ b/app/Census/CensusColumnConditionCanadaWidowedFemale.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionCanadaWidowedFemale extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionCanadaWidowedFemale extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = 'W';
}
diff --git a/app/Census/CensusColumnConditionCanadaWidowedMale.php b/app/Census/CensusColumnConditionCanadaWidowedMale.php
index c75dcf2c51..f21e41e41b 100644
--- a/app/Census/CensusColumnConditionCanadaWidowedMale.php
+++ b/app/Census/CensusColumnConditionCanadaWidowedMale.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionCanadaWidowedMale extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionCanadaWidowedMale extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = 'W';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionDanish.php b/app/Census/CensusColumnConditionDanish.php
index 89939d58fd..9318b77d74 100644
--- a/app/Census/CensusColumnConditionDanish.php
+++ b/app/Census/CensusColumnConditionDanish.php
@@ -19,32 +19,14 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionDanish extends CensusColumnConditionEnglish
+final readonly class CensusColumnConditionDanish extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = 'Gift';
-
- // Text to display for married females
protected const string WIFE = 'Gift';
-
- // Text to display for married unmarried males
protected const string BACHELOR = 'Ugift';
-
- // Text to display for married unmarried females
protected const string SPINSTER = 'Ugift';
-
- // Text to display for divorced males
protected const string DIVORCE = 'Skilt';
-
- // Text to display for divorced females
protected const string DIVORCEE = 'Skilt';
-
- // Text to display for widowed males
protected const string WIDOWER = 'Gift';
-
- // Text to display for widowed females
protected const string WIDOW = 'Gift';
}
diff --git a/app/Census/CensusColumnConditionEnglish.php b/app/Census/CensusColumnConditionEnglish.php
index 650a4e1015..80ad5292d5 100644
--- a/app/Census/CensusColumnConditionEnglish.php
+++ b/app/Census/CensusColumnConditionEnglish.php
@@ -19,32 +19,14 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionEnglish extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionEnglish extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = 'Mar';
-
- // Text to display for married females
protected const string WIFE = 'Mar';
-
- // Text to display for married unmarried males
protected const string BACHELOR = 'Unm';
-
- // Text to display for married unmarried females
protected const string SPINSTER = 'Unm';
-
- // Text to display for divorced males
protected const string DIVORCE = 'Div';
-
- // Text to display for divorced females
protected const string DIVORCEE = 'Div';
-
- // Text to display for widowed males
protected const string WIDOWER = 'Wid';
-
- // Text to display for widowed females
protected const string WIDOW = 'Wid';
}
diff --git a/app/Census/CensusColumnConditionFrenchFemme.php b/app/Census/CensusColumnConditionFrenchFemme.php
index 257e8c6a7d..d776c11717 100644
--- a/app/Census/CensusColumnConditionFrenchFemme.php
+++ b/app/Census/CensusColumnConditionFrenchFemme.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionFrenchFemme extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionFrenchFemme extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '1';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '1';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionFrenchFille.php b/app/Census/CensusColumnConditionFrenchFille.php
index 8bf94eaeea..9305394c1a 100644
--- a/app/Census/CensusColumnConditionFrenchFille.php
+++ b/app/Census/CensusColumnConditionFrenchFille.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionFrenchFille extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionFrenchFille extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '1';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '1';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionFrenchGarcon.php b/app/Census/CensusColumnConditionFrenchGarcon.php
index 34dd07856f..5420729157 100644
--- a/app/Census/CensusColumnConditionFrenchGarcon.php
+++ b/app/Census/CensusColumnConditionFrenchGarcon.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionFrenchGarcon extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionFrenchGarcon extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '1';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '1';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionFrenchHomme.php b/app/Census/CensusColumnConditionFrenchHomme.php
index f05b2a2471..bf3e857b49 100644
--- a/app/Census/CensusColumnConditionFrenchHomme.php
+++ b/app/Census/CensusColumnConditionFrenchHomme.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionFrenchHomme extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionFrenchHomme extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '1';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '1';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionFrenchVeuf.php b/app/Census/CensusColumnConditionFrenchVeuf.php
index cf2b19db50..329b12de57 100644
--- a/app/Census/CensusColumnConditionFrenchVeuf.php
+++ b/app/Census/CensusColumnConditionFrenchVeuf.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionFrenchVeuf extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionFrenchVeuf extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '1';
-
- // Text to display for widowed females
protected const string WIDOW = '';
}
diff --git a/app/Census/CensusColumnConditionFrenchVeuve.php b/app/Census/CensusColumnConditionFrenchVeuve.php
index 5ead58c03d..97f6c27d29 100644
--- a/app/Census/CensusColumnConditionFrenchVeuve.php
+++ b/app/Census/CensusColumnConditionFrenchVeuve.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionFrenchVeuve extends AbstractCensusColumnCondition
+final readonly class CensusColumnConditionFrenchVeuve extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = '';
-
- // Text to display for married females
protected const string WIFE = '';
-
- // Text to display for married unmarried males
protected const string BACHELOR = '';
-
- // Text to display for married unmarried females
protected const string SPINSTER = '';
-
- // Text to display for male children
protected const string BOY = '';
-
- // Text to display for female children
protected const string GIRL = '';
-
- // Text to display for divorced males
protected const string DIVORCE = '';
-
- // Text to display for divorced females
protected const string DIVORCEE = '';
-
- // Text to display for widowed males
protected const string WIDOWER = '';
-
- // Text to display for widowed females
protected const string WIDOW = '1';
}
diff --git a/app/Census/CensusColumnConditionUs.php b/app/Census/CensusColumnConditionUs.php
index 316c588940..febb29c042 100644
--- a/app/Census/CensusColumnConditionUs.php
+++ b/app/Census/CensusColumnConditionUs.php
@@ -19,38 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Marital status.
- */
-class CensusColumnConditionUs extends CensusColumnConditionEnglish
+final readonly class CensusColumnConditionUs extends AbstractCensusColumnCondition
{
- // Text to display for married males
protected const string HUSBAND = 'M';
-
- // Text to display for married females
protected const string WIFE = 'M';
-
- // Text to display for married unmarried males
protected const string BACHELOR = 'S';
-
- // Text to display for married unmarried females
protected const string SPINSTER = 'S';
-
- // Text to display for male children
protected const string BOY = 'S';
-
- // Text to display for female children
protected const string GIRL = 'S';
-
- // Text to display for divorced males
protected const string DIVORCE = 'D';
-
- // Text to display for divorced females
protected const string DIVORCEE = 'D';
-
- // Text to display for widowed males
protected const string WIDOWER = 'W';
-
- // Text to display for widowed females
protected const string WIDOW = 'W';
}
diff --git a/app/Census/CensusColumnFatherBirthPlace.php b/app/Census/CensusColumnFatherBirthPlace.php
index c1d6e39d5d..dcfe8dfa33 100644
--- a/app/Census/CensusColumnFatherBirthPlace.php
+++ b/app/Census/CensusColumnFatherBirthPlace.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * Birth place of the individual's father.
- */
-class CensusColumnFatherBirthPlace extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnFatherBirthPlace extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$father = $this->father($individual);
diff --git a/app/Census/CensusColumnFatherBirthPlaceSimple.php b/app/Census/CensusColumnFatherBirthPlaceSimple.php
index 705894ad9c..a34aea1e3c 100644
--- a/app/Census/CensusColumnFatherBirthPlaceSimple.php
+++ b/app/Census/CensusColumnFatherBirthPlaceSimple.php
@@ -21,21 +21,18 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's father's birth place.
- */
-class CensusColumnFatherBirthPlaceSimple extends CensusColumnFatherBirthPlace
+final readonly class CensusColumnFatherBirthPlaceSimple extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
- return $this->lastPartOfPlace(parent::generate($individual, $head));
+ $father = $this->father($individual);
+
+ if ($father instanceof Individual) {
+ $place = $this->notCountry($father->getBirthPlace()->gedcomName());
+
+ return $this->lastPartOfPlace($place);
+ }
+
+ return '';
}
}
diff --git a/app/Census/CensusColumnFatherForeign.php b/app/Census/CensusColumnFatherForeign.php
index 769cc6bd17..b1f12e889a 100644
--- a/app/Census/CensusColumnFatherForeign.php
+++ b/app/Census/CensusColumnFatherForeign.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * Is the individual's father a foreigner?
- */
-class CensusColumnFatherForeign extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnFatherForeign extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$father = $this->father($individual);
diff --git a/app/Census/CensusColumnFullName.php b/app/Census/CensusColumnFullName.php
index 1e3b933fb4..852bf72392 100644
--- a/app/Census/CensusColumnFullName.php
+++ b/app/Census/CensusColumnFullName.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's full name.
- */
-class CensusColumnFullName extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnFullName extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$name = $this->nameAtCensusDate($individual);
diff --git a/app/Census/CensusColumnGivenNameInitial.php b/app/Census/CensusColumnGivenNameInitial.php
index 5faea70a7b..4531bc9304 100644
--- a/app/Census/CensusColumnGivenNameInitial.php
+++ b/app/Census/CensusColumnGivenNameInitial.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's full name.
- */
-class CensusColumnGivenNameInitial extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnGivenNameInitial extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
foreach ($individual->getAllNames() as $name) {
diff --git a/app/Census/CensusColumnGivenNames.php b/app/Census/CensusColumnGivenNames.php
index 62e83fc0cd..3a8176f6be 100644
--- a/app/Census/CensusColumnGivenNames.php
+++ b/app/Census/CensusColumnGivenNames.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's full name.
- */
-class CensusColumnGivenNames extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnGivenNames extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
foreach ($individual->getAllNames() as $name) {
diff --git a/app/Census/CensusColumnInterface.php b/app/Census/CensusColumnInterface.php
index 6dd00e4beb..8c5fea4c1b 100644
--- a/app/Census/CensusColumnInterface.php
+++ b/app/Census/CensusColumnInterface.php
@@ -27,41 +27,9 @@ use Fisharebest\Webtrees\Individual;
*/
interface CensusColumnInterface
{
- /**
- * A short version of the column's name.
- *
- * @return string
- */
- public function abbreviation(): string;
+ public function title(): string;
- /**
- * When did this census occur
- *
- * @return Date
- */
- public function date(): Date;
+ public function abbreviation(): string;
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string;
-
- /**
- * Where did this census occur
- *
- * @return string
- */
- public function place(): string;
-
- /**
- * The full version of the column's name.
- *
- * @return string
- */
- public function title(): string;
}
diff --git a/app/Census/CensusColumnMarriedWithinYear.php b/app/Census/CensusColumnMarriedWithinYear.php
index 000ba1a3cf..a8e1677a39 100644
--- a/app/Census/CensusColumnMarriedWithinYear.php
+++ b/app/Census/CensusColumnMarriedWithinYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * Did the individual marry within the last year.
- */
-class CensusColumnMarriedWithinYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnMarriedWithinYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
foreach ($individual->spouseFamilies() as $family) {
diff --git a/app/Census/CensusColumnMonthIfBornWithinYear.php b/app/Census/CensusColumnMonthIfBornWithinYear.php
index 8c84d66012..25a61ddb21 100644
--- a/app/Census/CensusColumnMonthIfBornWithinYear.php
+++ b/app/Census/CensusColumnMonthIfBornWithinYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The month of birth, if within the last year.
- */
-class CensusColumnMonthIfBornWithinYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnMonthIfBornWithinYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$birth_jd = $individual->getBirthDate()->julianDay();
diff --git a/app/Census/CensusColumnMonthIfMarriedWithinYear.php b/app/Census/CensusColumnMonthIfMarriedWithinYear.php
index 12d11a27a5..0c6c3d9c52 100644
--- a/app/Census/CensusColumnMonthIfMarriedWithinYear.php
+++ b/app/Census/CensusColumnMonthIfMarriedWithinYear.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The month of marriage, if within the last year.
- */
-class CensusColumnMonthIfMarriedWithinYear extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnMonthIfMarriedWithinYear extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
foreach ($individual->spouseFamilies() as $family) {
diff --git a/app/Census/CensusColumnMotherBirthPlace.php b/app/Census/CensusColumnMotherBirthPlace.php
index 7dfce8166b..66d4b2ea7c 100644
--- a/app/Census/CensusColumnMotherBirthPlace.php
+++ b/app/Census/CensusColumnMotherBirthPlace.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * Birth place of the individual's mother.
- */
-class CensusColumnMotherBirthPlace extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnMotherBirthPlace extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$mother = $this->mother($individual);
diff --git a/app/Census/CensusColumnMotherBirthPlaceSimple.php b/app/Census/CensusColumnMotherBirthPlaceSimple.php
index efb2a20e5e..419e8e27fe 100644
--- a/app/Census/CensusColumnMotherBirthPlaceSimple.php
+++ b/app/Census/CensusColumnMotherBirthPlaceSimple.php
@@ -21,21 +21,18 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's mother's birth place.
- */
-class CensusColumnMotherBirthPlaceSimple extends CensusColumnMotherBirthPlace
+final readonly class CensusColumnMotherBirthPlaceSimple extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
- return $this->lastPartOfPlace(parent::generate($individual, $head));
+ $mother = $this->mother($individual);
+
+ if ($mother instanceof Individual) {
+ $place = $this->notCountry($mother->getBirthPlace()->gedcomName());
+
+ return $this->lastPartOfPlace($place);
+ }
+
+ return '';
}
}
diff --git a/app/Census/CensusColumnMotherForeign.php b/app/Census/CensusColumnMotherForeign.php
index d83de87c8b..ac9bafde28 100644
--- a/app/Census/CensusColumnMotherForeign.php
+++ b/app/Census/CensusColumnMotherForeign.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * Is the individual's mother a foreigner?
- */
-class CensusColumnMotherForeign extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnMotherForeign extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$mother = $this->mother($individual);
diff --git a/app/Census/CensusColumnNationality.php b/app/Census/CensusColumnNationality.php
index 6762a9f6ae..6adbaddfbf 100644
--- a/app/Census/CensusColumnNationality.php
+++ b/app/Census/CensusColumnNationality.php
@@ -22,10 +22,7 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Date;
use Fisharebest\Webtrees\Individual;
-/**
- * The nationality of the individual.
- */
-class CensusColumnNationality extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnNationality extends AbstractCensusColumn implements CensusColumnInterface
{
// Convert a country name to a nationality
private const array NATIONALITIES = [
@@ -36,14 +33,6 @@ class CensusColumnNationality extends AbstractCensusColumn implements CensusColu
'Canada' => 'Canadian',
];
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$place = $individual->getBirthPlace()->gedcomName();
@@ -53,7 +42,7 @@ class CensusColumnNationality extends AbstractCensusColumn implements CensusColu
$place = $this->place();
}
- // Did we emigrate or naturalise?
+ // Did we emigrate or naturalize?
foreach ($individual->facts(['IMMI', 'EMIG', 'NATU'], true) as $fact) {
if (Date::compare($fact->date(), $this->date()) <= 0) {
$place = $fact->place()->gedcomName();
diff --git a/app/Census/CensusColumnNull.php b/app/Census/CensusColumnNull.php
index ba46234f59..262b7d0e1d 100644
--- a/app/Census/CensusColumnNull.php
+++ b/app/Census/CensusColumnNull.php
@@ -21,21 +21,11 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * A column that we cannot generate.
- */
-class CensusColumnNull extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnNull extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
+ // This is a column that we cannot generate from data we might already have.
return '';
}
}
diff --git a/app/Census/CensusColumnOccupation.php b/app/Census/CensusColumnOccupation.php
index cd30d4349e..8b32e7f28f 100644
--- a/app/Census/CensusColumnOccupation.php
+++ b/app/Census/CensusColumnOccupation.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's occupation.
- */
-class CensusColumnOccupation extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnOccupation extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
foreach ($individual->facts(['OCCU']) as $fact) {
diff --git a/app/Census/CensusColumnRelationToHead.php b/app/Census/CensusColumnRelationToHead.php
index 204356611d..10409867e3 100644
--- a/app/Census/CensusColumnRelationToHead.php
+++ b/app/Census/CensusColumnRelationToHead.php
@@ -23,29 +23,15 @@ use Fisharebest\Webtrees\Individual;
use Fisharebest\Webtrees\Registry;
use Fisharebest\Webtrees\Services\RelationshipService;
-/**
- * Relationship to head of household.
- */
-class CensusColumnRelationToHead extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnRelationToHead extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string HEAD_OF_HOUSEHOLD = '-';
-
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
if ($individual === $head) {
- return static::HEAD_OF_HOUSEHOLD;
+ return '-';
}
- $relationship_service = Registry::container()->get(RelationshipService::class);
-
- return $relationship_service->getCloseRelationshipName($head, $individual);
+ return Registry::container()->get(RelationshipService::class)
+ ->getCloseRelationshipName($head, $individual);
}
}
diff --git a/app/Census/CensusColumnRelationToHeadEnglish.php b/app/Census/CensusColumnRelationToHeadEnglish.php
index e9d96135d8..288b90d23f 100644
--- a/app/Census/CensusColumnRelationToHeadEnglish.php
+++ b/app/Census/CensusColumnRelationToHeadEnglish.php
@@ -19,10 +19,19 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Relationship to head of household.
- */
-class CensusColumnRelationToHeadEnglish extends CensusColumnRelationToHead
+use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Registry;
+use Fisharebest\Webtrees\Services\RelationshipService;
+
+final readonly class CensusColumnRelationToHeadEnglish extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string HEAD_OF_HOUSEHOLD = 'head';
+ public function generate(Individual $individual, Individual $head): string
+ {
+ if ($individual === $head) {
+ return 'head';
+ }
+
+ return Registry::container()->get(RelationshipService::class)
+ ->getCloseRelationshipName($head, $individual);
+ }
}
diff --git a/app/Census/CensusColumnRelationToHeadGerman.php b/app/Census/CensusColumnRelationToHeadGerman.php
index bc8b83d01c..767ebb26c2 100644
--- a/app/Census/CensusColumnRelationToHeadGerman.php
+++ b/app/Census/CensusColumnRelationToHeadGerman.php
@@ -19,10 +19,19 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Relationship to head of household.
- */
-class CensusColumnRelationToHeadGerman extends CensusColumnRelationToHead
+use Fisharebest\Webtrees\Individual;
+use Fisharebest\Webtrees\Registry;
+use Fisharebest\Webtrees\Services\RelationshipService;
+
+final readonly class CensusColumnRelationToHeadGerman extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string HEAD_OF_HOUSEHOLD = 'Haushaltungsvorstand';
+ public function generate(Individual $individual, Individual $head): string
+ {
+ if ($individual === $head) {
+ return 'Haushaltungsvorstand';
+ }
+
+ return Registry::container()->get(RelationshipService::class)
+ ->getCloseRelationshipName($head, $individual);
+ }
}
diff --git a/app/Census/CensusColumnReligion.php b/app/Census/CensusColumnReligion.php
index 3a357f76dc..316d58e6ef 100644
--- a/app/Census/CensusColumnReligion.php
+++ b/app/Census/CensusColumnReligion.php
@@ -22,19 +22,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Fact;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's religion.
- */
-class CensusColumnReligion extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnReligion extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$reli_fact = $individual->facts(['RELI'])->first();
diff --git a/app/Census/CensusColumnSexF.php b/app/Census/CensusColumnSexF.php
index c669d0ccff..6e12a11d46 100644
--- a/app/Census/CensusColumnSexF.php
+++ b/app/Census/CensusColumnSexF.php
@@ -21,33 +21,13 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's sex Female?
- */
-class CensusColumnSexF extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnSexF extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string MALE = 'M';
-
- protected const string FEMALE = 'F';
-
- protected const string X = 'X';
-
- /**
- * Generate the likely value of this census column, based on available information.
- * X is the value returned for this column as it is a selection of F column or M
- * column.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
- if ($individual->sex() === 'F') {
- return static::X;
- }
-
- return '';
+ return match ($individual->sex()) {
+ 'F' => 'X',
+ default => '',
+ };
}
}
diff --git a/app/Census/CensusColumnSexM.php b/app/Census/CensusColumnSexM.php
index a76d02d771..b3d37bd3e5 100644
--- a/app/Census/CensusColumnSexM.php
+++ b/app/Census/CensusColumnSexM.php
@@ -21,33 +21,13 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's sex Male?
- */
-class CensusColumnSexM extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnSexM extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string MALE = 'M';
-
- protected const string FEMALE = 'F';
-
- protected const string X = 'X';
-
- /**
- * Generate the likely value of this census column, based on available information.
- * X is the value returned for this column as it is a selection of F column or M
- * column.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
- if ($individual->sex() === 'M') {
- return static::X;
- }
-
- return '';
+ return match ($individual->sex()) {
+ 'M' => 'X',
+ default => '',
+ };
}
}
diff --git a/app/Census/CensusColumnSexMF.php b/app/Census/CensusColumnSexMF.php
index 742b7d787b..47df59c5dd 100644
--- a/app/Census/CensusColumnSexMF.php
+++ b/app/Census/CensusColumnSexMF.php
@@ -21,32 +21,14 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's sex.
- */
-class CensusColumnSexMF extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnSexMF extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string MALE = 'M';
-
- protected const string FEMALE = 'F';
-
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
- switch ($individual->sex()) {
- case 'M':
- return static::MALE;
- case 'F':
- return static::FEMALE;
- default:
- return '';
- }
+ return match ($individual->sex()) {
+ 'M' => 'M',
+ 'F' => 'F',
+ default => '',
+ };
}
}
diff --git a/app/Census/CensusColumnSexMK.php b/app/Census/CensusColumnSexMK.php
index f0e923b366..5db92ff5ed 100644
--- a/app/Census/CensusColumnSexMK.php
+++ b/app/Census/CensusColumnSexMK.php
@@ -19,10 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * The individual's sex.
- */
-class CensusColumnSexMK extends CensusColumnSexMF
+use Fisharebest\Webtrees\Individual;
+
+final readonly class CensusColumnSexMK extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string FEMALE = 'K';
+ public function generate(Individual $individual, Individual $head): string
+ {
+ return match ($individual->sex()) {
+ 'M' => 'M',
+ 'F' => 'K',
+ default => '',
+ };
+ }
}
diff --git a/app/Census/CensusColumnSexMZ.php b/app/Census/CensusColumnSexMZ.php
index 847777ba13..4a65b704bf 100644
--- a/app/Census/CensusColumnSexMZ.php
+++ b/app/Census/CensusColumnSexMZ.php
@@ -19,10 +19,17 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * The individual's sex.
- */
-class CensusColumnSexMZ extends CensusColumnSexMF
+use Fisharebest\Webtrees\Encodings\UTF8;
+use Fisharebest\Webtrees\Individual;
+
+final readonly class CensusColumnSexMZ extends AbstractCensusColumn implements CensusColumnInterface
{
- protected const string FEMALE = 'Ž';
+ public function generate(Individual $individual, Individual $head): string
+ {
+ return match ($individual->sex()) {
+ 'M' => 'M',
+ 'F' => UTF8::LATIN_CAPITAL_LETTER_Z_WITH_CARON,
+ default => '',
+ };
+ }
}
diff --git a/app/Census/CensusColumnSurname.php b/app/Census/CensusColumnSurname.php
index e456e5ecd7..376e6eaffc 100644
--- a/app/Census/CensusColumnSurname.php
+++ b/app/Census/CensusColumnSurname.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's full name.
- */
-class CensusColumnSurname extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnSurname extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
foreach ($individual->getAllNames() as $name) {
diff --git a/app/Census/CensusColumnSurnameGivenNameInitial.php b/app/Census/CensusColumnSurnameGivenNameInitial.php
index f26d1db3d7..8b2cd4e458 100644
--- a/app/Census/CensusColumnSurnameGivenNameInitial.php
+++ b/app/Census/CensusColumnSurnameGivenNameInitial.php
@@ -21,19 +21,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's full name.
- */
-class CensusColumnSurnameGivenNameInitial extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnSurnameGivenNameInitial extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$name = $this->nameAtCensusDate($individual);
diff --git a/app/Census/CensusColumnSurnameGivenNames.php b/app/Census/CensusColumnSurnameGivenNames.php
index b627b188f7..c38819da6c 100644
--- a/app/Census/CensusColumnSurnameGivenNames.php
+++ b/app/Census/CensusColumnSurnameGivenNames.php
@@ -22,19 +22,8 @@ namespace Fisharebest\Webtrees\Census;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * The individual's full name.
- */
-class CensusColumnSurnameGivenNames extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnSurnameGivenNames extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$name = $this->nameAtCensusDate($individual);
diff --git a/app/Census/CensusColumnYearsMarried.php b/app/Census/CensusColumnYearsMarried.php
index c358f095dd..e65073019c 100644
--- a/app/Census/CensusColumnYearsMarried.php
+++ b/app/Census/CensusColumnYearsMarried.php
@@ -24,19 +24,8 @@ use Fisharebest\Webtrees\Date;
use Fisharebest\Webtrees\I18N;
use Fisharebest\Webtrees\Individual;
-/**
- * For how many years has the individual been married.
- */
-class CensusColumnYearsMarried extends AbstractCensusColumn implements CensusColumnInterface
+final readonly class CensusColumnYearsMarried extends AbstractCensusColumn implements CensusColumnInterface
{
- /**
- * Generate the likely value of this census column, based on available information.
- *
- * @param Individual $individual
- * @param Individual $head
- *
- * @return string
- */
public function generate(Individual $individual, Individual $head): string
{
$marriage_date = null;
diff --git a/app/Census/CensusInterface.php b/app/Census/CensusInterface.php
index dc59401ead..6359a67ceb 100644
--- a/app/Census/CensusInterface.php
+++ b/app/Census/CensusInterface.php
@@ -19,22 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
interface CensusInterface extends CensusPlaceInterface
{
- /**
- * When did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusDate(): string;
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array;
}
diff --git a/app/Census/CensusOfCanada.php b/app/Census/CensusOfCanada.php
index fddcab801b..fbf9195f0c 100644
--- a/app/Census/CensusOfCanada.php
+++ b/app/Census/CensusOfCanada.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada extends Census implements CensusPlaceInterface
+readonly class CensusOfCanada implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -46,21 +43,11 @@ class CensusOfCanada extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Canada';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'en-US';
diff --git a/app/Census/CensusOfCanada1851.php b/app/Census/CensusOfCanada1851.php
index 508849559c..3879eb62c5 100644
--- a/app/Census/CensusOfCanada1851.php
+++ b/app/Census/CensusOfCanada1851.php
@@ -19,10 +19,7 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1851 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1851 extends CensusOfCanada implements CensusInterface
{
/**
* When did this census occur.
@@ -38,9 +35,7 @@ class CensusOfCanada1851 extends CensusOfCanada implements CensusInterface
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1861.php b/app/Census/CensusOfCanada1861.php
index c23296d164..976da3faf7 100644
--- a/app/Census/CensusOfCanada1861.php
+++ b/app/Census/CensusOfCanada1861.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1861 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1861 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '14 JAN 1861';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1871.php b/app/Census/CensusOfCanada1871.php
index 6e59aacc0f..ab1aee71d7 100644
--- a/app/Census/CensusOfCanada1871.php
+++ b/app/Census/CensusOfCanada1871.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1871 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1871 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1871';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1881.php b/app/Census/CensusOfCanada1881.php
index 9ec5d3a8ad..4c0ba37ec6 100644
--- a/app/Census/CensusOfCanada1881.php
+++ b/app/Census/CensusOfCanada1881.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1881 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1881 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '04 APR 1881';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1891.php b/app/Census/CensusOfCanada1891.php
index ecd0cec060..3500689f27 100644
--- a/app/Census/CensusOfCanada1891.php
+++ b/app/Census/CensusOfCanada1891.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1891 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1891 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '06 APR 1891';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1901.php b/app/Census/CensusOfCanada1901.php
index c8024344e1..1ce0fc1eb4 100644
--- a/app/Census/CensusOfCanada1901.php
+++ b/app/Census/CensusOfCanada1901.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1901 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1901 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 MAR 1901';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1911.php b/app/Census/CensusOfCanada1911.php
index de22a6ad06..62a18d5413 100644
--- a/app/Census/CensusOfCanada1911.php
+++ b/app/Census/CensusOfCanada1911.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1911 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1911 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1911';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1921.php b/app/Census/CensusOfCanada1921.php
index 292ad6d80f..4ff483fe8c 100644
--- a/app/Census/CensusOfCanada1921.php
+++ b/app/Census/CensusOfCanada1921.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1921 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1921 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1921';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanada1931.php b/app/Census/CensusOfCanada1931.php
index 92a140c838..2464130c04 100644
--- a/app/Census/CensusOfCanada1931.php
+++ b/app/Census/CensusOfCanada1931.php
@@ -19,10 +19,7 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanada1931 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanada1931 extends CensusOfCanada implements CensusInterface
{
/**
* When did this census occur.
@@ -35,9 +32,7 @@ class CensusOfCanada1931 extends CensusOfCanada implements CensusInterface
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanadaPraries1916.php b/app/Census/CensusOfCanadaPraries1916.php
index d8ec2ef1eb..38c78e685f 100644
--- a/app/Census/CensusOfCanadaPraries1916.php
+++ b/app/Census/CensusOfCanadaPraries1916.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanadaPraries1916 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanadaPraries1916 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1916';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCanadaPraries1926.php b/app/Census/CensusOfCanadaPraries1926.php
index 907619e527..e4381cebab 100644
--- a/app/Census/CensusOfCanadaPraries1926.php
+++ b/app/Census/CensusOfCanadaPraries1926.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCanadaPraries1926 extends CensusOfCanada implements CensusInterface
+readonly class CensusOfCanadaPraries1926 extends CensusOfCanada implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1926';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCzechRepublic.php b/app/Census/CensusOfCzechRepublic.php
index a5c48b2658..a6df405fe4 100644
--- a/app/Census/CensusOfCzechRepublic.php
+++ b/app/Census/CensusOfCzechRepublic.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCzechRepublic extends Census implements CensusPlaceInterface
+readonly class CensusOfCzechRepublic implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -40,21 +37,11 @@ class CensusOfCzechRepublic extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'ÄŒesko';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'cs';
diff --git a/app/Census/CensusOfCzechRepublic1880.php b/app/Census/CensusOfCzechRepublic1880.php
index cce2d2eafc..c49802850d 100644
--- a/app/Census/CensusOfCzechRepublic1880.php
+++ b/app/Census/CensusOfCzechRepublic1880.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCzechRepublic1880 extends CensusOfCzechRepublic implements CensusInterface
+readonly class CensusOfCzechRepublic1880 extends CensusOfCzechRepublic implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 DEC 1880';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCzechRepublic1890.php b/app/Census/CensusOfCzechRepublic1890.php
index 9af3593bfa..672a4a123d 100644
--- a/app/Census/CensusOfCzechRepublic1890.php
+++ b/app/Census/CensusOfCzechRepublic1890.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCzechRepublic1890 extends CensusOfCzechRepublic implements CensusInterface
+readonly class CensusOfCzechRepublic1890 extends CensusOfCzechRepublic implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 DEC 1890';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCzechRepublic1900.php b/app/Census/CensusOfCzechRepublic1900.php
index e27b5774d4..863cba116e 100644
--- a/app/Census/CensusOfCzechRepublic1900.php
+++ b/app/Census/CensusOfCzechRepublic1900.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCzechRepublic1900 extends CensusOfCzechRepublic implements CensusInterface
+readonly class CensusOfCzechRepublic1900 extends CensusOfCzechRepublic implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 DEC 1900';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCzechRepublic1910.php b/app/Census/CensusOfCzechRepublic1910.php
index d8493d3f8a..eacb6ad86a 100644
--- a/app/Census/CensusOfCzechRepublic1910.php
+++ b/app/Census/CensusOfCzechRepublic1910.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCzechRepublic1910 extends CensusOfCzechRepublic implements CensusInterface
+readonly class CensusOfCzechRepublic1910 extends CensusOfCzechRepublic implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 DEC 1910';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfCzechRepublic1921.php b/app/Census/CensusOfCzechRepublic1921.php
index 9f0270d377..bfd8fa0be5 100644
--- a/app/Census/CensusOfCzechRepublic1921.php
+++ b/app/Census/CensusOfCzechRepublic1921.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfCzechRepublic1921 extends CensusOfCzechRepublic implements CensusInterface
+readonly class CensusOfCzechRepublic1921 extends CensusOfCzechRepublic implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '15 FEB 1921';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark.php b/app/Census/CensusOfDenmark.php
index c29a3381a2..a8e02c523c 100644
--- a/app/Census/CensusOfDenmark.php
+++ b/app/Census/CensusOfDenmark.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark extends Census implements CensusPlaceInterface
+readonly class CensusOfDenmark implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -57,21 +54,11 @@ class CensusOfDenmark extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Danmark';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'da';
diff --git a/app/Census/CensusOfDenmark1787.php b/app/Census/CensusOfDenmark1787.php
index b3f1e76093..68030f6f26 100644
--- a/app/Census/CensusOfDenmark1787.php
+++ b/app/Census/CensusOfDenmark1787.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1787 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1787 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUL 1787';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1801.php b/app/Census/CensusOfDenmark1801.php
index f9a657692f..ed73970bd1 100644
--- a/app/Census/CensusOfDenmark1801.php
+++ b/app/Census/CensusOfDenmark1801.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1801 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1801 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1801';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1803.php b/app/Census/CensusOfDenmark1803.php
index 73aa96ae91..2b0ad911f8 100644
--- a/app/Census/CensusOfDenmark1803.php
+++ b/app/Census/CensusOfDenmark1803.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1803 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1803 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1803';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Schleswig-Holstein, Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1834.php b/app/Census/CensusOfDenmark1834.php
index 7292c07a63..db95dc2b71 100644
--- a/app/Census/CensusOfDenmark1834.php
+++ b/app/Census/CensusOfDenmark1834.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1834 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1834 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '18 FEB 1834';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1835.php b/app/Census/CensusOfDenmark1835.php
index 460f980aa3..9317ab5ab6 100644
--- a/app/Census/CensusOfDenmark1835.php
+++ b/app/Census/CensusOfDenmark1835.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1835 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1835 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '18 FEB 1835';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Schleswig-Holstein, Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1840.php b/app/Census/CensusOfDenmark1840.php
index e5cacfda23..bfa2129dd3 100644
--- a/app/Census/CensusOfDenmark1840.php
+++ b/app/Census/CensusOfDenmark1840.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1840 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1840 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1840';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1845.php b/app/Census/CensusOfDenmark1845.php
index f063bdc78a..052dcb031a 100644
--- a/app/Census/CensusOfDenmark1845.php
+++ b/app/Census/CensusOfDenmark1845.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1845 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1845 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1845';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1850.php b/app/Census/CensusOfDenmark1850.php
index 22b4d6f882..134d63eff8 100644
--- a/app/Census/CensusOfDenmark1850.php
+++ b/app/Census/CensusOfDenmark1850.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1850 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1850 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1850';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1855.php b/app/Census/CensusOfDenmark1855.php
index 385cc16301..62ccb1995d 100644
--- a/app/Census/CensusOfDenmark1855.php
+++ b/app/Census/CensusOfDenmark1855.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1855 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1855 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1855';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1860.php b/app/Census/CensusOfDenmark1860.php
index 1c3ddd79b3..21f4ea00ef 100644
--- a/app/Census/CensusOfDenmark1860.php
+++ b/app/Census/CensusOfDenmark1860.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1860 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1860 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1860';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1870.php b/app/Census/CensusOfDenmark1870.php
index 37831c9915..8b18ab3e13 100644
--- a/app/Census/CensusOfDenmark1870.php
+++ b/app/Census/CensusOfDenmark1870.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1870 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1870 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1870';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1880.php b/app/Census/CensusOfDenmark1880.php
index 37ce2baffc..1fd6de2a7d 100644
--- a/app/Census/CensusOfDenmark1880.php
+++ b/app/Census/CensusOfDenmark1880.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1880 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1880 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1880';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1885.php b/app/Census/CensusOfDenmark1885.php
index c6e3798be3..84821f132e 100644
--- a/app/Census/CensusOfDenmark1885.php
+++ b/app/Census/CensusOfDenmark1885.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1885 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1885 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1885';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'København, Danmark';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1890.php b/app/Census/CensusOfDenmark1890.php
index 780aecfdd6..74725f545e 100644
--- a/app/Census/CensusOfDenmark1890.php
+++ b/app/Census/CensusOfDenmark1890.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1890 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1890 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1890';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1901.php b/app/Census/CensusOfDenmark1901.php
index 3bd15c742d..44f9121450 100644
--- a/app/Census/CensusOfDenmark1901.php
+++ b/app/Census/CensusOfDenmark1901.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1901 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1901 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1901';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1906.php b/app/Census/CensusOfDenmark1906.php
index b1b8cbee1e..0554c21633 100644
--- a/app/Census/CensusOfDenmark1906.php
+++ b/app/Census/CensusOfDenmark1906.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1906 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1906 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1906';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1911.php b/app/Census/CensusOfDenmark1911.php
index c9c765e7ac..9328f56035 100644
--- a/app/Census/CensusOfDenmark1911.php
+++ b/app/Census/CensusOfDenmark1911.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1911 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1911 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1911';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1916.php b/app/Census/CensusOfDenmark1916.php
index 21e85a4afa..1e753cd315 100644
--- a/app/Census/CensusOfDenmark1916.php
+++ b/app/Census/CensusOfDenmark1916.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1916 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1916 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1916';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1921.php b/app/Census/CensusOfDenmark1921.php
index e287ccb0d7..273a0bcab5 100644
--- a/app/Census/CensusOfDenmark1921.php
+++ b/app/Census/CensusOfDenmark1921.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1921 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1921 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 FEB 1921';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1925.php b/app/Census/CensusOfDenmark1925.php
index 3e06d979e3..5c2b7bd4bf 100644
--- a/app/Census/CensusOfDenmark1925.php
+++ b/app/Census/CensusOfDenmark1925.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1925 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1925 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '05 NOV 1925';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1930.php b/app/Census/CensusOfDenmark1930.php
index 4b8270180c..7158cc1e5f 100644
--- a/app/Census/CensusOfDenmark1930.php
+++ b/app/Census/CensusOfDenmark1930.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1930 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1930 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '05 NOV 1930';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDenmark1940.php b/app/Census/CensusOfDenmark1940.php
index 9b47fb0aa5..7176eb35a7 100644
--- a/app/Census/CensusOfDenmark1940.php
+++ b/app/Census/CensusOfDenmark1940.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDenmark1940 extends CensusOfDenmark implements CensusInterface
+readonly class CensusOfDenmark1940 extends CensusOfDenmark implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '05 NOV 1940';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDeutschland.php b/app/Census/CensusOfDeutschland.php
index 30884f2df7..ebef5bc26a 100644
--- a/app/Census/CensusOfDeutschland.php
+++ b/app/Census/CensusOfDeutschland.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDeutschland extends Census implements CensusPlaceInterface
+readonly class CensusOfDeutschland implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -40,21 +37,11 @@ class CensusOfDeutschland extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Deutschland';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'de';
diff --git a/app/Census/CensusOfDeutschland1819.php b/app/Census/CensusOfDeutschland1819.php
index 3818114daa..08e3c61b30 100644
--- a/app/Census/CensusOfDeutschland1819.php
+++ b/app/Census/CensusOfDeutschland1819.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDeutschland1819 extends CensusOfDeutschland implements CensusInterface
+readonly class CensusOfDeutschland1819 extends CensusOfDeutschland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'AUG 1819';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Mecklenburg-Schwerin, Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDeutschland1867.php b/app/Census/CensusOfDeutschland1867.php
index 9943956b31..53279fd362 100644
--- a/app/Census/CensusOfDeutschland1867.php
+++ b/app/Census/CensusOfDeutschland1867.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDeutschland1867 extends CensusOfDeutschland implements CensusInterface
+readonly class CensusOfDeutschland1867 extends CensusOfDeutschland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '03 DEC 1867';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Mecklenburg-Schwerin, Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDeutschland1900.php b/app/Census/CensusOfDeutschland1900.php
index 3a1c26c3a5..3e894510c5 100644
--- a/app/Census/CensusOfDeutschland1900.php
+++ b/app/Census/CensusOfDeutschland1900.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDeutschland1900 extends CensusOfDeutschland implements CensusInterface
+readonly class CensusOfDeutschland1900 extends CensusOfDeutschland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 DEC 1900';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Mecklenburg-Schwerin, Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDeutschland1919.php b/app/Census/CensusOfDeutschland1919.php
index 2bfc911bb1..6e13dd4929 100644
--- a/app/Census/CensusOfDeutschland1919.php
+++ b/app/Census/CensusOfDeutschland1919.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDeutschland1919 extends CensusOfDeutschland implements CensusInterface
+readonly class CensusOfDeutschland1919 extends CensusOfDeutschland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '08 OCT 1919';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Mecklenburg-Schwerin, Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfDeutschlandNL1867.php b/app/Census/CensusOfDeutschlandNL1867.php
index 1f1ae848a1..4940c217ec 100644
--- a/app/Census/CensusOfDeutschlandNL1867.php
+++ b/app/Census/CensusOfDeutschlandNL1867.php
@@ -19,35 +19,20 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfDeutschlandNL1867 extends CensusOfDeutschland implements CensusInterface
+readonly class CensusOfDeutschlandNL1867 extends CensusOfDeutschland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '03 DEC 1867';
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Mecklenburg-Schwerin (Nachtragsliste), Deutschland';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland.php b/app/Census/CensusOfEngland.php
index 07496caa80..c17d965be8 100644
--- a/app/Census/CensusOfEngland.php
+++ b/app/Census/CensusOfEngland.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland extends Census implements CensusPlaceInterface
+readonly class CensusOfEngland implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -44,21 +41,11 @@ class CensusOfEngland extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'England';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'en-GB';
diff --git a/app/Census/CensusOfEngland1841.php b/app/Census/CensusOfEngland1841.php
index 1d28099ff1..fd58ecfe53 100644
--- a/app/Census/CensusOfEngland1841.php
+++ b/app/Census/CensusOfEngland1841.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1841 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1841 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '06 JUN 1841';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1851.php b/app/Census/CensusOfEngland1851.php
index ad6b9a8ced..9b7b1e70d3 100644
--- a/app/Census/CensusOfEngland1851.php
+++ b/app/Census/CensusOfEngland1851.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1851 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1851 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '30 MAR 1851';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1861.php b/app/Census/CensusOfEngland1861.php
index e906a759e9..83e475ccc6 100644
--- a/app/Census/CensusOfEngland1861.php
+++ b/app/Census/CensusOfEngland1861.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1861 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1861 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '07 APR 1861';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1871.php b/app/Census/CensusOfEngland1871.php
index 80ce082e69..00f27f5edf 100644
--- a/app/Census/CensusOfEngland1871.php
+++ b/app/Census/CensusOfEngland1871.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1871 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1871 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1871';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1881.php b/app/Census/CensusOfEngland1881.php
index b87181f780..3b694bf678 100644
--- a/app/Census/CensusOfEngland1881.php
+++ b/app/Census/CensusOfEngland1881.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1881 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1881 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '03 APR 1881';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1891.php b/app/Census/CensusOfEngland1891.php
index 69be9fa574..d48bcb5796 100644
--- a/app/Census/CensusOfEngland1891.php
+++ b/app/Census/CensusOfEngland1891.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1891 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1891 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '05 APR 1891';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1901.php b/app/Census/CensusOfEngland1901.php
index 6badc686b6..6c342aaf1f 100644
--- a/app/Census/CensusOfEngland1901.php
+++ b/app/Census/CensusOfEngland1901.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1901 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1901 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 MAR 1901';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfEngland1911.php b/app/Census/CensusOfEngland1911.php
index 36e09303a0..c02c1544ef 100644
--- a/app/Census/CensusOfEngland1911.php
+++ b/app/Census/CensusOfEngland1911.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfEngland1911 extends CensusOfEngland implements CensusInterface
+readonly class CensusOfEngland1911 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1911';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance.php b/app/Census/CensusOfFrance.php
index 4cc0c3f84c..afb0bca7a4 100644
--- a/app/Census/CensusOfFrance.php
+++ b/app/Census/CensusOfFrance.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance extends Census implements CensusPlaceInterface
+readonly class CensusOfFrance implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -57,21 +54,11 @@ class CensusOfFrance extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'France';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'fr';
diff --git a/app/Census/CensusOfFrance1831.php b/app/Census/CensusOfFrance1831.php
index 0ea74d9823..967b9ccaa3 100644
--- a/app/Census/CensusOfFrance1831.php
+++ b/app/Census/CensusOfFrance1831.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1831 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1831 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '20 JAN 1831';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1836.php b/app/Census/CensusOfFrance1836.php
index 6ac3cf343f..7f2ddf2522 100644
--- a/app/Census/CensusOfFrance1836.php
+++ b/app/Census/CensusOfFrance1836.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1836 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1836 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '21 JAN 1836';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1841.php b/app/Census/CensusOfFrance1841.php
index de4040819f..6a15935672 100644
--- a/app/Census/CensusOfFrance1841.php
+++ b/app/Census/CensusOfFrance1841.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1841 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1841 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '21 JAN 1841';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1846.php b/app/Census/CensusOfFrance1846.php
index ec88dee799..a1f45c861a 100644
--- a/app/Census/CensusOfFrance1846.php
+++ b/app/Census/CensusOfFrance1846.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1846 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1846 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '15 JAN 1846';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1851.php b/app/Census/CensusOfFrance1851.php
index 9a322d9c1b..5ced1832fa 100644
--- a/app/Census/CensusOfFrance1851.php
+++ b/app/Census/CensusOfFrance1851.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1851 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1851 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '16 JAN 1851';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1856.php b/app/Census/CensusOfFrance1856.php
index 6ea57bfb6c..cb4c2efa29 100644
--- a/app/Census/CensusOfFrance1856.php
+++ b/app/Census/CensusOfFrance1856.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1856 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1856 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '17 JAN 1856';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1861.php b/app/Census/CensusOfFrance1861.php
index 453a86594d..0150bb1a4e 100644
--- a/app/Census/CensusOfFrance1861.php
+++ b/app/Census/CensusOfFrance1861.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1861 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1861 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '17 JAN 1861';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1866.php b/app/Census/CensusOfFrance1866.php
index 6cf88fa2a5..ebc6c2a3bc 100644
--- a/app/Census/CensusOfFrance1866.php
+++ b/app/Census/CensusOfFrance1866.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1866 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1866 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '18 JAN 1866';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1872.php b/app/Census/CensusOfFrance1872.php
index 299d16c949..1e8c1371ac 100644
--- a/app/Census/CensusOfFrance1872.php
+++ b/app/Census/CensusOfFrance1872.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1872 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1872 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '18 JAN 1872';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1876.php b/app/Census/CensusOfFrance1876.php
index 741588ebbe..629922af79 100644
--- a/app/Census/CensusOfFrance1876.php
+++ b/app/Census/CensusOfFrance1876.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1876 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1876 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '20 JAN 1876';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1881.php b/app/Census/CensusOfFrance1881.php
index 20c78b64e6..a68222b2b3 100644
--- a/app/Census/CensusOfFrance1881.php
+++ b/app/Census/CensusOfFrance1881.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1881 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1881 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '20 JAN 1881';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1886.php b/app/Census/CensusOfFrance1886.php
index 1ab4139078..6c212ad324 100644
--- a/app/Census/CensusOfFrance1886.php
+++ b/app/Census/CensusOfFrance1886.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1886 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1886 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '21 JAN 1886';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1891.php b/app/Census/CensusOfFrance1891.php
index c0da654c40..29f0ff12c4 100644
--- a/app/Census/CensusOfFrance1891.php
+++ b/app/Census/CensusOfFrance1891.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1891 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1891 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '15 JAN 1891';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1896.php b/app/Census/CensusOfFrance1896.php
index 5cd0125391..aca8d5b7c8 100644
--- a/app/Census/CensusOfFrance1896.php
+++ b/app/Census/CensusOfFrance1896.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1896 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1896 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '16 JAN 1896';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1901.php b/app/Census/CensusOfFrance1901.php
index b1b93257f0..63fcf3e7bc 100644
--- a/app/Census/CensusOfFrance1901.php
+++ b/app/Census/CensusOfFrance1901.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1901 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1901 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '17 JAN 1901';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1906.php b/app/Census/CensusOfFrance1906.php
index f256864977..106978cb79 100644
--- a/app/Census/CensusOfFrance1906.php
+++ b/app/Census/CensusOfFrance1906.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1906 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1906 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '18 JAN 1906';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1911.php b/app/Census/CensusOfFrance1911.php
index 383e2c1f22..2e16a08cb7 100644
--- a/app/Census/CensusOfFrance1911.php
+++ b/app/Census/CensusOfFrance1911.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1911 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1911 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '19 JAN 1911';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1921.php b/app/Census/CensusOfFrance1921.php
index 519edecb73..809d433673 100644
--- a/app/Census/CensusOfFrance1921.php
+++ b/app/Census/CensusOfFrance1921.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1921 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1921 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '20 JAN 1921';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1926.php b/app/Census/CensusOfFrance1926.php
index 3bb93e5cc2..15611940d2 100644
--- a/app/Census/CensusOfFrance1926.php
+++ b/app/Census/CensusOfFrance1926.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1926 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1926 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '21 JAN 1926';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1931.php b/app/Census/CensusOfFrance1931.php
index 31fbdcfbdd..f5ad1553a4 100644
--- a/app/Census/CensusOfFrance1931.php
+++ b/app/Census/CensusOfFrance1931.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1931 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1931 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '15 JAN 1931';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1936.php b/app/Census/CensusOfFrance1936.php
index b8b0953c4a..2fc33cb50b 100644
--- a/app/Census/CensusOfFrance1936.php
+++ b/app/Census/CensusOfFrance1936.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1936 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1936 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '16 JAN 1936';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfFrance1946.php b/app/Census/CensusOfFrance1946.php
index ecc518b5fe..0b609d1d9c 100644
--- a/app/Census/CensusOfFrance1946.php
+++ b/app/Census/CensusOfFrance1946.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfFrance1946 extends CensusOfFrance implements CensusInterface
+readonly class CensusOfFrance1946 extends CensusOfFrance implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '17 JAN 1946';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfRhodeIsland.php b/app/Census/CensusOfRhodeIsland.php
index 1acce53fc7..7a9e8f3f1f 100644
--- a/app/Census/CensusOfRhodeIsland.php
+++ b/app/Census/CensusOfRhodeIsland.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfRhodeIsland extends Census implements CensusPlaceInterface
+readonly class CensusOfRhodeIsland implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -38,21 +35,11 @@ class CensusOfRhodeIsland extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Rhode Island, United States';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'en-US';
diff --git a/app/Census/CensusOfRhodeIsland1905.php b/app/Census/CensusOfRhodeIsland1905.php
index 91bd3888e4..8e57ea967f 100644
--- a/app/Census/CensusOfRhodeIsland1905.php
+++ b/app/Census/CensusOfRhodeIsland1905.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfRhodeIsland1905 extends CensusOfRhodeIsland implements CensusInterface
+readonly class CensusOfRhodeIsland1905 extends CensusOfRhodeIsland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'JUN 1905';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfRhodeIsland1915.php b/app/Census/CensusOfRhodeIsland1915.php
index 7e2eac14d1..71a745cf99 100644
--- a/app/Census/CensusOfRhodeIsland1915.php
+++ b/app/Census/CensusOfRhodeIsland1915.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfRhodeIsland1915 extends CensusOfRhodeIsland implements CensusInterface
+readonly class CensusOfRhodeIsland1915 extends CensusOfRhodeIsland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'APR 1915';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfRhodeIsland1925.php b/app/Census/CensusOfRhodeIsland1925.php
index 7e74174ac0..df9c99819d 100644
--- a/app/Census/CensusOfRhodeIsland1925.php
+++ b/app/Census/CensusOfRhodeIsland1925.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfRhodeIsland1925 extends CensusOfRhodeIsland implements CensusInterface
+readonly class CensusOfRhodeIsland1925 extends CensusOfRhodeIsland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'APR 1925';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland.php b/app/Census/CensusOfScotland.php
index ac75535023..391a0cb2e3 100644
--- a/app/Census/CensusOfScotland.php
+++ b/app/Census/CensusOfScotland.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland extends Census implements CensusPlaceInterface
+readonly class CensusOfScotland implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -44,21 +41,11 @@ class CensusOfScotland extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Scotland';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'en-GB';
diff --git a/app/Census/CensusOfScotland1841.php b/app/Census/CensusOfScotland1841.php
index e071605324..ce551b5f0e 100644
--- a/app/Census/CensusOfScotland1841.php
+++ b/app/Census/CensusOfScotland1841.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1841 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1841 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '06 JUN 1841';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1851.php b/app/Census/CensusOfScotland1851.php
index 7e042d4d7b..2fdf4e1dfb 100644
--- a/app/Census/CensusOfScotland1851.php
+++ b/app/Census/CensusOfScotland1851.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1851 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1851 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '30 MAR 1851';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1861.php b/app/Census/CensusOfScotland1861.php
index ca80576938..d502fc51f7 100644
--- a/app/Census/CensusOfScotland1861.php
+++ b/app/Census/CensusOfScotland1861.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1861 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1861 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '07 APR 1861';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1871.php b/app/Census/CensusOfScotland1871.php
index 0caa88ee1a..126cb5cf41 100644
--- a/app/Census/CensusOfScotland1871.php
+++ b/app/Census/CensusOfScotland1871.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1871 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1871 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1871';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1881.php b/app/Census/CensusOfScotland1881.php
index b90604de27..fdb3b7ab7d 100644
--- a/app/Census/CensusOfScotland1881.php
+++ b/app/Census/CensusOfScotland1881.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1881 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1881 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '03 APR 1881';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1891.php b/app/Census/CensusOfScotland1891.php
index 6817b73852..88a8bba1d5 100644
--- a/app/Census/CensusOfScotland1891.php
+++ b/app/Census/CensusOfScotland1891.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1891 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1891 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '05 APR 1891';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1901.php b/app/Census/CensusOfScotland1901.php
index 1cb5144a9e..b518e16e5d 100644
--- a/app/Census/CensusOfScotland1901.php
+++ b/app/Census/CensusOfScotland1901.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1901 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1901 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 MAR 1901';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfScotland1911.php b/app/Census/CensusOfScotland1911.php
index 9983714ae5..23ac755584 100644
--- a/app/Census/CensusOfScotland1911.php
+++ b/app/Census/CensusOfScotland1911.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfScotland1911 extends CensusOfScotland implements CensusInterface
+readonly class CensusOfScotland1911 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1911';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfSlovakia.php b/app/Census/CensusOfSlovakia.php
index 5409350232..c1156935f3 100644
--- a/app/Census/CensusOfSlovakia.php
+++ b/app/Census/CensusOfSlovakia.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfSlovakia extends Census implements CensusPlaceInterface
+readonly class CensusOfSlovakia implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -38,21 +35,11 @@ class CensusOfSlovakia extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Slovensko';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'sk';
diff --git a/app/Census/CensusOfSlovakia1869.php b/app/Census/CensusOfSlovakia1869.php
index f487cb0b2d..fba6f5e2c7 100644
--- a/app/Census/CensusOfSlovakia1869.php
+++ b/app/Census/CensusOfSlovakia1869.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfSlovakia1869 extends CensusOfSlovakia implements CensusInterface
+readonly class CensusOfSlovakia1869 extends CensusOfSlovakia implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 DEC 1869';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfSlovakia1930.php b/app/Census/CensusOfSlovakia1930.php
index 6e604d4498..813f94733f 100644
--- a/app/Census/CensusOfSlovakia1930.php
+++ b/app/Census/CensusOfSlovakia1930.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfSlovakia1930 extends CensusOfSlovakia implements CensusInterface
+readonly class CensusOfSlovakia1930 extends CensusOfSlovakia implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 DEC 1930';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfSlovakia1940.php b/app/Census/CensusOfSlovakia1940.php
index 345f6ef4d8..2a8d6d1505 100644
--- a/app/Census/CensusOfSlovakia1940.php
+++ b/app/Census/CensusOfSlovakia1940.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfSlovakia1940 extends CensusOfSlovakia implements CensusInterface
+readonly class CensusOfSlovakia1940 extends CensusOfSlovakia implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '14 DEC 1940';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates.php b/app/Census/CensusOfUnitedStates.php
index 0da0092802..0df9d455f9 100644
--- a/app/Census/CensusOfUnitedStates.php
+++ b/app/Census/CensusOfUnitedStates.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates extends Census implements CensusPlaceInterface
+readonly class CensusOfUnitedStates implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -52,21 +49,11 @@ class CensusOfUnitedStates extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'United States';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'en-US';
diff --git a/app/Census/CensusOfUnitedStates1790.php b/app/Census/CensusOfUnitedStates1790.php
index a4e8981801..e52ad3f614 100644
--- a/app/Census/CensusOfUnitedStates1790.php
+++ b/app/Census/CensusOfUnitedStates1790.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1790 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1790 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 AUG 1790';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1800.php b/app/Census/CensusOfUnitedStates1800.php
index adce10f376..cce04d3c36 100644
--- a/app/Census/CensusOfUnitedStates1800.php
+++ b/app/Census/CensusOfUnitedStates1800.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1800 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1800 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '04 AUG 1800';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1810.php b/app/Census/CensusOfUnitedStates1810.php
index 640298c3bf..f91c860f79 100644
--- a/app/Census/CensusOfUnitedStates1810.php
+++ b/app/Census/CensusOfUnitedStates1810.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1810 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1810 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '06 AUG 1810';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1820.php b/app/Census/CensusOfUnitedStates1820.php
index 1d64761c86..4c40cc5c04 100644
--- a/app/Census/CensusOfUnitedStates1820.php
+++ b/app/Census/CensusOfUnitedStates1820.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1820 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1820 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '07 AUG 1820';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
diff --git a/app/Census/CensusOfUnitedStates1830.php b/app/Census/CensusOfUnitedStates1830.php
index 78c63aba84..fa12769c1e 100644
--- a/app/Census/CensusOfUnitedStates1830.php
+++ b/app/Census/CensusOfUnitedStates1830.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1830 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1830 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1830';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1840.php b/app/Census/CensusOfUnitedStates1840.php
index 642efa7fdf..33c43955a0 100644
--- a/app/Census/CensusOfUnitedStates1840.php
+++ b/app/Census/CensusOfUnitedStates1840.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1840 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1840 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1840';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1850.php b/app/Census/CensusOfUnitedStates1850.php
index 41f3f79cf8..8bd13f20b3 100644
--- a/app/Census/CensusOfUnitedStates1850.php
+++ b/app/Census/CensusOfUnitedStates1850.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1850 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1850 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1850';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1860.php b/app/Census/CensusOfUnitedStates1860.php
index 1fa0d0d8fb..165a371964 100644
--- a/app/Census/CensusOfUnitedStates1860.php
+++ b/app/Census/CensusOfUnitedStates1860.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1860 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1860 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'BET JUN 1860 AND OCT 1860';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1870.php b/app/Census/CensusOfUnitedStates1870.php
index 2058e1251f..2d5d71d0d8 100644
--- a/app/Census/CensusOfUnitedStates1870.php
+++ b/app/Census/CensusOfUnitedStates1870.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1870 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1870 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'JUN 1870';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1880.php b/app/Census/CensusOfUnitedStates1880.php
index bcadd222be..ad517e957d 100644
--- a/app/Census/CensusOfUnitedStates1880.php
+++ b/app/Census/CensusOfUnitedStates1880.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1880 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1880 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'JUN 1880';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1890.php b/app/Census/CensusOfUnitedStates1890.php
index 3c56bb4a04..2e42c651b7 100644
--- a/app/Census/CensusOfUnitedStates1890.php
+++ b/app/Census/CensusOfUnitedStates1890.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1890 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1890 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 JUN 1890';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1900.php b/app/Census/CensusOfUnitedStates1900.php
index e1a1bd7ce5..df13d62790 100644
--- a/app/Census/CensusOfUnitedStates1900.php
+++ b/app/Census/CensusOfUnitedStates1900.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1900 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1900 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '01 JUN 1900';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1910.php b/app/Census/CensusOfUnitedStates1910.php
index 3f8fc255a7..51e1672526 100644
--- a/app/Census/CensusOfUnitedStates1910.php
+++ b/app/Census/CensusOfUnitedStates1910.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1910 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1910 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '15 APR 1910';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1920.php b/app/Census/CensusOfUnitedStates1920.php
index b9310292a6..001751a1bf 100644
--- a/app/Census/CensusOfUnitedStates1920.php
+++ b/app/Census/CensusOfUnitedStates1920.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1920 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1920 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'JAN 1920';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1930.php b/app/Census/CensusOfUnitedStates1930.php
index 6cf052d359..e38d1ced1e 100644
--- a/app/Census/CensusOfUnitedStates1930.php
+++ b/app/Census/CensusOfUnitedStates1930.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1930 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1930 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'APR 1930';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1940.php b/app/Census/CensusOfUnitedStates1940.php
index 328841039f..6dc4ae8063 100644
--- a/app/Census/CensusOfUnitedStates1940.php
+++ b/app/Census/CensusOfUnitedStates1940.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1940 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1940 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'APR 1940';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfUnitedStates1950.php b/app/Census/CensusOfUnitedStates1950.php
index dab5a3dbb9..addb7b1c3c 100644
--- a/app/Census/CensusOfUnitedStates1950.php
+++ b/app/Census/CensusOfUnitedStates1950.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfUnitedStates1950 extends CensusOfUnitedStates implements CensusInterface
+readonly class CensusOfUnitedStates1950 extends CensusOfUnitedStates implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return 'APR 1950';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales.php b/app/Census/CensusOfWales.php
index 45ba69d5f0..82444ef037 100644
--- a/app/Census/CensusOfWales.php
+++ b/app/Census/CensusOfWales.php
@@ -19,15 +19,12 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales extends Census implements CensusPlaceInterface
+readonly class CensusOfWales implements CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array
{
@@ -44,21 +41,11 @@ class CensusOfWales extends Census implements CensusPlaceInterface
];
}
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string
{
return 'Wales';
}
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string
{
return 'en-GB';
diff --git a/app/Census/CensusOfWales1841.php b/app/Census/CensusOfWales1841.php
index fd02732353..217ad0a202 100644
--- a/app/Census/CensusOfWales1841.php
+++ b/app/Census/CensusOfWales1841.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1841 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1841 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '06 JUN 1841';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1851.php b/app/Census/CensusOfWales1851.php
index 84ead4c9b1..ebc282c825 100644
--- a/app/Census/CensusOfWales1851.php
+++ b/app/Census/CensusOfWales1851.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1851 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1851 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '30 MAR 1851';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1861.php b/app/Census/CensusOfWales1861.php
index efe6a5baf6..24ba672e28 100644
--- a/app/Census/CensusOfWales1861.php
+++ b/app/Census/CensusOfWales1861.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1861 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1861 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '07 APR 1861';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1871.php b/app/Census/CensusOfWales1871.php
index 5b28791768..a46882d92f 100644
--- a/app/Census/CensusOfWales1871.php
+++ b/app/Census/CensusOfWales1871.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1871 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1871 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1871';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1881.php b/app/Census/CensusOfWales1881.php
index db8765dd64..e349e11398 100644
--- a/app/Census/CensusOfWales1881.php
+++ b/app/Census/CensusOfWales1881.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1881 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1881 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '03 APR 1881';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1891.php b/app/Census/CensusOfWales1891.php
index 52af524569..bb83b6b9bf 100644
--- a/app/Census/CensusOfWales1891.php
+++ b/app/Census/CensusOfWales1891.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1891 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1891 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '05 APR 1891';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1901.php b/app/Census/CensusOfWales1901.php
index db6dfbd6ba..7ba6a4b50d 100644
--- a/app/Census/CensusOfWales1901.php
+++ b/app/Census/CensusOfWales1901.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1901 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1901 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '31 MAR 1901';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusOfWales1911.php b/app/Census/CensusOfWales1911.php
index f2ebb40110..a935e6d1f1 100644
--- a/app/Census/CensusOfWales1911.php
+++ b/app/Census/CensusOfWales1911.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class CensusOfWales1911 extends CensusOfWales implements CensusInterface
+readonly class CensusOfWales1911 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '02 APR 1911';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/CensusPlaceInterface.php b/app/Census/CensusPlaceInterface.php
index 3cea9af7c8..b70cfadb93 100644
--- a/app/Census/CensusPlaceInterface.php
+++ b/app/Census/CensusPlaceInterface.php
@@ -19,29 +19,16 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
interface CensusPlaceInterface
{
/**
* All available censuses for this census place.
*
- * @return array<CensusInterface>
+ * @return list<CensusInterface>
*/
public function allCensusDates(): array;
- /**
- * Where did this census occur, in GEDCOM format.
- *
- * @return string
- */
public function censusPlace(): string;
- /**
- * In which language was this census written.
- *
- * @return string
- */
public function censusLanguage(): string;
}
diff --git a/app/Census/RegisterOfEngland1939.php b/app/Census/RegisterOfEngland1939.php
index a357cc434b..4c5740fa8b 100644
--- a/app/Census/RegisterOfEngland1939.php
+++ b/app/Census/RegisterOfEngland1939.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class RegisterOfEngland1939 extends CensusOfEngland implements CensusInterface
+readonly class RegisterOfEngland1939 extends CensusOfEngland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '29 SEP 1939';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/RegisterOfScotland1939.php b/app/Census/RegisterOfScotland1939.php
index 614b319a5d..efc8ded49d 100644
--- a/app/Census/RegisterOfScotland1939.php
+++ b/app/Census/RegisterOfScotland1939.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class RegisterOfScotland1939 extends CensusOfScotland implements CensusInterface
+readonly class RegisterOfScotland1939 extends CensusOfScotland implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '29 SEP 1939';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{
diff --git a/app/Census/RegisterOfWales1939.php b/app/Census/RegisterOfWales1939.php
index 9a420aeb9b..0c64728fc7 100644
--- a/app/Census/RegisterOfWales1939.php
+++ b/app/Census/RegisterOfWales1939.php
@@ -19,25 +19,15 @@ declare(strict_types=1);
namespace Fisharebest\Webtrees\Census;
-/**
- * Definitions for a census
- */
-class RegisterOfWales1939 extends CensusOfWales implements CensusInterface
+readonly class RegisterOfWales1939 extends CensusOfWales implements CensusInterface
{
- /**
- * When did this census occur.
- *
- * @return string
- */
public function censusDate(): string
{
return '29 SEP 1939';
}
/**
- * The columns of the census.
- *
- * @return array<CensusColumnInterface>
+ * @return list<CensusColumnInterface>
*/
public function columns(): array
{