Skip to content

Commit fe0946c

Browse files
authored
Merge pull request laminas#244 from InvisibleSmiley/fix/233
Adjust documented return types to be `$this` where the pre-existing `self` declaration was too imprecise
2 parents 03c3030 + 3f2d984 commit fe0946c

Some content is hidden

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

77 files changed

+264
-264
lines changed

src/Adapter/Adapter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ public function __construct(
9393
}
9494

9595
/**
96-
* @return self Provides a fluent interface
96+
* @return $this Provides a fluent interface
9797
*/
9898
public function setProfiler(Profiler\ProfilerInterface $profiler)
9999
{

src/Adapter/AdapterAwareTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ trait AdapterAwareTrait
1010
/**
1111
* Set db adapter
1212
*
13-
* @return self Provides a fluent interface
13+
* @return $this Provides a fluent interface
1414
*/
1515
public function setDbAdapter(Adapter $adapter)
1616
{

src/Adapter/Driver/AbstractConnection.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ public function inTransaction()
9595

9696
/**
9797
* @param array $connectionParameters
98-
* @return self Provides a fluent interface
98+
* @return $this Provides a fluent interface
9999
*/
100100
public function setConnectionParameters(array $connectionParameters)
101101
{
@@ -107,7 +107,7 @@ public function setConnectionParameters(array $connectionParameters)
107107
/**
108108
* {@inheritDoc}
109109
*
110-
* @return self Provides a fluent interface
110+
* @return $this Provides a fluent interface
111111
*/
112112
public function setProfiler(ProfilerInterface $profiler)
113113
{

src/Adapter/Driver/IbmDb2/Connection.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public function __construct($connectionParameters = null)
5757
/**
5858
* Set driver
5959
*
60-
* @return self Provides a fluent interface
60+
* @return $this Provides a fluent interface
6161
*/
6262
public function setDriver(IbmDb2 $driver)
6363
{
@@ -68,7 +68,7 @@ public function setDriver(IbmDb2 $driver)
6868

6969
/**
7070
* @param resource $resource DB2 resource
71-
* @return self Provides a fluent interface
71+
* @return $this Provides a fluent interface
7272
*/
7373
public function setResource($resource)
7474
{
@@ -204,7 +204,7 @@ public function commit()
204204
/**
205205
* Rollback
206206
*
207-
* @return self Provides a fluent interface
207+
* @return $this Provides a fluent interface
208208
* @throws Exception\RuntimeException
209209
*/
210210
public function rollback()

src/Adapter/Driver/IbmDb2/IbmDb2.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function __construct($connection, ?Statement $statementPrototype = null,
4040
}
4141

4242
/**
43-
* @return self Provides a fluent interface
43+
* @return $this Provides a fluent interface
4444
*/
4545
public function setProfiler(Profiler\ProfilerInterface $profiler)
4646
{
@@ -63,7 +63,7 @@ public function getProfiler()
6363
}
6464

6565
/**
66-
* @return self Provides a fluent interface
66+
* @return $this Provides a fluent interface
6767
*/
6868
public function registerConnection(Connection $connection)
6969
{
@@ -73,7 +73,7 @@ public function registerConnection(Connection $connection)
7373
}
7474

7575
/**
76-
* @return self Provides a fluent interface
76+
* @return $this Provides a fluent interface
7777
*/
7878
public function registerStatementPrototype(Statement $statementPrototype)
7979
{
@@ -83,7 +83,7 @@ public function registerStatementPrototype(Statement $statementPrototype)
8383
}
8484

8585
/**
86-
* @return self Provides a fluent interface
86+
* @return $this Provides a fluent interface
8787
*/
8888
public function registerResultPrototype(Result $resultPrototype)
8989
{

src/Adapter/Driver/IbmDb2/Result.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class Result implements ResultInterface
2727
/**
2828
* @param resource $resource
2929
* @param mixed $generatedValue
30-
* @return self Provides a fluent interface
30+
* @return $this Provides a fluent interface
3131
*/
3232
public function initialize($resource, $generatedValue = null)
3333
{

src/Adapter/Driver/IbmDb2/Statement.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class Statement implements StatementInterface, Profiler\ProfilerAwareInterface
4242

4343
/**
4444
* @param resource $resource
45-
* @return self Provides a fluent interface
45+
* @return $this Provides a fluent interface
4646
*/
4747
public function initialize($resource)
4848
{
@@ -51,7 +51,7 @@ public function initialize($resource)
5151
}
5252

5353
/**
54-
* @return self Provides a fluent interface
54+
* @return $this Provides a fluent interface
5555
*/
5656
public function setDriver(IbmDb2 $driver)
5757
{
@@ -60,7 +60,7 @@ public function setDriver(IbmDb2 $driver)
6060
}
6161

6262
/**
63-
* @return self Provides a fluent interface
63+
* @return $this Provides a fluent interface
6464
*/
6565
public function setProfiler(Profiler\ProfilerInterface $profiler)
6666
{
@@ -80,7 +80,7 @@ public function getProfiler()
8080
* Set sql
8181
*
8282
* @param null|string $sql
83-
* @return self Provides a fluent interface
83+
* @return $this Provides a fluent interface
8484
*/
8585
public function setSql($sql)
8686
{
@@ -101,7 +101,7 @@ public function getSql()
101101
/**
102102
* Set parameter container
103103
*
104-
* @return self Provides a fluent interface
104+
* @return $this Provides a fluent interface
105105
*/
106106
public function setParameterContainer(ParameterContainer $parameterContainer)
107107
{
@@ -145,7 +145,7 @@ public function getResource()
145145
* Prepare sql
146146
*
147147
* @param string|null $sql
148-
* @return self Provides a fluent interface
148+
* @return $this Provides a fluent interface
149149
* @throws Exception\RuntimeException
150150
*/
151151
public function prepare($sql = null)

src/Adapter/Driver/Mysqli/Connection.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ public function __construct($connectionInfo = null)
4444
}
4545

4646
/**
47-
* @return self Provides a fluent interface
47+
* @return $this Provides a fluent interface
4848
*/
4949
public function setDriver(Mysqli $driver)
5050
{
@@ -71,7 +71,7 @@ public function getCurrentSchema()
7171
/**
7272
* Set resource
7373
*
74-
* @return self Provides a fluent interface
74+
* @return $this Provides a fluent interface
7575
*/
7676
public function setResource(\mysqli $resource)
7777
{

src/Adapter/Driver/Mysqli/Mysqli.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public function __construct(
5555
}
5656

5757
/**
58-
* @return self Provides a fluent interface
58+
* @return $this Provides a fluent interface
5959
*/
6060
public function setProfiler(Profiler\ProfilerInterface $profiler)
6161
{
@@ -80,7 +80,7 @@ public function getProfiler()
8080
/**
8181
* Register connection
8282
*
83-
* @return self Provides a fluent interface
83+
* @return $this Provides a fluent interface
8484
*/
8585
public function registerConnection(Connection $connection)
8686
{

src/Adapter/Driver/Mysqli/Result.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ class Result implements
6464
* @param mixed $resource
6565
* @param mixed $generatedValue
6666
* @param bool|null $isBuffered
67-
* @return self Provides a fluent interface
67+
* @return $this Provides a fluent interface
6868
* @throws Exception\InvalidArgumentException
6969
*/
7070
public function initialize($resource, $generatedValue, $isBuffered = null)

0 commit comments

Comments
 (0)