You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/main/java/graphql/relay/ConnectionCursor.java
+9-1Lines changed: 9 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -3,11 +3,19 @@
3
3
importgraphql.PublicApi;
4
4
5
5
/**
6
-
* represents a {@link Connection connection} cursor in relay.
6
+
* Represents a {@link Connection connection} cursor in Relay which is an opaque
7
+
* string that the server understands. Often this is base64 encoded but the spec only
8
+
* mandates that it be an opaque cursor so meaning can't be inferred from it (to prevent cheating like
9
+
* pre calculating the next cursor on the client say)
10
+
*
11
+
* See <a href="https://facebook.github.io/relay/graphql/connections.htm#sec-Cursor">https://facebook.github.io/relay/graphql/connections.htm#sec-Cursor</a>
7
12
*/
8
13
@PublicApi
9
14
publicinterfaceConnectionCursor {
10
15
16
+
/**
17
+
* @return an opaque string that represents this cursor.
Copy file name to clipboardExpand all lines: src/main/java/graphql/relay/Edge.java
+9-1Lines changed: 9 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -3,13 +3,21 @@
3
3
importgraphql.PublicApi;
4
4
5
5
/**
6
-
* represents an edge in relay.
6
+
* Represents an edge in Relay which is essentially a node of data T and the cursor for that node.
7
+
*
8
+
* See <a href="https://facebook.github.io/relay/graphql/connections.htm#sec-Edge-Types">https://facebook.github.io/relay/graphql/connections.htm#sec-Edge-Types</a>
7
9
*/
8
10
@PublicApi
9
11
publicinterfaceEdge<T> {
10
12
13
+
/**
14
+
* @return the node of data that this edge represents
Copy file name to clipboardExpand all lines: src/main/java/graphql/relay/PageInfo.java
+6-3Lines changed: 6 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -3,7 +3,10 @@
3
3
importgraphql.PublicApi;
4
4
5
5
/**
6
-
* represents a page in relay.
6
+
* Represents pagination information in Relay about {@link graphql.relay.Edge edges} when used
7
+
* inside a {@link graphql.relay.Connection connection}
8
+
*
9
+
* See <a href="https://facebook.github.io/relay/graphql/connections.htm#sec-undefined.PageInfo">https://facebook.github.io/relay/graphql/connections.htm#sec-undefined.PageInfo</a>
7
10
*/
8
11
@PublicApi
9
12
publicinterfacePageInfo {
@@ -19,12 +22,12 @@ public interface PageInfo {
19
22
ConnectionCursorgetEndCursor();
20
23
21
24
/**
22
-
* @return true if and only if this page is not the first page. only meaningful when you gave {@code last} argument.
25
+
* @return true if and only if this page is not the first page. only meaningful when you gave the {@code last} argument.
23
26
*/
24
27
booleanisHasPreviousPage();
25
28
26
29
/**
27
-
* @return true if and only if this page is not the last page. only meaningful when you gave {@code first} argument.
30
+
* @return true if and only if this page is not the last page. only meaningful when you gave the {@code first} argument.
0 commit comments