Skip to content

Commit

Permalink
Transaction: CodeStyle.
Browse files Browse the repository at this point in the history
  • Loading branch information
janbarasek authored Aug 6, 2020
1 parent 47c41eb commit eea79f9
Showing 1 changed file with 1 addition and 44 deletions.
45 changes: 1 addition & 44 deletions src/Transaction.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@ final class Transaction implements \Baraja\BankTransferAuthorizator\Transaction


/**
* @param \DateTime $relatedDate
* @param string $currency
* @param string[] $data
*/
public function __construct(\DateTime $relatedDate, string $currency, array $data)
Expand All @@ -68,121 +66,80 @@ public function __construct(\DateTime $relatedDate, string $currency, array $dat
}


/**
* @param int $variableSymbol
* @return bool
*/
public function isVariableSymbol(int $variableSymbol): bool
{
return $this->variable === $variableSymbol || $this->isContainVariableSymbolInMessage($variableSymbol);
}


/**
* @param int $variableSymbol
* @return bool
*/
public function isContainVariableSymbolInMessage(int $variableSymbol): bool
{
return $this->note !== null && strpos($this->note, (string) $variableSymbol) !== false;
}


/**
* @return \DateTime
*/
public function getDate(): \DateTime
{
return $this->date;
}


/**
* @return string
*/
public function getCurrency(): string
{
return $this->currency;
}


/**
* @return string
*/
public function getName(): string
{
return $this->name;
}


/**
* @return string|null
*/
public function getAccountName(): ?string
{
return $this->accountName;
}


/**
* @return string|null
*/
public function getAccountNumber(): ?string
{
return $this->accountNumber;
}


/**
* @return int
*/
public function getSekv(): int
{
return $this->sekv;
}


/**
* @return float
*/
public function getPrice(): float
{
return $this->price;
}


/**
* @return int|null
*/
public function getVariable(): ?int
{
return $this->variable;
}


/**
* @return string|null
*/
public function getKs(): ?string
{
return $this->ks;
}


/**
* @return string|null
*/
public function getSs(): ?string
{
return $this->ss;
}


/**
* @return string|null
*/
public function getNote(): ?string
{
return $this->note;
}
}
}

0 comments on commit eea79f9

Please sign in to comment.