2015-05-16 07:51:23 -05:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace FireflyIII\Helpers\Collection;
|
|
|
|
use Illuminate\Support\Collection;
|
|
|
|
|
|
|
|
/**
|
2015-05-16 12:08:54 -05:00
|
|
|
* @codeCoverageIgnore
|
|
|
|
*
|
2015-05-16 07:51:23 -05:00
|
|
|
* Class Balance
|
|
|
|
*
|
|
|
|
* @package FireflyIII\Helpers\Collection
|
|
|
|
*/
|
|
|
|
class Balance
|
|
|
|
{
|
|
|
|
|
|
|
|
/** @var BalanceHeader */
|
|
|
|
protected $balanceHeader;
|
|
|
|
|
|
|
|
/** @var Collection */
|
|
|
|
protected $balanceLines;
|
|
|
|
|
|
|
|
/**
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
public function __construct()
|
|
|
|
{
|
|
|
|
$this->balanceLines = new Collection;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param BalanceLine $line
|
|
|
|
*/
|
|
|
|
public function addBalanceLine(BalanceLine $line)
|
|
|
|
{
|
|
|
|
$this->balanceLines->push($line);
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @return BalanceHeader
|
|
|
|
*/
|
|
|
|
public function getBalanceHeader()
|
|
|
|
{
|
|
|
|
return $this->balanceHeader;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param BalanceHeader $balanceHeader
|
|
|
|
*/
|
|
|
|
public function setBalanceHeader($balanceHeader)
|
|
|
|
{
|
|
|
|
$this->balanceHeader = $balanceHeader;
|
|
|
|
}
|
|
|
|
|
2015-05-16 08:43:58 -05:00
|
|
|
/**
|
|
|
|
* @return \Illuminate\Support\Collection
|
|
|
|
*/
|
|
|
|
public function getBalanceLines()
|
|
|
|
{
|
|
|
|
return $this->balanceLines;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-05-16 07:51:23 -05:00
|
|
|
|
|
|
|
}
|