RprtCli/app/src/Utils/TimeTrackingServices/YoutrackInterface.php

44 lines
969 B
PHP
Raw Normal View History

2021-09-20 01:08:42 +02:00
<?php
declare(strict_types=1);
namespace RprtCli\Utils\TimeTrackingServices;
interface YoutrackInterface
{
/**
* Check if client can sign into youtrack with provided token.
*/
2023-01-02 15:18:52 +01:00
public function testYoutrackapi(): ?string;
2021-09-20 01:08:42 +02:00
/**
* Get the id of the report from configuration.
*/
2023-01-02 15:18:52 +01:00
public function getReportId(): ?string;
2021-09-20 01:08:42 +02:00
/**
* Downloads report and returns file path.
*
*
2021-09-20 01:08:42 +02:00
* Youtrack internal report id.
*
*
2021-09-20 01:08:42 +02:00
* If fetch was unsuccssefull return false, otherwise the file path.
*/
2023-01-02 15:18:52 +01:00
public function downloadReport(string $report_id): ?string;
2021-09-20 01:08:42 +02:00
/**
* Get a list of reports.
*
*
* Array of reports with ids as keys and names as values.
*/
2023-01-02 15:18:52 +01:00
public function listReports(): array;
2023-01-01 23:41:40 +01:00
2023-01-02 15:18:52 +01:00
public function setReportId(string $report_id): void;
public function setReportName(?string $report_name = null): void;
public function getReportName(): ?string;
2021-09-20 01:08:42 +02:00
}