Improved metric repository for per-db methods. Closes #921
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of Cachet.
|
||||
*
|
||||
* (c) Alt Three Services Limited
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace CachetHQ\Cachet\Repositories\Metric;
|
||||
|
||||
use CachetHQ\Cachet\Models\Metric;
|
||||
|
||||
interface MetricInterface
|
||||
{
|
||||
/**
|
||||
* Returns metrics for a given hour.
|
||||
*
|
||||
* @param \CachetHQ\Cachet\Models\Metric $metric
|
||||
* @param int $hour
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPointsByHour(Metric $metric, $hour);
|
||||
|
||||
/**
|
||||
* Returns metrics for the week.
|
||||
*
|
||||
* @param \CachetHQ\Cachet\Models\Metric $metric
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPointsForDayInWeek(Metric $metric, $day);
|
||||
}
|
||||
Reference in New Issue
Block a user