File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,18 @@ abstract class AbstractPaginator implements \Illuminate\Contracts\Support\Htmlab
1515 * @return TValue|null
1616 */
1717 public function offsetGet($key): mixed;
18+
19+ /**
20+ * Transform each item in the slice of items using a callback.
21+ *
22+ * @template TMapValue
23+ *
24+ * @param callable(TValue, TKey): TMapValue $callback
25+ * @return $this
26+ *
27+ * @phpstan-this-out static<TKey, TMapValue>
28+ */
29+ public function through(callable $callback);
1830}
1931
2032/**
@@ -71,6 +83,18 @@ abstract class AbstractCursorPaginator implements \Illuminate\Contracts\Support\
7183 * @return TValue|null
7284 */
7385 public function offsetGet($key): mixed;
86+
87+ /**
88+ * Transform each item in the slice of items using a callback.
89+ *
90+ * @template TMapValue
91+ *
92+ * @param callable(TValue, TKey): TMapValue $callback
93+ * @return $this
94+ *
95+ * @phpstan-this-out static<TKey, TMapValue>
96+ */
97+ public function through(callable $callback);
7498}
7599
76100/**
You can’t perform that action at this time.
0 commit comments