Skip to content

Commit

Permalink
Merge pull request #28 from twitnic/fix/return-values
Browse files Browse the repository at this point in the history
corrected returntypes
  • Loading branch information
sandermarechal authored Mar 12, 2020
2 parents 45f246c + d4fc836 commit 114741b
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions lib/Jejik/MT940/Account.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function getNumber(): ?string
/**
* Setter for number
*/
public function setNumber(?string $number): self
public function setNumber(?string $number): AccountInterface
{
$this->number = $number;
return $this;
Expand All @@ -65,7 +65,7 @@ public function getName(): ?string
/**
* Setter for name
*/
public function setName(?string $name): self
public function setName(?string $name): AccountInterface
{
$this->name = $name;
return $this;
Expand Down
6 changes: 3 additions & 3 deletions lib/Jejik/MT940/Balance.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public function getCurrency(): string
/**
* Setter for currency
*/
public function setCurrency(string $currency): self
public function setCurrency(string $currency): BalanceInterface
{
$this->currency = $currency;
return $this;
Expand All @@ -70,7 +70,7 @@ public function getAmount(): float
/**
* Setter for amount
*/
public function setAmount(float $amount): self
public function setAmount(float $amount): BalanceInterface
{
$this->amount = $amount;
return $this;
Expand All @@ -87,7 +87,7 @@ public function getDate(): ?\DateTime
/**
* Setter for date
*/
public function setDate(?\DateTime $date): self
public function setDate(?\DateTime $date): BalanceInterface
{
$this->date = $date;
return $this;
Expand Down
8 changes: 4 additions & 4 deletions lib/Jejik/MT940/Statement.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public function getNumber(): ?string
/**
* Setter for number
*/
public function setNumber(?string $number): self
public function setNumber(?string $number): StatementInterface
{
$this->number = $number;
return $this;
Expand All @@ -80,7 +80,7 @@ public function getAccount(): ?AccountInterface
/**
* Setter for account
*/
public function setAccount(?AccountInterface $account): self
public function setAccount(?AccountInterface $account): StatementInterface
{
$this->account = $account;
return $this;
Expand All @@ -97,7 +97,7 @@ public function getOpeningBalance(): ?BalanceInterface
/**
* Setter for openingBalance
*/
public function setOpeningBalance(?BalanceInterface $openingBalance): self
public function setOpeningBalance(?BalanceInterface $openingBalance): StatementInterface
{
$this->openingBalance = $openingBalance;
return $this;
Expand All @@ -114,7 +114,7 @@ public function getClosingBalance(): ?BalanceInterface
/**
* Setter for closingBalance
*/
public function setClosingBalance(?BalanceInterface $closingBalance): self
public function setClosingBalance(?BalanceInterface $closingBalance): StatementInterface
{
$this->closingBalance = $closingBalance;
return $this;
Expand Down
10 changes: 5 additions & 5 deletions lib/Jejik/MT940/Transaction.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public function getContraAccount(): ?AccountInterface
/**
* Setter for contraAccount
*/
public function setContraAccount(?AccountInterface $contraAccount): self
public function setContraAccount(?AccountInterface $contraAccount): TransactionInterface
{
$this->contraAccount = $contraAccount;
return $this;
Expand All @@ -80,7 +80,7 @@ public function getAmount(): float
/**
* Setter for amount
*/
public function setAmount(float $amount): self
public function setAmount(float $amount): TransactionInterface
{
$this->amount = $amount;
return $this;
Expand All @@ -97,7 +97,7 @@ public function getDescription(): ?string
/**
* Setter for description
*/
public function setDescription(?string $description): self
public function setDescription(?string $description): TransactionInterface
{
$this->description = $description;
return $this;
Expand All @@ -114,7 +114,7 @@ public function getValueDate(): ?\DateTime
/**
* Setter for valueDate
*/
public function setValueDate(?\DateTime $valueDate): self
public function setValueDate(?\DateTime $valueDate): TransactionInterface
{
$this->valueDate = $valueDate;
return $this;
Expand All @@ -131,7 +131,7 @@ public function getBookDate(): ?\DateTime
/**
* Setter for bookDate
*/
public function setBookDate(?\DateTime $bookDate): self
public function setBookDate(?\DateTime $bookDate): TransactionInterface
{
$this->bookDate = $bookDate;
return $this;
Expand Down

0 comments on commit 114741b

Please sign in to comment.