firefly-iii/app/lib/FireflyIII/Database/Ifaces/CommonDatabaseCalls.php

48 lines
781 B
PHP
Raw Normal View History

<?php
2014-10-30 13:26:28 -05:00
namespace FireflyIII\Database\Ifaces;
use Illuminate\Support\Collection;
2014-12-06 05:12:55 -06:00
/**
* Interface CommonDatabaseCalls
*
* @package FireflyIII\Database
*/
interface CommonDatabaseCalls
{
/**
* Returns an object with id $id.
*
* @param int $id
*
2014-12-06 05:12:55 -06:00
* @return \Eloquent
*/
public function find($id);
2014-11-12 15:37:09 -06:00
/**
* Finds an account type using one of the "$what"'s: expense, asset, revenue, opening, etc.
*
* @param $what
*
* @return \AccountType|null
*/
public function findByWhat($what);
/**
* Returns all objects.
*
* @return Collection
*/
public function get();
2014-10-29 04:30:52 -05:00
/**
* @param array $ids
*
* @return Collection
*/
public function getByIds(array $ids);
}