1 | 1 |
deleted file mode 100644 |
... | ... |
@@ -1,117 +0,0 @@ |
1 |
-<?php |
|
2 |
- |
|
3 |
-namespace Illuminate\Contracts\Pagination; |
|
4 |
- |
|
5 |
-interface Paginator |
|
6 |
-{ |
|
7 |
- /** |
|
8 |
- * Get the URL for a given page. |
|
9 |
- * |
|
10 |
- * @param int $page |
|
11 |
- * @return string |
|
12 |
- */ |
|
13 |
- public function url($page); |
|
14 |
- |
|
15 |
- /** |
|
16 |
- * Add a set of query string values to the paginator. |
|
17 |
- * |
|
18 |
- * @param array|string $key |
|
19 |
- * @param string|null $value |
|
20 |
- * @return $this |
|
21 |
- */ |
|
22 |
- public function appends($key, $value = null); |
|
23 |
- |
|
24 |
- /** |
|
25 |
- * Get / set the URL fragment to be appended to URLs. |
|
26 |
- * |
|
27 |
- * @param string|null $fragment |
|
28 |
- * @return $this|string |
|
29 |
- */ |
|
30 |
- public function fragment($fragment = null); |
|
31 |
- |
|
32 |
- /** |
|
33 |
- * The URL for the next page, or null. |
|
34 |
- * |
|
35 |
- * @return string|null |
|
36 |
- */ |
|
37 |
- public function nextPageUrl(); |
|
38 |
- |
|
39 |
- /** |
|
40 |
- * Get the URL for the previous page, or null. |
|
41 |
- * |
|
42 |
- * @return string|null |
|
43 |
- */ |
|
44 |
- public function previousPageUrl(); |
|
45 |
- |
|
46 |
- /** |
|
47 |
- * Get all of the items being paginated. |
|
48 |
- * |
|
49 |
- * @return array |
|
50 |
- */ |
|
51 |
- public function items(); |
|
52 |
- |
|
53 |
- /** |
|
54 |
- * Get the "index" of the first item being paginated. |
|
55 |
- * |
|
56 |
- * @return int |
|
57 |
- */ |
|
58 |
- public function firstItem(); |
|
59 |
- |
|
60 |
- /** |
|
61 |
- * Get the "index" of the last item being paginated. |
|
62 |
- * |
|
63 |
- * @return int |
|
64 |
- */ |
|
65 |
- public function lastItem(); |
|
66 |
- |
|
67 |
- /** |
|
68 |
- * Determine how many items are being shown per page. |
|
69 |
- * |
|
70 |
- * @return int |
|
71 |
- */ |
|
72 |
- public function perPage(); |
|
73 |
- |
|
74 |
- /** |
|
75 |
- * Determine the current page being paginated. |
|
76 |
- * |
|
77 |
- * @return int |
|
78 |
- */ |
|
79 |
- public function currentPage(); |
|
80 |
- |
|
81 |
- /** |
|
82 |
- * Determine if there are enough items to split into multiple pages. |
|
83 |
- * |
|
84 |
- * @return bool |
|
85 |
- */ |
|
86 |
- public function hasPages(); |
|
87 |
- |
|
88 |
- /** |
|
89 |
- * Determine if there is more items in the data store. |
|
90 |
- * |
|
91 |
- * @return bool |
|
92 |
- */ |
|
93 |
- public function hasMorePages(); |
|
94 |
- |
|
95 |
- /** |
|
96 |
- * Determine if the list of items is empty or not. |
|
97 |
- * |
|
98 |
- * @return bool |
|
99 |
- */ |
|
100 |
- public function isEmpty(); |
|
101 |
- |
|
102 |
- /** |
|
103 |
- * Determine if the list of items is not empty. |
|
104 |
- * |
|
105 |
- * @return bool |
|
106 |
- */ |
|
107 |
- public function isNotEmpty(); |
|
108 |
- |
|
109 |
- /** |
|
110 |
- * Render the paginator using a given view. |
|
111 |
- * |
|
112 |
- * @param string|null $view |
|
113 |
- * @param array $data |
|
114 |
- * @return string |
|
115 |
- */ |
|
116 |
- public function render($view = null, $data = []); |
|
117 |
-} |
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,117 @@ |
1 |
+<?php |
|
2 |
+ |
|
3 |
+namespace Illuminate\Contracts\Pagination; |
|
4 |
+ |
|
5 |
+interface Paginator |
|
6 |
+{ |
|
7 |
+ /** |
|
8 |
+ * Get the URL for a given page. |
|
9 |
+ * |
|
10 |
+ * @param int $page |
|
11 |
+ * @return string |
|
12 |
+ */ |
|
13 |
+ public function url($page); |
|
14 |
+ |
|
15 |
+ /** |
|
16 |
+ * Add a set of query string values to the paginator. |
|
17 |
+ * |
|
18 |
+ * @param array|string $key |
|
19 |
+ * @param string|null $value |
|
20 |
+ * @return $this |
|
21 |
+ */ |
|
22 |
+ public function appends($key, $value = null); |
|
23 |
+ |
|
24 |
+ /** |
|
25 |
+ * Get / set the URL fragment to be appended to URLs. |
|
26 |
+ * |
|
27 |
+ * @param string|null $fragment |
|
28 |
+ * @return $this|string |
|
29 |
+ */ |
|
30 |
+ public function fragment($fragment = null); |
|
31 |
+ |
|
32 |
+ /** |
|
33 |
+ * The URL for the next page, or null. |
|
34 |
+ * |
|
35 |
+ * @return string|null |
|
36 |
+ */ |
|
37 |
+ public function nextPageUrl(); |
|
38 |
+ |
|
39 |
+ /** |
|
40 |
+ * Get the URL for the previous page, or null. |
|
41 |
+ * |
|
42 |
+ * @return string|null |
|
43 |
+ */ |
|
44 |
+ public function previousPageUrl(); |
|
45 |
+ |
|
46 |
+ /** |
|
47 |
+ * Get all of the items being paginated. |
|
48 |
+ * |
|
49 |
+ * @return array |
|
50 |
+ */ |
|
51 |
+ public function items(); |
|
52 |
+ |
|
53 |
+ /** |
|
54 |
+ * Get the "index" of the first item being paginated. |
|
55 |
+ * |
|
56 |
+ * @return int |
|
57 |
+ */ |
|
58 |
+ public function firstItem(); |
|
59 |
+ |
|
60 |
+ /** |
|
61 |
+ * Get the "index" of the last item being paginated. |
|
62 |
+ * |
|
63 |
+ * @return int |
|
64 |
+ */ |
|
65 |
+ public function lastItem(); |
|
66 |
+ |
|
67 |
+ /** |
|
68 |
+ * Determine how many items are being shown per page. |
|
69 |
+ * |
|
70 |
+ * @return int |
|
71 |
+ */ |
|
72 |
+ public function perPage(); |
|
73 |
+ |
|
74 |
+ /** |
|
75 |
+ * Determine the current page being paginated. |
|
76 |
+ * |
|
77 |
+ * @return int |
|
78 |
+ */ |
|
79 |
+ public function currentPage(); |
|
80 |
+ |
|
81 |
+ /** |
|
82 |
+ * Determine if there are enough items to split into multiple pages. |
|
83 |
+ * |
|
84 |
+ * @return bool |
|
85 |
+ */ |
|
86 |
+ public function hasPages(); |
|
87 |
+ |
|
88 |
+ /** |
|
89 |
+ * Determine if there is more items in the data store. |
|
90 |
+ * |
|
91 |
+ * @return bool |
|
92 |
+ */ |
|
93 |
+ public function hasMorePages(); |
|
94 |
+ |
|
95 |
+ /** |
|
96 |
+ * Determine if the list of items is empty or not. |
|
97 |
+ * |
|
98 |
+ * @return bool |
|
99 |
+ */ |
|
100 |
+ public function isEmpty(); |
|
101 |
+ |
|
102 |
+ /** |
|
103 |
+ * Determine if the list of items is not empty. |
|
104 |
+ * |
|
105 |
+ * @return bool |
|
106 |
+ */ |
|
107 |
+ public function isNotEmpty(); |
|
108 |
+ |
|
109 |
+ /** |
|
110 |
+ * Render the paginator using a given view. |
|
111 |
+ * |
|
112 |
+ * @param string|null $view |
|
113 |
+ * @param array $data |
|
114 |
+ * @return string |
|
115 |
+ */ |
|
116 |
+ public function render($view = null, $data = []); |
|
117 |
+} |