Skip to content

Commit 25ca85e

Browse files
committed
docs(ocp): Add since tag
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
1 parent aee960c commit 25ca85e

42 files changed

Lines changed: 358 additions & 2 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

build/psalm-baseline.xml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@
4444
<DeprecatedConstant>
4545
<code><![CDATA[CommentsEvent::EVENT_ADD]]></code>
4646
</DeprecatedConstant>
47+
<DeprecatedMethod>
48+
<code><![CDATA[getEvent]]></code>
49+
</DeprecatedMethod>
4750
</file>
4851
<file src="apps/comments/lib/Listener/CommentsEventListener.php">
4952
<DeprecatedConstant>
@@ -52,6 +55,9 @@
5255
<code><![CDATA[CommentsEvent::EVENT_PRE_UPDATE]]></code>
5356
<code><![CDATA[CommentsEvent::EVENT_UPDATE]]></code>
5457
</DeprecatedConstant>
58+
<DeprecatedMethod>
59+
<code><![CDATA[getEvent]]></code>
60+
</DeprecatedMethod>
5561
</file>
5662
<file src="apps/comments/lib/MaxAutoCompleteResultsInitialState.php">
5763
<DeprecatedMethod>
@@ -63,6 +69,10 @@
6369
<code><![CDATA[CommentsEvent::EVENT_DELETE]]></code>
6470
<code><![CDATA[CommentsEvent::EVENT_PRE_UPDATE]]></code>
6571
</DeprecatedConstant>
72+
<DeprecatedMethod>
73+
<code><![CDATA[getEvent]]></code>
74+
<code><![CDATA[getEvent]]></code>
75+
</DeprecatedMethod>
6676
</file>
6777
<file src="apps/dav/appinfo/v1/publicwebdav.php">
6878
<InternalMethod>
@@ -2083,7 +2093,6 @@
20832093
<file src="apps/provisioning_api/lib/Middleware/ProvisioningApiMiddleware.php">
20842094
<DeprecatedMethod>
20852095
<code><![CDATA[hasAnnotation]]></code>
2086-
<code><![CDATA[hasAnnotation]]></code>
20872096
</DeprecatedMethod>
20882097
<InvalidReturnType>
20892098
<code><![CDATA[Response]]></code>

lib/public/AppFramework/Attribute/ASince.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,16 @@ abstract class ASince {
2222
* @param string $since For shipped apps and server code such as core/ and lib/,
2323
* this should be the server version. For other apps it
2424
* should be the semantic app version.
25+
* @since 32.0.0
2526
*/
2627
public function __construct(
2728
protected string $since,
2829
) {
2930
}
3031

32+
/**
33+
* @since 32.0.0
34+
*/
3135
public function getSince(): string {
3236
return $this->since;
3337
}

lib/public/AppFramework/Attribute/ExceptionalImplementable.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,25 @@
2222
#[Consumable(since: '32.0.0')]
2323
#[Implementable(since: '32.0.0')]
2424
class ExceptionalImplementable {
25+
/**
26+
* @since 32.0.0
27+
*/
2528
public function __construct(
2629
protected string $app,
2730
protected ?string $class = null,
2831
) {
2932
}
3033

34+
/**
35+
* @since 32.0.0
36+
*/
3137
public function getApp(): string {
3238
return $this->app;
3339
}
3440

41+
/**
42+
* @since 32.0.0
43+
*/
3544
public function getClass(): ?string {
3645
return $this->class;
3746
}

lib/public/AppFramework/Controller.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,9 @@ public function buildResponse($response, $format = 'json') {
141141
. $format . '!');
142142
}
143143

144+
/**
145+
* @since 33.0.0
146+
*/
144147
public function isResponderRegistered(string $responder): bool {
145148
return isset($this->responders[$responder]);
146149
}

lib/public/AppFramework/Db/SnowflakeAwareEntity.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,16 @@ abstract class SnowflakeAwareEntity extends Entity {
2626
/** @psalm-param $_fieldTypes array<string, Types::*> */
2727
protected array $_fieldTypes = ['id' => Types::STRING];
2828

29+
/**
30+
* @since 33.0.0
31+
*/
2932
public function setId($id): void {
3033
throw new \LogicException('Use generated id to set a new id to the Snowflake aware entity.');
3134
}
3235

3336
/**
3437
* Automatically creates a snowflake ID
38+
* @since 33.0.0
3539
*/
3640
public function generateId(): void {
3741
if ($this->id === null) {
@@ -41,10 +45,16 @@ public function generateId(): void {
4145
}
4246
}
4347

48+
/**
49+
* @since 33.0.0
50+
*/
4451
public function getCreatedAt(): ?\DateTimeImmutable {
4552
return $this->getSnowflake()?->getCreatedAt();
4653
}
4754

55+
/**
56+
* @since 33.0.0
57+
*/
4858
public function getSnowflake(): ?Snowflake {
4959
if ($this->id === null) {
5060
return null;

lib/public/AppFramework/Http/Attribute/RequestHeader.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ class RequestHeader {
2424
* @param lowercase-string $name The name of the request header
2525
* @param non-empty-string $description The description of the request header
2626
* @param bool $indirect Allow indirect usage of the header for example in a middleware. Enabling this turns off the check which ensures that the header must be referenced in the controller method.
27+
* @since 32.0.0
2728
*/
2829
public function __construct(
2930
protected string $name,

lib/public/AppFramework/PublicShareController.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@
2626
*/
2727
abstract class PublicShareController extends Controller {
2828

29+
/**
30+
* @since 33.0.0
31+
*/
2932
public const DAV_AUTHENTICATED_FRONTEND = 'public_link_authenticated_frontend';
3033

3134
/** @var string */
@@ -118,6 +121,8 @@ public function shareNotFound() {
118121

119122
/**
120123
* Validate the token and password hash stored in session
124+
*
125+
* @since 33.0.0
121126
*/
122127
protected function validateTokenSession(string $token, string $passwordHash): bool {
123128
$allowedTokensJSON = $this->session->get(self::DAV_AUTHENTICATED_FRONTEND) ?? '[]';
@@ -131,6 +136,8 @@ protected function validateTokenSession(string $token, string $passwordHash): bo
131136

132137
/**
133138
* Store the token and password hash in session
139+
*
140+
* @since 33.0.0
134141
*/
135142
protected function storeTokenSession(string $token, string $passwordHash = ''): void {
136143
$allowedTokensJSON = $this->session->get(self::DAV_AUTHENTICATED_FRONTEND) ?? '[]';

lib/public/BackgroundJob/Job.php

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ public function __construct(
3535
) {
3636
}
3737

38+
/**
39+
* @since 25.0.0
40+
*/
3841
#[Override]
3942
public function start(IJobList $jobList): void {
4043
$jobList->setLastRun($this);
@@ -59,45 +62,72 @@ public function start(IJobList $jobList): void {
5962
}
6063
}
6164

65+
/**
66+
* @since 15.0.0
67+
*/
6268
#[Override]
6369
final public function setId(string $id): void {
6470
$this->id = $id;
6571
}
6672

73+
/**
74+
* @since 15.0.0
75+
*/
6776
#[Override]
6877
final public function setLastRun(int $lastRun): void {
6978
$this->lastRun = $lastRun;
7079
}
7180

81+
/**
82+
* @since 15.0.0
83+
*/
7284
#[Override]
7385
public function setArgument(mixed $argument): void {
7486
$this->argument = $argument;
7587
}
7688

89+
/**
90+
* @since 15.0.0
91+
*/
7792
#[Override]
7893
final public function getId(): string {
7994
return $this->id;
8095
}
8196

97+
/**
98+
* @since 15.0.0
99+
*/
82100
#[Override]
83101
final public function getLastRun(): int {
84102
return $this->lastRun;
85103
}
86104

105+
/**
106+
* @since 15.0.0
107+
*/
87108
#[Override]
88109
public function getArgument(): mixed {
89110
return $this->argument;
90111
}
91112

113+
/**
114+
* @since 25.0.0
115+
*/
92116
#[Override]
93117
public function setAllowParallelRuns(bool $allow): void {
94118
$this->allowParallelRuns = $allow;
95119
}
96120

121+
/**
122+
* @since 25.0.0
123+
*/
97124
#[Override]
98125
public function getAllowParallelRuns(): bool {
99126
return $this->allowParallelRuns;
100127
}
101128

129+
/**
130+
* @since 15.0.0
131+
*/
102132
abstract protected function run($argument);
103133
}

lib/public/Calendar/CalendarExportOptions.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ final class CalendarExportOptions {
2424
* Gets the export format
2525
*
2626
* @return 'ical'|'jcal'|'xcal' (defaults to ical)
27+
* @since 32.0.0
2728
*/
2829
public function getFormat(): string {
2930
return $this->format;
@@ -33,34 +34,43 @@ public function getFormat(): string {
3334
* Sets the export format
3435
*
3536
* @param 'ical'|'jcal'|'xcal' $format
37+
* @since 32.0.0
3638
*/
3739
public function setFormat(string $format): void {
3840
$this->format = $format;
3941
}
4042

4143
/**
4244
* Gets the start of the range to export
45+
*
46+
* @since 32.0.0
4347
*/
4448
public function getRangeStart(): ?string {
4549
return $this->rangeStart;
4650
}
4751

4852
/**
4953
* Sets the start of the range to export
54+
*
55+
* @since 32.0.0
5056
*/
5157
public function setRangeStart(?string $rangeStart): void {
5258
$this->rangeStart = $rangeStart;
5359
}
5460

5561
/**
5662
* Gets the number of objects to export
63+
*
64+
* @since 32.0.0
5765
*/
5866
public function getRangeCount(): ?int {
5967
return $this->rangeCount;
6068
}
6169

6270
/**
6371
* Sets the number of objects to export
72+
*
73+
* @since 32.0.0
6474
*/
6575
public function setRangeCount(?int $rangeCount): void {
6676
$this->rangeCount = $rangeCount;

0 commit comments

Comments
 (0)