File tree Expand file tree Collapse file tree 2 files changed +41
-0
lines changed
Templates/Java/requests_extensions Expand file tree Collapse file tree 2 files changed +41
-0
lines changed Original file line number Diff line number Diff line change @@ -103,6 +103,29 @@ import <#=mainNamespace#>.<#=TypeHelperJava.GetPrefixForRequests()#>.<#=c.TypeCo
103
103
}
104
104
105
105
<# } #>
106
+ <# if (c.GetFeatures().CanSkip) { #>
107
+ /**
108
+ * Sets the skip value for the request
109
+ *
110
+ * @param value of the number of items to skip
111
+ * @return the updated request
112
+ */
113
+ public <#=c.ITypeCollectionRequest()#> skip(final int value) {
114
+ addQueryOption(new com.microsoft.graph.options.QueryOption("$skip", value + ""));
115
+ return (<#=c.TypeCollectionRequest()#>)this;
116
+ }
117
+
118
+ <# } #>
119
+
120
+ /**
121
+ * Add Skip token for pagination
122
+ * @param skipToken - Token for pagination
123
+ * @return the updated request
124
+ */
125
+ public <#=c.ITypeCollectionRequest()#> skipToken(final String skipToken) {
126
+ addQueryOption(new QueryOption("$skiptoken", skipToken));
127
+ return (<#=c.ITypeCollectionRequest()#>)this;
128
+ }
106
129
public <#=c.ITypeCollectionPage()#> buildFromResponse(final <#=c.BaseTypeCollectionResponse()#> response) {
107
130
final <#=c.ITypeCollectionRequestBuilder()#> builder;
108
131
if (response.nextLink != null) {
Original file line number Diff line number Diff line change @@ -49,5 +49,23 @@ import <#=importNamespace#>.http.IBaseCollectionPage;
49
49
<#=c.ITypeCollectionRequest()#> top(final int value);
50
50
51
51
<# } #>
52
+ <# if (c.GetFeatures().CanSkip) { #>
53
+ /**
54
+ * Sets the skip value for the request
55
+ *
56
+ * @param value of the number of items to skip
57
+ * @return the updated request
58
+ */
59
+ <#=c.ITypeCollectionRequest()#> skip(final int value);
60
+
61
+ <# } #>
62
+ /**
63
+ * Sets the skip token value for the request
64
+ *
65
+ * @param skipToken value for pagination
66
+ *
67
+ * @return the updated request
68
+ */
69
+ <#=c.ITypeCollectionRequest()#> skipToken(String skipToken);
52
70
}
53
71
<#=PostProcess(c.ITypeCollectionRequest())#>
You can’t perform that action at this time.
0 commit comments