@@ -60,6 +60,32 @@ public MailboxFolderItemRequestBuilder(@jakarta.annotation.Nonnull final HashMap
6060 public MailboxFolderItemRequestBuilder (@ jakarta .annotation .Nonnull final String rawUrl , @ jakarta .annotation .Nonnull final RequestAdapter requestAdapter ) {
6161 super (requestAdapter , "{+baseurl}/admin/exchange/mailboxes/{mailbox%2Did}/folders/{mailboxFolder%2Did}{?%24expand,%24select}" , rawUrl );
6262 }
63+ /**
64+ * Delete a mailboxFolder or a child mailboxFolder within a mailbox.
65+ * @throws ODataError When receiving a 4XX or 5XX status code
66+ * @deprecated
67+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
68+ * @see <a href="https://learn.microsoft.com/graph/api/mailbox-delete-folders?view=graph-rest-beta">Find more info here</a>
69+ */
70+ @ Deprecated
71+ public void delete () {
72+ delete (null );
73+ }
74+ /**
75+ * Delete a mailboxFolder or a child mailboxFolder within a mailbox.
76+ * @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
77+ * @throws ODataError When receiving a 4XX or 5XX status code
78+ * @deprecated
79+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
80+ * @see <a href="https://learn.microsoft.com/graph/api/mailbox-delete-folders?view=graph-rest-beta">Find more info here</a>
81+ */
82+ @ Deprecated
83+ public void delete (@ jakarta .annotation .Nullable final java .util .function .Consumer <DeleteRequestConfiguration > requestConfiguration ) {
84+ final RequestInformation requestInfo = toDeleteRequestInformation (requestConfiguration );
85+ final HashMap <String , ParsableFactory <? extends Parsable >> errorMapping = new HashMap <String , ParsableFactory <? extends Parsable >>();
86+ errorMapping .put ("XXX" , ODataError ::createFromDiscriminatorValue );
87+ this .requestAdapter .sendPrimitive (requestInfo , errorMapping , Void .class );
88+ }
6389 /**
6490 * Read the properties and relationships of a mailboxFolder object.
6591 * @return a {@link MailboxFolder}
@@ -90,6 +116,65 @@ public MailboxFolder get(@jakarta.annotation.Nullable final java.util.function.C
90116 errorMapping .put ("XXX" , ODataError ::createFromDiscriminatorValue );
91117 return this .requestAdapter .send (requestInfo , errorMapping , MailboxFolder ::createFromDiscriminatorValue );
92118 }
119+ /**
120+ * Update mailboxFolder properties such as the displayName within a mailbox.
121+ * @param body The request body
122+ * @return a {@link MailboxFolder}
123+ * @throws ODataError When receiving a 4XX or 5XX status code
124+ * @deprecated
125+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
126+ * @see <a href="https://learn.microsoft.com/graph/api/mailboxfolder-update?view=graph-rest-beta">Find more info here</a>
127+ */
128+ @ jakarta .annotation .Nullable
129+ @ Deprecated
130+ public MailboxFolder patch (@ jakarta .annotation .Nonnull final MailboxFolder body ) {
131+ return patch (body , null );
132+ }
133+ /**
134+ * Update mailboxFolder properties such as the displayName within a mailbox.
135+ * @param body The request body
136+ * @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
137+ * @return a {@link MailboxFolder}
138+ * @throws ODataError When receiving a 4XX or 5XX status code
139+ * @deprecated
140+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
141+ * @see <a href="https://learn.microsoft.com/graph/api/mailboxfolder-update?view=graph-rest-beta">Find more info here</a>
142+ */
143+ @ jakarta .annotation .Nullable
144+ @ Deprecated
145+ public MailboxFolder patch (@ jakarta .annotation .Nonnull final MailboxFolder body , @ jakarta .annotation .Nullable final java .util .function .Consumer <PatchRequestConfiguration > requestConfiguration ) {
146+ Objects .requireNonNull (body );
147+ final RequestInformation requestInfo = toPatchRequestInformation (body , requestConfiguration );
148+ final HashMap <String , ParsableFactory <? extends Parsable >> errorMapping = new HashMap <String , ParsableFactory <? extends Parsable >>();
149+ errorMapping .put ("XXX" , ODataError ::createFromDiscriminatorValue );
150+ return this .requestAdapter .send (requestInfo , errorMapping , MailboxFolder ::createFromDiscriminatorValue );
151+ }
152+ /**
153+ * Delete a mailboxFolder or a child mailboxFolder within a mailbox.
154+ * @return a {@link RequestInformation}
155+ * @deprecated
156+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
157+ */
158+ @ jakarta .annotation .Nonnull
159+ @ Deprecated
160+ public RequestInformation toDeleteRequestInformation () {
161+ return toDeleteRequestInformation (null );
162+ }
163+ /**
164+ * Delete a mailboxFolder or a child mailboxFolder within a mailbox.
165+ * @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
166+ * @return a {@link RequestInformation}
167+ * @deprecated
168+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
169+ */
170+ @ jakarta .annotation .Nonnull
171+ @ Deprecated
172+ public RequestInformation toDeleteRequestInformation (@ jakarta .annotation .Nullable final java .util .function .Consumer <DeleteRequestConfiguration > requestConfiguration ) {
173+ final RequestInformation requestInfo = new RequestInformation (HttpMethod .DELETE , urlTemplate , pathParameters );
174+ requestInfo .configure (requestConfiguration , DeleteRequestConfiguration ::new );
175+ requestInfo .headers .tryAdd ("Accept" , "application/json" );
176+ return requestInfo ;
177+ }
93178 /**
94179 * Read the properties and relationships of a mailboxFolder object.
95180 * @return a {@link RequestInformation}
@@ -116,6 +201,36 @@ public RequestInformation toGetRequestInformation(@jakarta.annotation.Nullable f
116201 requestInfo .headers .tryAdd ("Accept" , "application/json" );
117202 return requestInfo ;
118203 }
204+ /**
205+ * Update mailboxFolder properties such as the displayName within a mailbox.
206+ * @param body The request body
207+ * @return a {@link RequestInformation}
208+ * @deprecated
209+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
210+ */
211+ @ jakarta .annotation .Nonnull
212+ @ Deprecated
213+ public RequestInformation toPatchRequestInformation (@ jakarta .annotation .Nonnull final MailboxFolder body ) {
214+ return toPatchRequestInformation (body , null );
215+ }
216+ /**
217+ * Update mailboxFolder properties such as the displayName within a mailbox.
218+ * @param body The request body
219+ * @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
220+ * @return a {@link RequestInformation}
221+ * @deprecated
222+ * Private preview for Import Export APIs as of 2021-08/PrivatePreview:importExport on 2021-08-19 and will be removed 2021-11-15
223+ */
224+ @ jakarta .annotation .Nonnull
225+ @ Deprecated
226+ public RequestInformation toPatchRequestInformation (@ jakarta .annotation .Nonnull final MailboxFolder body , @ jakarta .annotation .Nullable final java .util .function .Consumer <PatchRequestConfiguration > requestConfiguration ) {
227+ Objects .requireNonNull (body );
228+ final RequestInformation requestInfo = new RequestInformation (HttpMethod .PATCH , urlTemplate , pathParameters );
229+ requestInfo .configure (requestConfiguration , PatchRequestConfiguration ::new );
230+ requestInfo .headers .tryAdd ("Accept" , "application/json" );
231+ requestInfo .setContentFromParsable (requestAdapter , "application/json" , body );
232+ return requestInfo ;
233+ }
119234 /**
120235 * Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
121236 * @param rawUrl The raw URL to use for the request builder.
@@ -129,6 +244,12 @@ public MailboxFolderItemRequestBuilder withUrl(@jakarta.annotation.Nonnull final
129244 Objects .requireNonNull (rawUrl );
130245 return new MailboxFolderItemRequestBuilder (rawUrl , requestAdapter );
131246 }
247+ /**
248+ * Configuration for the request such as headers, query parameters, and middleware options.
249+ */
250+ @ jakarta .annotation .Generated ("com.microsoft.kiota" )
251+ public class DeleteRequestConfiguration extends BaseRequestConfiguration {
252+ }
132253 /**
133254 * Read the properties and relationships of a mailboxFolder object.
134255 */
@@ -167,4 +288,10 @@ public class GetRequestConfiguration extends BaseRequestConfiguration {
167288 @ jakarta .annotation .Nullable
168289 public GetQueryParameters queryParameters = new GetQueryParameters ();
169290 }
291+ /**
292+ * Configuration for the request such as headers, query parameters, and middleware options.
293+ */
294+ @ jakarta .annotation .Generated ("com.microsoft.kiota" )
295+ public class PatchRequestConfiguration extends BaseRequestConfiguration {
296+ }
170297}
0 commit comments