Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
0.00% covered (danger)
0.00%
0 / 8
0.00% covered (danger)
0.00%
0 / 8
CRAP
0.00% covered (danger)
0.00%
0 / 1
SegmentPageResponse
0.00% covered (danger)
0.00%
0 / 8
0.00% covered (danger)
0.00%
0 / 8
72
0.00% covered (danger)
0.00%
0 / 1
 getSegments
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setSegments
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 getTitle
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setTitle
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 getRevisionId
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setRevisionId
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 getPageId
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 setPageId
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
1<?php
2
3namespace MediaWiki\Wikispeech\Segment;
4
5use Title;
6
7/**
8 * @file
9 * @ingroup Extensions
10 * @license GPL-2.0-or-later
11 */
12
13/**
14 * The response from {@link SegmentPageFactory::segmentPage()}
15 *
16 * @since 0.1.10
17 */
18class SegmentPageResponse {
19
20    /** @var SegmentList|null */
21    private $segments = null;
22
23    /** @var Title|null */
24    private $title = null;
25
26    /** @var int|null */
27    private $revisionId = null;
28
29    /** @var int|null */
30    private $pageId = null;
31
32    /**
33     * @since 0.1.10
34     * @return SegmentList|null
35     */
36    public function getSegments(): ?SegmentList {
37        return $this->segments;
38    }
39
40    /**
41     * @since 0.1.10
42     * @param SegmentList|null $segments
43     */
44    public function setSegments( ?SegmentList $segments ): void {
45        $this->segments = $segments;
46    }
47
48    /**
49     * @since 0.1.10
50     * @return Title|null
51     */
52    public function getTitle(): ?Title {
53        return $this->title;
54    }
55
56    /**
57     * @since 0.1.10
58     * @param Title|null $title
59     */
60    public function setTitle( ?Title $title ): void {
61        $this->title = $title;
62    }
63
64    /**
65     * Revision id fetched by page provider
66     *
67     * @see PageProvider::loadData()
68     * @see PageProvider::getRevisionId()
69     * @since 0.1.10
70     * @return int|null
71     */
72    public function getRevisionId(): ?int {
73        return $this->revisionId;
74    }
75
76    /**
77     * @since 0.1.10
78     * @param int|null $revisionId
79     */
80    public function setRevisionId( ?int $revisionId ): void {
81        $this->revisionId = $revisionId;
82    }
83
84    /**
85     * @since 0.1.10
86     * @return int|null
87     */
88    public function getPageId(): ?int {
89        return $this->pageId;
90    }
91
92    /**
93     * @since 0.1.10
94     * @param int|null $pageId
95     */
96    public function setPageId( ?int $pageId ): void {
97        $this->pageId = $pageId;
98    }
99
100}