-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathScraperInterface.php
More file actions
61 lines (57 loc) · 1.69 KB
/
ScraperInterface.php
File metadata and controls
61 lines (57 loc) · 1.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<?php
declare(strict_types=1);
namespace BOA\Programs;
use Carbon\CarbonInterface;
/**
* @psalm-type ScrapedBoat = array{
* racer_boat_number: int,
* racer_name: string,
* racer_number: int,
* racer_class_number: int,
* racer_branch_number: int,
* racer_birthplace_number: int,
* racer_age: int,
* racer_weight: float,
* racer_flying_count: int,
* racer_late_count: int,
* racer_average_start_timing: float,
* racer_national_top_1_percent: float,
* racer_national_top_2_percent: float,
* racer_national_top_3_percent: float,
* racer_local_top_1_percent: float,
* racer_local_top_2_percent: float,
* racer_local_top_3_percent: float,
* racer_assigned_motor_number: int,
* racer_assigned_motor_top_2_percent: float,
* racer_assigned_motor_top_3_percent: float,
* racer_assigned_boat_number: int,
* racer_assigned_boat_top_2_percent: float,
* racer_assigned_boat_top_3_percent: float
* }
* @psalm-type ScrapedRace = array{
* race_date: string,
* race_stadium_number: int,
* race_number: int,
* race_closed_at: string,
* race_grade_number: int,
* race_title: string,
* race_subtitle: string,
* race_distance: int,
* boats: array<int, ScrapedBoat>
* }
* @psalm-type ScrapedRaces = array<int, ScrapedRace>
* @psalm-type ScrapedStadiumRaces = array<int, ScrapedRaces>
*
* @author shimomo
*/
interface ScraperInterface
{
/**
* @psalm-param \Carbon\CarbonInterface $date
* @psalm-return ScrapedStadiumRaces
*
* @param \Carbon\CarbonInterface $date
* @return array
*/
public function scrapePrograms(CarbonInterface $date): array;
}