Skip to content

Commit 8372e0a

Browse files
Microsoft Graph DevX ToolingMicrosoft Graph DevX Tooling
authored andcommitted
feat(generation): update request builders and models
Update generated files with build 175290
1 parent 2331559 commit 8372e0a

File tree

103 files changed

+4175
-419
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+4175
-419
lines changed

src/main/java/com/microsoft/graph/generated/chats/item/members/MembersRequestBuilder.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import com.microsoft.graph.chats.item.members.add.AddRequestBuilder;
44
import com.microsoft.graph.chats.item.members.count.CountRequestBuilder;
55
import com.microsoft.graph.chats.item.members.item.ConversationMemberItemRequestBuilder;
6+
import com.microsoft.graph.chats.item.members.remove.RemoveRequestBuilder;
67
import com.microsoft.graph.models.ConversationMember;
78
import com.microsoft.graph.models.ConversationMemberCollectionResponse;
89
import com.microsoft.graph.models.odataerrors.ODataError;
@@ -40,6 +41,14 @@ public AddRequestBuilder add() {
4041
public CountRequestBuilder count() {
4142
return new CountRequestBuilder(pathParameters, requestAdapter);
4243
}
44+
/**
45+
* Provides operations to call the remove method.
46+
* @return a {@link RemoveRequestBuilder}
47+
*/
48+
@jakarta.annotation.Nonnull
49+
public RemoveRequestBuilder remove() {
50+
return new RemoveRequestBuilder(pathParameters, requestAdapter);
51+
}
4352
/**
4453
* Provides operations to manage the members property of the microsoft.graph.chat entity.
4554
* @param conversationMemberId The unique identifier of conversationMember

src/main/java/com/microsoft/graph/generated/chats/item/members/item/ConversationMemberItemRequestBuilder.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -57,21 +57,21 @@ public void delete(@jakarta.annotation.Nullable final java.util.function.Consume
5757
this.requestAdapter.sendPrimitive(requestInfo, errorMapping, Void.class);
5858
}
5959
/**
60-
* Retrieve a conversationMember from a chat or channel.
60+
* Retrieve a conversationMember from a chat.
6161
* @return a {@link ConversationMember}
6262
* @throws ODataError When receiving a 4XX or 5XX status code
63-
* @see <a href="https://learn.microsoft.com/graph/api/conversationmember-get?view=graph-rest-1.0">Find more info here</a>
63+
* @see <a href="https://learn.microsoft.com/graph/api/chat-get-members?view=graph-rest-1.0">Find more info here</a>
6464
*/
6565
@jakarta.annotation.Nullable
6666
public ConversationMember get() {
6767
return get(null);
6868
}
6969
/**
70-
* Retrieve a conversationMember from a chat or channel.
70+
* Retrieve a conversationMember from a chat.
7171
* @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
7272
* @return a {@link ConversationMember}
7373
* @throws ODataError When receiving a 4XX or 5XX status code
74-
* @see <a href="https://learn.microsoft.com/graph/api/conversationmember-get?view=graph-rest-1.0">Find more info here</a>
74+
* @see <a href="https://learn.microsoft.com/graph/api/chat-get-members?view=graph-rest-1.0">Find more info here</a>
7575
*/
7676
@jakarta.annotation.Nullable
7777
public ConversationMember get(@jakarta.annotation.Nullable final java.util.function.Consumer<GetRequestConfiguration> requestConfiguration) {
@@ -126,15 +126,15 @@ public RequestInformation toDeleteRequestInformation(@jakarta.annotation.Nullabl
126126
return requestInfo;
127127
}
128128
/**
129-
* Retrieve a conversationMember from a chat or channel.
129+
* Retrieve a conversationMember from a chat.
130130
* @return a {@link RequestInformation}
131131
*/
132132
@jakarta.annotation.Nonnull
133133
public RequestInformation toGetRequestInformation() {
134134
return toGetRequestInformation(null);
135135
}
136136
/**
137-
* Retrieve a conversationMember from a chat or channel.
137+
* Retrieve a conversationMember from a chat.
138138
* @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
139139
* @return a {@link RequestInformation}
140140
*/
@@ -186,7 +186,7 @@ public ConversationMemberItemRequestBuilder withUrl(@jakarta.annotation.Nonnull
186186
public class DeleteRequestConfiguration extends BaseRequestConfiguration {
187187
}
188188
/**
189-
* Retrieve a conversationMember from a chat or channel.
189+
* Retrieve a conversationMember from a chat.
190190
*/
191191
@jakarta.annotation.Generated("com.microsoft.kiota")
192192
public class GetQueryParameters implements QueryParameters {
Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
package com.microsoft.graph.chats.item.members.remove;
2+
3+
import com.microsoft.graph.models.ConversationMember;
4+
import com.microsoft.kiota.serialization.AdditionalDataHolder;
5+
import com.microsoft.kiota.serialization.Parsable;
6+
import com.microsoft.kiota.serialization.ParseNode;
7+
import com.microsoft.kiota.serialization.SerializationWriter;
8+
import com.microsoft.kiota.store.BackedModel;
9+
import com.microsoft.kiota.store.BackingStore;
10+
import com.microsoft.kiota.store.BackingStoreFactorySingleton;
11+
import java.util.HashMap;
12+
import java.util.Map;
13+
import java.util.Objects;
14+
@jakarta.annotation.Generated("com.microsoft.kiota")
15+
public class RemovePostRequestBody implements AdditionalDataHolder, BackedModel, Parsable {
16+
/**
17+
* Stores model information.
18+
*/
19+
@jakarta.annotation.Nonnull
20+
protected BackingStore backingStore;
21+
/**
22+
* Instantiates a new {@link RemovePostRequestBody} and sets the default values.
23+
*/
24+
public RemovePostRequestBody() {
25+
this.backingStore = BackingStoreFactorySingleton.instance.createBackingStore();
26+
this.setAdditionalData(new HashMap<>());
27+
}
28+
/**
29+
* Creates a new instance of the appropriate class based on discriminator value
30+
* @param parseNode The parse node to use to read the discriminator value and create the object
31+
* @return a {@link RemovePostRequestBody}
32+
*/
33+
@jakarta.annotation.Nonnull
34+
public static RemovePostRequestBody createFromDiscriminatorValue(@jakarta.annotation.Nonnull final ParseNode parseNode) {
35+
Objects.requireNonNull(parseNode);
36+
return new RemovePostRequestBody();
37+
}
38+
/**
39+
* Gets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
40+
* @return a {@link Map<String, Object>}
41+
*/
42+
@jakarta.annotation.Nonnull
43+
public Map<String, Object> getAdditionalData() {
44+
Map<String, Object> value = this.backingStore.get("additionalData");
45+
if(value == null) {
46+
value = new HashMap<>();
47+
this.setAdditionalData(value);
48+
}
49+
return value;
50+
}
51+
/**
52+
* Gets the backingStore property value. Stores model information.
53+
* @return a {@link BackingStore}
54+
*/
55+
@jakarta.annotation.Nonnull
56+
public BackingStore getBackingStore() {
57+
return this.backingStore;
58+
}
59+
/**
60+
* The deserialization information for the current model
61+
* @return a {@link Map<String, java.util.function.Consumer<ParseNode>>}
62+
*/
63+
@jakarta.annotation.Nonnull
64+
public Map<String, java.util.function.Consumer<ParseNode>> getFieldDeserializers() {
65+
final HashMap<String, java.util.function.Consumer<ParseNode>> deserializerMap = new HashMap<String, java.util.function.Consumer<ParseNode>>(1);
66+
deserializerMap.put("values", (n) -> { this.setValues(n.getCollectionOfObjectValues(ConversationMember::createFromDiscriminatorValue)); });
67+
return deserializerMap;
68+
}
69+
/**
70+
* Gets the values property value. The values property
71+
* @return a {@link java.util.List<ConversationMember>}
72+
*/
73+
@jakarta.annotation.Nullable
74+
public java.util.List<ConversationMember> getValues() {
75+
return this.backingStore.get("values");
76+
}
77+
/**
78+
* Serializes information the current object
79+
* @param writer Serialization writer to use to serialize this model
80+
*/
81+
public void serialize(@jakarta.annotation.Nonnull final SerializationWriter writer) {
82+
Objects.requireNonNull(writer);
83+
writer.writeCollectionOfObjectValues("values", this.getValues());
84+
writer.writeAdditionalData(this.getAdditionalData());
85+
}
86+
/**
87+
* Sets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
88+
* @param value Value to set for the AdditionalData property.
89+
*/
90+
public void setAdditionalData(@jakarta.annotation.Nullable final Map<String, Object> value) {
91+
this.backingStore.set("additionalData", value);
92+
}
93+
/**
94+
* Sets the backingStore property value. Stores model information.
95+
* @param value Value to set for the backingStore property.
96+
*/
97+
public void setBackingStore(@jakarta.annotation.Nonnull final BackingStore value) {
98+
Objects.requireNonNull(value);
99+
this.backingStore = value;
100+
}
101+
/**
102+
* Sets the values property value. The values property
103+
* @param value Value to set for the values property.
104+
*/
105+
public void setValues(@jakarta.annotation.Nullable final java.util.List<ConversationMember> value) {
106+
this.backingStore.set("values", value);
107+
}
108+
}
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
package com.microsoft.graph.chats.item.members.remove;
2+
3+
import com.microsoft.graph.models.ActionResultPart;
4+
import com.microsoft.graph.models.BaseCollectionPaginationCountResponse;
5+
import com.microsoft.kiota.serialization.Parsable;
6+
import com.microsoft.kiota.serialization.ParseNode;
7+
import com.microsoft.kiota.serialization.SerializationWriter;
8+
import java.util.HashMap;
9+
import java.util.Map;
10+
import java.util.Objects;
11+
@jakarta.annotation.Generated("com.microsoft.kiota")
12+
public class RemovePostResponse extends BaseCollectionPaginationCountResponse implements Parsable {
13+
/**
14+
* Instantiates a new {@link RemovePostResponse} and sets the default values.
15+
*/
16+
public RemovePostResponse() {
17+
super();
18+
}
19+
/**
20+
* Creates a new instance of the appropriate class based on discriminator value
21+
* @param parseNode The parse node to use to read the discriminator value and create the object
22+
* @return a {@link RemovePostResponse}
23+
*/
24+
@jakarta.annotation.Nonnull
25+
public static RemovePostResponse createFromDiscriminatorValue(@jakarta.annotation.Nonnull final ParseNode parseNode) {
26+
Objects.requireNonNull(parseNode);
27+
return new RemovePostResponse();
28+
}
29+
/**
30+
* The deserialization information for the current model
31+
* @return a {@link Map<String, java.util.function.Consumer<ParseNode>>}
32+
*/
33+
@jakarta.annotation.Nonnull
34+
public Map<String, java.util.function.Consumer<ParseNode>> getFieldDeserializers() {
35+
final HashMap<String, java.util.function.Consumer<ParseNode>> deserializerMap = new HashMap<String, java.util.function.Consumer<ParseNode>>(super.getFieldDeserializers());
36+
deserializerMap.put("value", (n) -> { this.setValue(n.getCollectionOfObjectValues(ActionResultPart::createFromDiscriminatorValue)); });
37+
return deserializerMap;
38+
}
39+
/**
40+
* Gets the value property value. The value property
41+
* @return a {@link java.util.List<ActionResultPart>}
42+
*/
43+
@jakarta.annotation.Nullable
44+
public java.util.List<ActionResultPart> getValue() {
45+
return this.backingStore.get("value");
46+
}
47+
/**
48+
* Serializes information the current object
49+
* @param writer Serialization writer to use to serialize this model
50+
*/
51+
public void serialize(@jakarta.annotation.Nonnull final SerializationWriter writer) {
52+
Objects.requireNonNull(writer);
53+
super.serialize(writer);
54+
writer.writeCollectionOfObjectValues("value", this.getValue());
55+
}
56+
/**
57+
* Sets the value property value. The value property
58+
* @param value Value to set for the value property.
59+
*/
60+
public void setValue(@jakarta.annotation.Nullable final java.util.List<ActionResultPart> value) {
61+
this.backingStore.set("value", value);
62+
}
63+
}
Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
package com.microsoft.graph.chats.item.members.remove;
2+
3+
import com.microsoft.graph.models.odataerrors.ODataError;
4+
import com.microsoft.kiota.BaseRequestBuilder;
5+
import com.microsoft.kiota.BaseRequestConfiguration;
6+
import com.microsoft.kiota.HttpMethod;
7+
import com.microsoft.kiota.RequestAdapter;
8+
import com.microsoft.kiota.RequestInformation;
9+
import com.microsoft.kiota.RequestOption;
10+
import com.microsoft.kiota.serialization.Parsable;
11+
import com.microsoft.kiota.serialization.ParsableFactory;
12+
import java.util.Collection;
13+
import java.util.HashMap;
14+
import java.util.Map;
15+
import java.util.Objects;
16+
/**
17+
* Provides operations to call the remove method.
18+
*/
19+
@jakarta.annotation.Generated("com.microsoft.kiota")
20+
public class RemoveRequestBuilder extends BaseRequestBuilder {
21+
/**
22+
* Instantiates a new {@link RemoveRequestBuilder} and sets the default values.
23+
* @param pathParameters Path parameters for the request
24+
* @param requestAdapter The request adapter to use to execute the requests.
25+
*/
26+
public RemoveRequestBuilder(@jakarta.annotation.Nonnull final HashMap<String, Object> pathParameters, @jakarta.annotation.Nonnull final RequestAdapter requestAdapter) {
27+
super(requestAdapter, "{+baseurl}/chats/{chat%2Did}/members/remove", pathParameters);
28+
}
29+
/**
30+
* Instantiates a new {@link RemoveRequestBuilder} and sets the default values.
31+
* @param rawUrl The raw URL to use for the request builder.
32+
* @param requestAdapter The request adapter to use to execute the requests.
33+
*/
34+
public RemoveRequestBuilder(@jakarta.annotation.Nonnull final String rawUrl, @jakarta.annotation.Nonnull final RequestAdapter requestAdapter) {
35+
super(requestAdapter, "{+baseurl}/chats/{chat%2Did}/members/remove", rawUrl);
36+
}
37+
/**
38+
* Remove multiple members from a team in a single request. The response provides details about which memberships could and couldn't be removed.
39+
* @param body The request body
40+
* @return a {@link RemovePostResponse}
41+
* @throws ODataError When receiving a 4XX or 5XX status code
42+
* @see <a href="https://learn.microsoft.com/graph/api/conversationmember-remove?view=graph-rest-1.0">Find more info here</a>
43+
*/
44+
@jakarta.annotation.Nullable
45+
public RemovePostResponse post(@jakarta.annotation.Nonnull final RemovePostRequestBody body) {
46+
return post(body, null);
47+
}
48+
/**
49+
* Remove multiple members from a team in a single request. The response provides details about which memberships could and couldn't be removed.
50+
* @param body The request body
51+
* @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
52+
* @return a {@link RemovePostResponse}
53+
* @throws ODataError When receiving a 4XX or 5XX status code
54+
* @see <a href="https://learn.microsoft.com/graph/api/conversationmember-remove?view=graph-rest-1.0">Find more info here</a>
55+
*/
56+
@jakarta.annotation.Nullable
57+
public RemovePostResponse post(@jakarta.annotation.Nonnull final RemovePostRequestBody body, @jakarta.annotation.Nullable final java.util.function.Consumer<PostRequestConfiguration> requestConfiguration) {
58+
Objects.requireNonNull(body);
59+
final RequestInformation requestInfo = toPostRequestInformation(body, requestConfiguration);
60+
final HashMap<String, ParsableFactory<? extends Parsable>> errorMapping = new HashMap<String, ParsableFactory<? extends Parsable>>();
61+
errorMapping.put("XXX", ODataError::createFromDiscriminatorValue);
62+
return this.requestAdapter.send(requestInfo, errorMapping, RemovePostResponse::createFromDiscriminatorValue);
63+
}
64+
/**
65+
* Remove multiple members from a team in a single request. The response provides details about which memberships could and couldn't be removed.
66+
* @param body The request body
67+
* @return a {@link RequestInformation}
68+
*/
69+
@jakarta.annotation.Nonnull
70+
public RequestInformation toPostRequestInformation(@jakarta.annotation.Nonnull final RemovePostRequestBody body) {
71+
return toPostRequestInformation(body, null);
72+
}
73+
/**
74+
* Remove multiple members from a team in a single request. The response provides details about which memberships could and couldn't be removed.
75+
* @param body The request body
76+
* @param requestConfiguration Configuration for the request such as headers, query parameters, and middleware options.
77+
* @return a {@link RequestInformation}
78+
*/
79+
@jakarta.annotation.Nonnull
80+
public RequestInformation toPostRequestInformation(@jakarta.annotation.Nonnull final RemovePostRequestBody body, @jakarta.annotation.Nullable final java.util.function.Consumer<PostRequestConfiguration> requestConfiguration) {
81+
Objects.requireNonNull(body);
82+
final RequestInformation requestInfo = new RequestInformation(HttpMethod.POST, urlTemplate, pathParameters);
83+
requestInfo.configure(requestConfiguration, PostRequestConfiguration::new);
84+
requestInfo.headers.tryAdd("Accept", "application/json");
85+
requestInfo.setContentFromParsable(requestAdapter, "application/json", body);
86+
return requestInfo;
87+
}
88+
/**
89+
* Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
90+
* @param rawUrl The raw URL to use for the request builder.
91+
* @return a {@link RemoveRequestBuilder}
92+
*/
93+
@jakarta.annotation.Nonnull
94+
public RemoveRequestBuilder withUrl(@jakarta.annotation.Nonnull final String rawUrl) {
95+
Objects.requireNonNull(rawUrl);
96+
return new RemoveRequestBuilder(rawUrl, requestAdapter);
97+
}
98+
/**
99+
* Configuration for the request such as headers, query parameters, and middleware options.
100+
*/
101+
@jakarta.annotation.Generated("com.microsoft.kiota")
102+
public class PostRequestConfiguration extends BaseRequestConfiguration {
103+
}
104+
}

0 commit comments

Comments
 (0)