public static function createNew($date, $name, $from, $to, $code, $amount, $description) { return new static(Id::generate(), Date::fromString($date), Account::withName($name, $to), Account::fromNumber($from), Code::fromString($code), Amount::fromString($amount), Description::fromString($description)); }
public static function fromNumber($from) { return new static(Id::generate(), null, $from); }
public static function createNew($title, $type) { return new static(Id::generate(), $title, $type); }