@@ -26,7 +26,7 @@ public final class PageDetails {
26
26
27
27
private final String currentUrl ;
28
28
29
- private final String prevUrl ;
29
+ private final Optional < String > prevUrl ;
30
30
31
31
private final Optional <String > nextUrl ;
32
32
@@ -36,7 +36,7 @@ private PageDetails(
36
36
int limit ,
37
37
int resultCount ,
38
38
String currentUrl ,
39
- String prevUrl ,
39
+ Optional < String > prevUrl ,
40
40
Optional <String > nextUrl ,
41
41
Map <String , Object > additionalProperties ) {
42
42
this .limit = limit ;
@@ -62,11 +62,17 @@ public String getCurrentUrl() {
62
62
return currentUrl ;
63
63
}
64
64
65
+ /**
66
+ * @return The URL to the next page of transcripts. The previous URL always points to a page with older transcripts.
67
+ */
65
68
@ JsonProperty ("prev_url" )
66
- public String getPrevUrl () {
69
+ public Optional < String > getPrevUrl () {
67
70
return prevUrl ;
68
71
}
69
72
73
+ /**
74
+ * @return The URL to the next page of transcripts. The next URL always points to a page with newer transcripts.
75
+ */
70
76
@ JsonProperty ("next_url" )
71
77
public Optional <String > getNextUrl () {
72
78
return nextUrl ;
@@ -116,34 +122,33 @@ public interface ResultCountStage {
116
122
}
117
123
118
124
public interface CurrentUrlStage {
119
- PrevUrlStage currentUrl (String currentUrl );
120
- }
121
-
122
- public interface PrevUrlStage {
123
- _FinalStage prevUrl (String prevUrl );
125
+ _FinalStage currentUrl (String currentUrl );
124
126
}
125
127
126
128
public interface _FinalStage {
127
129
PageDetails build ();
128
130
131
+ _FinalStage prevUrl (Optional <String > prevUrl );
132
+
133
+ _FinalStage prevUrl (String prevUrl );
134
+
129
135
_FinalStage nextUrl (Optional <String > nextUrl );
130
136
131
137
_FinalStage nextUrl (String nextUrl );
132
138
}
133
139
134
140
@ JsonIgnoreProperties (ignoreUnknown = true )
135
- public static final class Builder
136
- implements LimitStage , ResultCountStage , CurrentUrlStage , PrevUrlStage , _FinalStage {
141
+ public static final class Builder implements LimitStage , ResultCountStage , CurrentUrlStage , _FinalStage {
137
142
private int limit ;
138
143
139
144
private int resultCount ;
140
145
141
146
private String currentUrl ;
142
147
143
- private String prevUrl ;
144
-
145
148
private Optional <String > nextUrl = Optional .empty ();
146
149
150
+ private Optional <String > prevUrl = Optional .empty ();
151
+
147
152
@ JsonAnySetter
148
153
private Map <String , Object > additionalProperties = new HashMap <>();
149
154
@@ -175,18 +180,15 @@ public CurrentUrlStage resultCount(int resultCount) {
175
180
176
181
@ java .lang .Override
177
182
@ JsonSetter ("current_url" )
178
- public PrevUrlStage currentUrl (String currentUrl ) {
183
+ public _FinalStage currentUrl (String currentUrl ) {
179
184
this .currentUrl = currentUrl ;
180
185
return this ;
181
186
}
182
187
183
- @ java .lang .Override
184
- @ JsonSetter ("prev_url" )
185
- public _FinalStage prevUrl (String prevUrl ) {
186
- this .prevUrl = prevUrl ;
187
- return this ;
188
- }
189
-
188
+ /**
189
+ * <p>The URL to the next page of transcripts. The next URL always points to a page with newer transcripts.</p>
190
+ * @return Reference to {@code this} so that method calls can be chained together.
191
+ */
190
192
@ java .lang .Override
191
193
public _FinalStage nextUrl (String nextUrl ) {
192
194
this .nextUrl = Optional .of (nextUrl );
@@ -200,6 +202,23 @@ public _FinalStage nextUrl(Optional<String> nextUrl) {
200
202
return this ;
201
203
}
202
204
205
+ /**
206
+ * <p>The URL to the next page of transcripts. The previous URL always points to a page with older transcripts.</p>
207
+ * @return Reference to {@code this} so that method calls can be chained together.
208
+ */
209
+ @ java .lang .Override
210
+ public _FinalStage prevUrl (String prevUrl ) {
211
+ this .prevUrl = Optional .of (prevUrl );
212
+ return this ;
213
+ }
214
+
215
+ @ java .lang .Override
216
+ @ JsonSetter (value = "prev_url" , nulls = Nulls .SKIP )
217
+ public _FinalStage prevUrl (Optional <String > prevUrl ) {
218
+ this .prevUrl = prevUrl ;
219
+ return this ;
220
+ }
221
+
203
222
@ java .lang .Override
204
223
public PageDetails build () {
205
224
return new PageDetails (limit , resultCount , currentUrl , prevUrl , nextUrl , additionalProperties );
0 commit comments