Skip to content

Commit

Permalink
Changed visibility of internal class functions to 'private'. These ar…
Browse files Browse the repository at this point in the history
…e to be used within the class only and should not be public.

Signed-off-by: Sacha Telgenhof <stelgenhof@gmail.com>
  • Loading branch information
stelgenhof committed Jan 23, 2019
1 parent d7b5e92 commit 22609ce
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 29 deletions.
10 changes: 5 additions & 5 deletions src/Yasumi/Provider/Slovakia.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ public function initialize(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateSaintsCyrilAndMethodiusDay(): void
private function calculateSaintsCyrilAndMethodiusDay(): void
{
$this->addHoliday(new Holiday(
'saintsCyrilAndMethodiusDay',
Expand All @@ -141,7 +141,7 @@ public function calculateSaintsCyrilAndMethodiusDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateSlovakNationalUprisingDay(): void
private function calculateSlovakNationalUprisingDay(): void
{
$this->addHoliday(new Holiday(
'slovakNationalUprisingDay',
Expand All @@ -165,7 +165,7 @@ public function calculateSlovakNationalUprisingDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateSlovakConstitutionDay(): void
private function calculateSlovakConstitutionDay(): void
{
$this->addHoliday(new Holiday(
'slovakConstitutionDay',
Expand Down Expand Up @@ -193,7 +193,7 @@ public function calculateSlovakConstitutionDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateOurLadyOfSorrowsDay(): void
private function calculateOurLadyOfSorrowsDay(): void
{
$this->addHoliday(new Holiday('ourLadyOfSorrowsDay', [
'sk_SK' => 'Sviatok Sedembolestnej Panny Márie',
Expand All @@ -211,7 +211,7 @@ public function calculateOurLadyOfSorrowsDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateStruggleForFreedomAndDemocracyDay(): void
private function calculateStruggleForFreedomAndDemocracyDay(): void
{
$this->addHoliday(new Holiday(
'struggleForFreedomAndDemocracyDay',
Expand Down
18 changes: 9 additions & 9 deletions src/Yasumi/Provider/SouthAfrica.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public function initialize(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateHumanRightsDay(): void
private function calculateHumanRightsDay(): void
{
$this->addHoliday(new Holiday(
'humanRightsDay',
Expand All @@ -114,7 +114,7 @@ public function calculateHumanRightsDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateFamilyDay(): void
private function calculateFamilyDay(): void
{
$this->addHoliday(new Holiday(
'familyDay',
Expand All @@ -137,7 +137,7 @@ public function calculateFamilyDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateFreedomDay(): void
private function calculateFreedomDay(): void
{
$this->addHoliday(new Holiday(
'freedomDay',
Expand All @@ -164,7 +164,7 @@ public function calculateFreedomDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateYouthDay(): void
private function calculateYouthDay(): void
{
$this->addHoliday(new Holiday(
'youthDay',
Expand All @@ -187,7 +187,7 @@ public function calculateYouthDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculate2016MunicipalElectionsDay(): void
private function calculate2016MunicipalElectionsDay(): void
{
if ($this->year !== 2016) {
return;
Expand Down Expand Up @@ -216,7 +216,7 @@ public function calculate2016MunicipalElectionsDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateNationalWomensDay(): void
private function calculateNationalWomensDay(): void
{
$this->addHoliday(new Holiday(
'nationalWomensDay',
Expand All @@ -241,7 +241,7 @@ public function calculateNationalWomensDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateHeritageDay(): void
private function calculateHeritageDay(): void
{
$this->addHoliday(new Holiday(
'heritageDay',
Expand All @@ -268,7 +268,7 @@ public function calculateHeritageDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateDayOfReconciliation(): void
private function calculateDayOfReconciliation(): void
{
$this->addHoliday(new Holiday(
'reconciliationDay',
Expand All @@ -294,7 +294,7 @@ public function calculateDayOfReconciliation(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateSubstituteDayOfGoodwill(): void
private function calculateSubstituteDayOfGoodwill(): void
{
if ($this->year !== 2016) {
return;
Expand Down
4 changes: 2 additions & 2 deletions src/Yasumi/Provider/Spain.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public function initialize(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateNationalDay(): void
private function calculateNationalDay(): void
{
if ($this->year >= 1981) {
$this->addHoliday(new Holiday(
Expand All @@ -102,7 +102,7 @@ public function calculateNationalDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateConstitutionDay(): void
private function calculateConstitutionDay(): void
{
if ($this->year >= 1978) {
$this->addHoliday(new Holiday(
Expand Down
6 changes: 3 additions & 3 deletions src/Yasumi/Provider/Sweden.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public function initialize(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateStJohnsDay(): void
private function calculateStJohnsDay(): void
{
$date = new DateTime("$this->year-6-20", new DateTimeZone($this->timezone)); // Default date

Expand Down Expand Up @@ -118,7 +118,7 @@ public function calculateStJohnsDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateAllSaintsDay(): void
private function calculateAllSaintsDay(): void
{
$date = new DateTime("$this->year-10-31", new DateTimeZone($this->timezone));

Expand Down Expand Up @@ -147,7 +147,7 @@ public function calculateAllSaintsDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateNationalDay(): void
private function calculateNationalDay(): void
{
if ($this->year < 1916) {
return;
Expand Down
2 changes: 1 addition & 1 deletion src/Yasumi/Provider/Switzerland.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function initialize(): void
* @throws \Exception
* @throws \Exception
*/
public function calculateNationalDay(): void
private function calculateNationalDay(): void
{
$translations = [
'en_US' => 'National Day',
Expand Down
14 changes: 7 additions & 7 deletions src/Yasumi/Provider/Ukraine.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public function initialize(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateChristmasDay(): void
private function calculateChristmasDay(): void
{
$this->addHoliday(new Holiday(
'christmasDay',
Expand All @@ -93,7 +93,7 @@ public function calculateChristmasDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateInternationalWomensDay(): void
private function calculateInternationalWomensDay(): void
{
$this->addHoliday(new Holiday(
'internationalWomensDay',
Expand All @@ -113,7 +113,7 @@ public function calculateInternationalWomensDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateSecondInternationalWorkersDay(): void
private function calculateSecondInternationalWorkersDay(): void
{
$this->addHoliday(new Holiday('secondInternationalWorkersDay', [
'uk_UA' => 'День міжнародної солідарності трудящих',
Expand All @@ -137,7 +137,7 @@ public function calculateSecondInternationalWorkersDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateVictoryDay(): void
private function calculateVictoryDay(): void
{
$this->addHoliday(new Holiday(
'victoryDay',
Expand All @@ -159,7 +159,7 @@ public function calculateVictoryDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateConstitutionDay(): void
private function calculateConstitutionDay(): void
{
if ($this->year < 1996) {
return;
Expand Down Expand Up @@ -187,7 +187,7 @@ public function calculateConstitutionDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateIndependenceDay(): void
private function calculateIndependenceDay(): void
{
if ($this->year < 1991) {
return;
Expand Down Expand Up @@ -216,7 +216,7 @@ public function calculateIndependenceDay(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateDefenderOfUkraineDay(): void
private function calculateDefenderOfUkraineDay(): void
{
if ($this->year < 2015) {
return;
Expand Down
4 changes: 2 additions & 2 deletions src/Yasumi/Provider/UnitedKingdom.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public function initialize(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateNewYearsDay(): void
private function calculateNewYearsDay(): void
{
// Before 1871 it was not an observed or statutory holiday
if ($this->year < 1871) {
Expand Down Expand Up @@ -213,7 +213,7 @@ private function calculateSummerBankHoliday(): void
* @throws \Yasumi\Exception\UnknownLocaleException
* @throws \Exception
*/
public function calculateChristmasHolidays(): void
private function calculateChristmasHolidays(): void
{
$christmasDay = new DateTime("$this->year-12-25", new DateTimeZone($this->timezone));
$boxingDay = new DateTime("$this->year-12-26", new DateTimeZone($this->timezone));
Expand Down

0 comments on commit 22609ce

Please sign in to comment.