Skip to content

Commit

Permalink
New updates to generated code
Browse files Browse the repository at this point in the history
  • Loading branch information
octokitbot committed Jan 25, 2025
1 parent 1f34431 commit 39c42d0
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
9 changes: 4 additions & 5 deletions src/GitHub/Models/GlobalAdvisory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,13 @@ public partial class GlobalAdvisory : IParsable
#else
public string Description { get; set; }
#endif
/// <summary>The epss property</summary>
/// <summary>The EPSS scores as calculated by the [Exploit Prediction Scoring System](https://www.first.org/epss).</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
#nullable enable
public global::GitHub.Models.GlobalAdvisory_epss? Epss { get; set; }
public global::GitHub.Models.SecurityAdvisoryEpss? Epss { get; private set; }
#nullable restore
#else
public global::GitHub.Models.GlobalAdvisory_epss Epss { get; set; }
public global::GitHub.Models.SecurityAdvisoryEpss Epss { get; private set; }
#endif
/// <summary>The GitHub Security Advisory ID.</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
Expand Down Expand Up @@ -179,7 +179,7 @@ public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
{ "cvss_severities", n => { CvssSeverities = n.GetObjectValue<global::GitHub.Models.CvssSeverities>(global::GitHub.Models.CvssSeverities.CreateFromDiscriminatorValue); } },
{ "cwes", n => { Cwes = n.GetCollectionOfObjectValues<global::GitHub.Models.GlobalAdvisory_cwes>(global::GitHub.Models.GlobalAdvisory_cwes.CreateFromDiscriminatorValue)?.AsList(); } },
{ "description", n => { Description = n.GetStringValue(); } },
{ "epss", n => { Epss = n.GetObjectValue<global::GitHub.Models.GlobalAdvisory_epss>(global::GitHub.Models.GlobalAdvisory_epss.CreateFromDiscriminatorValue); } },
{ "epss", n => { Epss = n.GetObjectValue<global::GitHub.Models.SecurityAdvisoryEpss>(global::GitHub.Models.SecurityAdvisoryEpss.CreateFromDiscriminatorValue); } },
{ "ghsa_id", n => { GhsaId = n.GetStringValue(); } },
{ "github_reviewed_at", n => { GithubReviewedAt = n.GetDateTimeOffsetValue(); } },
{ "html_url", n => { HtmlUrl = n.GetStringValue(); } },
Expand Down Expand Up @@ -209,7 +209,6 @@ public virtual void Serialize(ISerializationWriter writer)
writer.WriteObjectValue<global::GitHub.Models.CvssSeverities>("cvss_severities", CvssSeverities);
writer.WriteCollectionOfObjectValues<global::GitHub.Models.GlobalAdvisory_cwes>("cwes", Cwes);
writer.WriteStringValue("description", Description);
writer.WriteObjectValue<global::GitHub.Models.GlobalAdvisory_epss>("epss", Epss);
writer.WriteCollectionOfPrimitiveValues<string>("references", References);
writer.WriteEnumValue<global::GitHub.Models.GlobalAdvisory_severity>("severity", Severity);
writer.WriteStringValue("source_code_location", SourceCodeLocation);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@
using System;
namespace GitHub.Models
{
/// <summary>
/// The EPSS scores as calculated by the [Exploit Prediction Scoring System](https://www.first.org/epss).
/// </summary>
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.19.0")]
#pragma warning disable CS1591
public partial class GlobalAdvisory_epss : IAdditionalDataHolder, IParsable
#pragma warning restore CS1591
public partial class SecurityAdvisoryEpss : IAdditionalDataHolder, IParsable
{
/// <summary>Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.</summary>
public IDictionary<string, object> AdditionalData { get; set; }
Expand All @@ -19,21 +20,21 @@ public partial class GlobalAdvisory_epss : IAdditionalDataHolder, IParsable
/// <summary>The percentile property</summary>
public double? Percentile { get; set; }
/// <summary>
/// Instantiates a new <see cref="global::GitHub.Models.GlobalAdvisory_epss"/> and sets the default values.
/// Instantiates a new <see cref="global::GitHub.Models.SecurityAdvisoryEpss"/> and sets the default values.
/// </summary>
public GlobalAdvisory_epss()
public SecurityAdvisoryEpss()
{
AdditionalData = new Dictionary<string, object>();
}
/// <summary>
/// Creates a new instance of the appropriate class based on discriminator value
/// </summary>
/// <returns>A <see cref="global::GitHub.Models.GlobalAdvisory_epss"/></returns>
/// <returns>A <see cref="global::GitHub.Models.SecurityAdvisoryEpss"/></returns>
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
public static global::GitHub.Models.GlobalAdvisory_epss CreateFromDiscriminatorValue(IParseNode parseNode)
public static global::GitHub.Models.SecurityAdvisoryEpss CreateFromDiscriminatorValue(IParseNode parseNode)
{
_ = parseNode ?? throw new ArgumentNullException(nameof(parseNode));
return new global::GitHub.Models.GlobalAdvisory_epss();
return new global::GitHub.Models.SecurityAdvisoryEpss();
}
/// <summary>
/// The deserialization information for the current model
Expand Down
2 changes: 1 addition & 1 deletion src/GitHub/kiota-lock.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"descriptionHash": "4CA6D430F0CF25944A23E251A94782DD3ECAB8769BBE27AC29E4DDE38E7EA934F9BFBD7168F8B72C6B8A2E165701D418E4E843543B5F6DF7E5C54309649FD955",
"descriptionHash": "2E3AE800ADED470B4D3B5F2A158D2D35F0175D03E8C36F908A2470D6931457FDC4EC931A5B21D84F82D14CEDBFE6348373E6A120E4538CB4835CCF6B85D60956",
"descriptionLocation": "../../../../../schemas/ghes-3.11.json",
"lockFileVersion": "1.0.0",
"kiotaVersion": "1.19.0",
Expand Down

0 comments on commit 39c42d0

Please sign in to comment.