@@ -18,13 +18,15 @@ discard block |
||
| 18 | 18 | /** |
| 19 | 19 | * Definitions for a census |
| 20 | 20 | */ |
| 21 | -class CensusOfDenmark1890 extends CensusOfDenmark implements CensusInterface { |
|
| 21 | +class CensusOfDenmark1890 extends CensusOfDenmark implements CensusInterface |
|
| 22 | +{ |
|
| 22 | 23 | /** |
| 23 | 24 | * When did this census occur. |
| 24 | 25 | * |
| 25 | 26 | * @return string |
| 26 | 27 | */ |
| 27 | - public function censusDate() { |
|
| 28 | + public function censusDate() |
|
| 29 | + { |
|
| 28 | 30 | return '01 FEB 1890'; |
| 29 | 31 | } |
| 30 | 32 | |
@@ -33,7 +35,8 @@ discard block |
||
| 33 | 35 | * |
| 34 | 36 | * @return CensusColumnInterface[] |
| 35 | 37 | */ |
| 36 | - public function columns() { |
|
| 38 | + public function columns() |
|
| 39 | + { |
|
| 37 | 40 | return array( |
| 38 | 41 | new CensusColumnFullName($this, 'Navn', 'Samtlige Personers fulde Navn.'), |
| 39 | 42 | new CensusColumnSexMK($this, 'Køn', 'Kjønnet. Mandkøn (M.) eller Kvindekøn (Kv.).'), |
@@ -18,13 +18,15 @@ discard block |
||
| 18 | 18 | /** |
| 19 | 19 | * Definitions for a census |
| 20 | 20 | */ |
| 21 | -class CensusOfDenmark1860 extends CensusOfDenmark implements CensusInterface { |
|
| 21 | +class CensusOfDenmark1860 extends CensusOfDenmark implements CensusInterface |
|
| 22 | +{ |
|
| 22 | 23 | /** |
| 23 | 24 | * When did this census occur. |
| 24 | 25 | * |
| 25 | 26 | * @return string |
| 26 | 27 | */ |
| 27 | - public function censusDate() { |
|
| 28 | + public function censusDate() |
|
| 29 | + { |
|
| 28 | 30 | return '01 FEB 1860'; |
| 29 | 31 | } |
| 30 | 32 | |
@@ -33,7 +35,8 @@ discard block |
||
| 33 | 35 | * |
| 34 | 36 | * @return CensusColumnInterface[] |
| 35 | 37 | */ |
| 36 | - public function columns() { |
|
| 38 | + public function columns() |
|
| 39 | + { |
|
| 37 | 40 | return array( |
| 38 | 41 | new CensusColumnFullName($this, 'Navn', ''), |
| 39 | 42 | new CensusColumnAge($this, 'Alder', ''), |
@@ -18,13 +18,15 @@ discard block |
||
| 18 | 18 | /** |
| 19 | 19 | * Definitions for a census |
| 20 | 20 | */ |
| 21 | -class CensusOfFrance1836 extends CensusOfFrance implements CensusInterface { |
|
| 21 | +class CensusOfFrance1836 extends CensusOfFrance implements CensusInterface |
|
| 22 | +{ |
|
| 22 | 23 | /** |
| 23 | 24 | * When did this census occur. |
| 24 | 25 | * |
| 25 | 26 | * @return string |
| 26 | 27 | */ |
| 27 | - public function censusDate() { |
|
| 28 | + public function censusDate() |
|
| 29 | + { |
|
| 28 | 30 | return '21 JAN 1836'; |
| 29 | 31 | } |
| 30 | 32 | |
@@ -33,7 +35,8 @@ discard block |
||
| 33 | 35 | * |
| 34 | 36 | * @return CensusColumnInterface[] |
| 35 | 37 | */ |
| 36 | - public function columns() { |
|
| 38 | + public function columns() |
|
| 39 | + { |
|
| 37 | 40 | return array( |
| 38 | 41 | new CensusColumnSurname($this, 'Noms', 'Noms de famille'), |
| 39 | 42 | new CensusColumnGivenNames($this, 'Prénoms', ''), |
@@ -18,7 +18,8 @@ |
||
| 18 | 18 | /** |
| 19 | 19 | * Definitions for a census |
| 20 | 20 | */ |
| 21 | -interface CensusInterface extends CensusPlaceInterface { |
|
| 21 | +interface CensusInterface extends CensusPlaceInterface |
|
| 22 | +{ |
|
| 22 | 23 | /** |
| 23 | 24 | * When did this census occur, in GEDCOM format. |
| 24 | 25 | * |
@@ -18,13 +18,15 @@ discard block |
||
| 18 | 18 | /** |
| 19 | 19 | * Definitions for a census |
| 20 | 20 | */ |
| 21 | -class CensusOfEngland1881 extends CensusOfEngland implements CensusInterface { |
|
| 21 | +class CensusOfEngland1881 extends CensusOfEngland implements CensusInterface |
|
| 22 | +{ |
|
| 22 | 23 | /** |
| 23 | 24 | * When did this census occur. |
| 24 | 25 | * |
| 25 | 26 | * @return string |
| 26 | 27 | */ |
| 27 | - public function censusDate() { |
|
| 28 | + public function censusDate() |
|
| 29 | + { |
|
| 28 | 30 | return '03 APR 1881'; |
| 29 | 31 | } |
| 30 | 32 | |
@@ -33,7 +35,8 @@ discard block |
||
| 33 | 35 | * |
| 34 | 36 | * @return CensusColumnInterface[] |
| 35 | 37 | */ |
| 36 | - public function columns() { |
|
| 38 | + public function columns() |
|
| 39 | + { |
|
| 37 | 40 | return array( |
| 38 | 41 | new CensusColumnFullName($this, 'Name', 'Name and surname'), |
| 39 | 42 | new CensusColumnRelationToHead($this, 'Relation', 'Relation to head of household'), |
@@ -18,7 +18,8 @@ |
||
| 18 | 18 | /** |
| 19 | 19 | * Marital status. |
| 20 | 20 | */ |
| 21 | -class CensusColumnConditionDanish extends CensusColumnConditionEnglish { |
|
| 21 | +class CensusColumnConditionDanish extends CensusColumnConditionEnglish |
|
| 22 | +{ |
|
| 22 | 23 | /* Text to display for married individuals */ |
| 23 | 24 | protected $husband = 'Gift'; |
| 24 | 25 | protected $wife = 'Gift'; |
@@ -20,7 +20,8 @@ discard block |
||
| 20 | 20 | /** |
| 21 | 21 | * The individual's mother's birth place. |
| 22 | 22 | */ |
| 23 | -class CensusColumnMotherBirthPlaceSimple extends CensusColumnMotherBirthPlace implements CensusColumnInterface { |
|
| 23 | +class CensusColumnMotherBirthPlaceSimple extends CensusColumnMotherBirthPlace implements CensusColumnInterface |
|
| 24 | +{ |
|
| 24 | 25 | /** |
| 25 | 26 | * Generate the likely value of this census column, based on available information. |
| 26 | 27 | * |
@@ -29,7 +30,8 @@ discard block |
||
| 29 | 30 | * |
| 30 | 31 | * @return string |
| 31 | 32 | */ |
| 32 | - public function generate(Individual $individual, Individual $head = null) { |
|
| 33 | + public function generate(Individual $individual, Individual $head = null) |
|
| 34 | + { |
|
| 33 | 35 | return $this->lastPartOfPlace(parent::generate($individual, $head)); |
| 34 | 36 | } |
| 35 | 37 | } |
@@ -18,13 +18,15 @@ discard block |
||
| 18 | 18 | /** |
| 19 | 19 | * Definitions for a census |
| 20 | 20 | */ |
| 21 | -class CensusOfEngland1891 extends CensusOfEngland implements CensusInterface { |
|
| 21 | +class CensusOfEngland1891 extends CensusOfEngland implements CensusInterface |
|
| 22 | +{ |
|
| 22 | 23 | /** |
| 23 | 24 | * When did this census occur. |
| 24 | 25 | * |
| 25 | 26 | * @return string |
| 26 | 27 | */ |
| 27 | - public function censusDate() { |
|
| 28 | + public function censusDate() |
|
| 29 | + { |
|
| 28 | 30 | return '05 APR 1891'; |
| 29 | 31 | } |
| 30 | 32 | |
@@ -33,7 +35,8 @@ discard block |
||
| 33 | 35 | * |
| 34 | 36 | * @return CensusColumnInterface[] |
| 35 | 37 | */ |
| 36 | - public function columns() { |
|
| 38 | + public function columns() |
|
| 39 | + { |
|
| 37 | 40 | return array( |
| 38 | 41 | new CensusColumnFullName($this, 'Name', 'Name and surname'), |
| 39 | 42 | new CensusColumnRelationToHead($this, 'Relation', 'Relation to head of household'), |
@@ -20,7 +20,8 @@ discard block |
||
| 20 | 20 | /** |
| 21 | 21 | * The individual's full name. |
| 22 | 22 | */ |
| 23 | -class CensusColumnSurnameGivenNameInitial extends CensusColumnFullName { |
|
| 23 | +class CensusColumnSurnameGivenNameInitial extends CensusColumnFullName |
|
| 24 | +{ |
|
| 24 | 25 | /** |
| 25 | 26 | * Generate the likely value of this census column, based on available information. |
| 26 | 27 | * |
@@ -29,7 +30,8 @@ discard block |
||
| 29 | 30 | * |
| 30 | 31 | * @return string |
| 31 | 32 | */ |
| 32 | - public function generate(Individual $individual, Individual $head = null) { |
|
| 33 | + public function generate(Individual $individual, Individual $head = null) |
|
| 34 | + { |
|
| 33 | 35 | $name = $this->nameAtCensusDate($individual, $this->date()); |
| 34 | 36 | $given = $name['givn']; |
| 35 | 37 | if (strpos($given, ' ') === false) { |