Skip to content

Commit

Permalink
Update generated code. (#394)
Browse files Browse the repository at this point in the history
  • Loading branch information
calebkiage authored Nov 18, 2023
1 parent 4ce8265 commit b43bafd
Show file tree
Hide file tree
Showing 11,349 changed files with 56,910 additions and 158,243 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
32 changes: 6 additions & 26 deletions src/generated/Admin/AdminRequestBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -226,19 +226,9 @@ public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<Ad
#else
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<AdminRequestBuilderGetQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.GET,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<AdminRequestBuilderGetQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -254,19 +244,9 @@ public RequestInformation ToPatchRequestInformation(ApiSdk.Models.Admin body, Ac
public RequestInformation ToPatchRequestInformation(ApiSdk.Models.Admin body, Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
_ = body ?? throw new ArgumentNullException(nameof(body));
var requestInfo = new RequestInformation {
HttpMethod = Method.PATCH,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand Down
48 changes: 9 additions & 39 deletions src/generated/Admin/Edge/EdgeRequestBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -180,19 +180,9 @@ public RequestInformation ToDeleteRequestInformation(Action<RequestConfiguration
#else
public RequestInformation ToDeleteRequestInformation(Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.DELETE,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json, application/json");
var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -206,19 +196,9 @@ public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<Ed
#else
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<EdgeRequestBuilderGetQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.GET,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<EdgeRequestBuilderGetQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -234,19 +214,9 @@ public RequestInformation ToPatchRequestInformation(ApiSdk.Models.Edge body, Act
public RequestInformation ToPatchRequestInformation(ApiSdk.Models.Edge body, Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
_ = body ?? throw new ArgumentNullException(nameof(body));
var requestInfo = new RequestInformation {
HttpMethod = Method.PATCH,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,19 +182,9 @@ public RequestInformation ToDeleteRequestInformation(Action<RequestConfiguration
#else
public RequestInformation ToDeleteRequestInformation(Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.DELETE,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json, application/json");
var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -208,19 +198,9 @@ public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<In
#else
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<InternetExplorerModeRequestBuilderGetQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.GET,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<InternetExplorerModeRequestBuilderGetQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -236,19 +216,9 @@ public RequestInformation ToPatchRequestInformation(ApiSdk.Models.InternetExplor
public RequestInformation ToPatchRequestInformation(ApiSdk.Models.InternetExplorerMode body, Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
_ = body ?? throw new ArgumentNullException(nameof(body));
var requestInfo = new RequestInformation {
HttpMethod = Method.PATCH,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,18 +75,8 @@ public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<Co
#else
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<CountRequestBuilderGetQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.GET,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<CountRequestBuilderGetQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9");
return requestInfo;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -245,19 +245,9 @@ public RequestInformation ToDeleteRequestInformation(Action<RequestConfiguration
#else
public RequestInformation ToDeleteRequestInformation(Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.DELETE,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json, application/json");
var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -271,19 +261,9 @@ public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<Br
#else
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<BrowserSiteListItemRequestBuilderGetQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.GET,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<BrowserSiteListItemRequestBuilderGetQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand All @@ -299,19 +279,9 @@ public RequestInformation ToPatchRequestInformation(BrowserSiteList body, Action
public RequestInformation ToPatchRequestInformation(BrowserSiteList body, Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
_ = body ?? throw new ArgumentNullException(nameof(body));
var requestInfo = new RequestInformation {
HttpMethod = Method.PATCH,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public static PublishPostRequestBody CreateFromDiscriminatorValue(IParseNode par
/// <summary>
/// The deserialization information for the current model
/// </summary>
public IDictionary<string, Action<IParseNode>> GetFieldDeserializers() {
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers() {
return new Dictionary<string, Action<IParseNode>> {
{"revision", n => { Revision = n.GetStringValue(); } },
{"sharedCookies", n => { SharedCookies = n.GetCollectionOfObjectValues<BrowserSharedCookie>(BrowserSharedCookie.CreateFromDiscriminatorValue)?.ToList(); } },
Expand All @@ -61,7 +61,7 @@ public IDictionary<string, Action<IParseNode>> GetFieldDeserializers() {
/// Serializes information the current object
/// </summary>
/// <param name="writer">Serialization writer to use to serialize this model</param>
public void Serialize(ISerializationWriter writer) {
public virtual void Serialize(ISerializationWriter writer) {
_ = writer ?? throw new ArgumentNullException(nameof(writer));
writer.WriteStringValue("revision", Revision);
writer.WriteCollectionOfObjectValues<BrowserSharedCookie>("sharedCookies", SharedCookies);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,19 +94,9 @@ public RequestInformation ToPostRequestInformation(PublishPostRequestBody body,
public RequestInformation ToPostRequestInformation(PublishPostRequestBody body, Action<RequestConfiguration<DefaultQueryParameters>> requestConfiguration = default) {
#endif
_ = body ?? throw new ArgumentNullException(nameof(body));
var requestInfo = new RequestInformation {
HttpMethod = Method.POST,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<DefaultQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
requestInfo.Headers.TryAdd("Accept", "application/json;q=1");
var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "application/json");
return requestInfo;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,18 +81,8 @@ public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<Co
#else
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<CountRequestBuilderGetQueryParameters>> requestConfiguration = default) {
#endif
var requestInfo = new RequestInformation {
HttpMethod = Method.GET,
UrlTemplate = UrlTemplate,
PathParameters = PathParameters,
};
if (requestConfiguration != null) {
var requestConfig = new RequestConfiguration<CountRequestBuilderGetQueryParameters>();
requestConfiguration.Invoke(requestConfig);
requestInfo.AddQueryParameters(requestConfig.QueryParameters);
requestInfo.AddRequestOptions(requestConfig.Options);
requestInfo.AddHeaders(requestConfig.Headers);
}
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
requestInfo.Configure(requestConfiguration);
requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9");
return requestInfo;
}
Expand Down
Loading

0 comments on commit b43bafd

Please sign in to comment.