Skip to content

Commit

Permalink
FEAT:| Added/Updated [class, IDictionary, File_extension_restriction_…
Browse files Browse the repository at this point in the history
…parameters, File_extension_restriction_type, File_extension_restriction, static, virtual, List, enum, File_path_restriction_parameters, File_path_restriction_type, File_path_restriction, Max_file_path_length_parameters, Max_file_path_length_type, Max_file_path_length, int, Max_file_size_parameters, Max_file_size_type, Max_file_size, repositories]| Removed [repositories] (#66)

* New updates to generated code

* New updates to generated code

* New updates to generated code

---------

Co-authored-by: Octokit Bot <octokitbot@martynus.net>
Co-authored-by: Keegan Campbell <me@kfcampbell.com>
  • Loading branch information
3 people committed Apr 29, 2024
1 parent fefc246 commit 1ea21b0
Show file tree
Hide file tree
Showing 32 changed files with 1,017 additions and 41 deletions.
14 changes: 7 additions & 7 deletions src/GitHub.Octokit.SDK.csproj
Expand Up @@ -33,13 +33,13 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Kiota.Abstractions" Version="1.8.3" />
<PackageReference Include="Microsoft.Kiota.Http.HttpClientLibrary" Version="1.3.9" />
<PackageReference Include="Microsoft.Kiota.Serialization.Form" Version="1.1.5" />
<PackageReference Include="Microsoft.Kiota.Serialization.Json" Version="1.2.1" />
<PackageReference Include="Microsoft.Kiota.Serialization.Multipart" Version="1.1.3" />
<PackageReference Include="Microsoft.Kiota.Serialization.Text" Version="1.1.4" />
<PackageReference Include="Microsoft.Kiota.Authentication.Azure" Version="1.1.4" />
<PackageReference Include="Microsoft.Kiota.Abstractions" Version="1.8.4" />
<PackageReference Include="Microsoft.Kiota.Http.HttpClientLibrary" Version="1.4.0" />
<PackageReference Include="Microsoft.Kiota.Serialization.Form" Version="1.1.6" />
<PackageReference Include="Microsoft.Kiota.Serialization.Json" Version="1.2.3" />
<PackageReference Include="Microsoft.Kiota.Serialization.Multipart" Version="1.1.4" />
<PackageReference Include="Microsoft.Kiota.Serialization.Text" Version="1.1.5" />
<PackageReference Include="Microsoft.Kiota.Authentication.Azure" Version="1.1.5" />
<None Include="NugetREADME.md" Pack="true" PackagePath="\" />
<None Include="octokit.png" Pack="true" PackagePath="\" />
</ItemGroup>
Expand Down
66 changes: 66 additions & 0 deletions src/GitHub/Models/File_extension_restriction.cs
@@ -0,0 +1,66 @@
// <auto-generated/>
using Microsoft.Kiota.Abstractions.Serialization;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System;
namespace GitHub.Models {
/// <summary>
/// Note: file_extension_restriction is in beta and subject to change.Prevent commits that include files with specified file extensions from being pushed to the commit graph.
/// </summary>
public class File_extension_restriction : 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; }
/// <summary>The parameters property</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
#nullable enable
public File_extension_restriction_parameters? Parameters { get; set; }
#nullable restore
#else
public File_extension_restriction_parameters Parameters { get; set; }
#endif
/// <summary>The type property</summary>
public File_extension_restriction_type? Type { get; set; }
/// <summary>
/// Instantiates a new <see cref="File_extension_restriction"/> and sets the default values.
/// </summary>
public File_extension_restriction()
{
AdditionalData = new Dictionary<string, object>();
}
/// <summary>
/// Creates a new instance of the appropriate class based on discriminator value
/// </summary>
/// <returns>A <see cref="File_extension_restriction"/></returns>
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
public static File_extension_restriction CreateFromDiscriminatorValue(IParseNode parseNode)
{
_ = parseNode ?? throw new ArgumentNullException(nameof(parseNode));
return new File_extension_restriction();
}
/// <summary>
/// The deserialization information for the current model
/// </summary>
/// <returns>A IDictionary&lt;string, Action&lt;IParseNode&gt;&gt;</returns>
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
{
return new Dictionary<string, Action<IParseNode>>
{
{"parameters", n => { Parameters = n.GetObjectValue<File_extension_restriction_parameters>(File_extension_restriction_parameters.CreateFromDiscriminatorValue); } },
{"type", n => { Type = n.GetEnumValue<File_extension_restriction_type>(); } },
};
}
/// <summary>
/// Serializes information the current object
/// </summary>
/// <param name="writer">Serialization writer to use to serialize this model</param>
public virtual void Serialize(ISerializationWriter writer)
{
_ = writer ?? throw new ArgumentNullException(nameof(writer));
writer.WriteObjectValue<File_extension_restriction_parameters>("parameters", Parameters);
writer.WriteEnumValue<File_extension_restriction_type>("type", Type);
writer.WriteAdditionalData(AdditionalData);
}
}
}
61 changes: 61 additions & 0 deletions src/GitHub/Models/File_extension_restriction_parameters.cs
@@ -0,0 +1,61 @@
// <auto-generated/>
using Microsoft.Kiota.Abstractions.Serialization;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System;
namespace GitHub.Models {
#pragma warning disable CS1591
public class File_extension_restriction_parameters : IAdditionalDataHolder, IParsable
#pragma warning restore CS1591
{
/// <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; }
/// <summary>The file extensions that are restricted from being pushed to the commit graph.</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
#nullable enable
public List<string>? RestrictedFileExtensions { get; set; }
#nullable restore
#else
public List<string> RestrictedFileExtensions { get; set; }
#endif
/// <summary>
/// Instantiates a new <see cref="File_extension_restriction_parameters"/> and sets the default values.
/// </summary>
public File_extension_restriction_parameters()
{
AdditionalData = new Dictionary<string, object>();
}
/// <summary>
/// Creates a new instance of the appropriate class based on discriminator value
/// </summary>
/// <returns>A <see cref="File_extension_restriction_parameters"/></returns>
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
public static File_extension_restriction_parameters CreateFromDiscriminatorValue(IParseNode parseNode)
{
_ = parseNode ?? throw new ArgumentNullException(nameof(parseNode));
return new File_extension_restriction_parameters();
}
/// <summary>
/// The deserialization information for the current model
/// </summary>
/// <returns>A IDictionary&lt;string, Action&lt;IParseNode&gt;&gt;</returns>
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
{
return new Dictionary<string, Action<IParseNode>>
{
{"restricted_file_extensions", n => { RestrictedFileExtensions = n.GetCollectionOfPrimitiveValues<string>()?.ToList(); } },
};
}
/// <summary>
/// Serializes information the current object
/// </summary>
/// <param name="writer">Serialization writer to use to serialize this model</param>
public virtual void Serialize(ISerializationWriter writer)
{
_ = writer ?? throw new ArgumentNullException(nameof(writer));
writer.WriteCollectionOfPrimitiveValues<string>("restricted_file_extensions", RestrictedFileExtensions);
writer.WriteAdditionalData(AdditionalData);
}
}
}
14 changes: 14 additions & 0 deletions src/GitHub/Models/File_extension_restriction_type.cs
@@ -0,0 +1,14 @@
// <auto-generated/>
using System.Runtime.Serialization;
using System;
namespace GitHub.Models {
#pragma warning disable CS1591
public enum File_extension_restriction_type
#pragma warning restore CS1591
{
[EnumMember(Value = "file_extension_restriction")]
#pragma warning disable CS1591
File_extension_restriction,
#pragma warning restore CS1591
}
}
66 changes: 66 additions & 0 deletions src/GitHub/Models/File_path_restriction.cs
@@ -0,0 +1,66 @@
// <auto-generated/>
using Microsoft.Kiota.Abstractions.Serialization;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System;
namespace GitHub.Models {
/// <summary>
/// Note: file_path_restriction is in beta and subject to change.Prevent commits that include changes in specified file paths from being pushed to the commit graph.
/// </summary>
public class File_path_restriction : 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; }
/// <summary>The parameters property</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
#nullable enable
public File_path_restriction_parameters? Parameters { get; set; }
#nullable restore
#else
public File_path_restriction_parameters Parameters { get; set; }
#endif
/// <summary>The type property</summary>
public File_path_restriction_type? Type { get; set; }
/// <summary>
/// Instantiates a new <see cref="File_path_restriction"/> and sets the default values.
/// </summary>
public File_path_restriction()
{
AdditionalData = new Dictionary<string, object>();
}
/// <summary>
/// Creates a new instance of the appropriate class based on discriminator value
/// </summary>
/// <returns>A <see cref="File_path_restriction"/></returns>
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
public static File_path_restriction CreateFromDiscriminatorValue(IParseNode parseNode)
{
_ = parseNode ?? throw new ArgumentNullException(nameof(parseNode));
return new File_path_restriction();
}
/// <summary>
/// The deserialization information for the current model
/// </summary>
/// <returns>A IDictionary&lt;string, Action&lt;IParseNode&gt;&gt;</returns>
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
{
return new Dictionary<string, Action<IParseNode>>
{
{"parameters", n => { Parameters = n.GetObjectValue<File_path_restriction_parameters>(File_path_restriction_parameters.CreateFromDiscriminatorValue); } },
{"type", n => { Type = n.GetEnumValue<File_path_restriction_type>(); } },
};
}
/// <summary>
/// Serializes information the current object
/// </summary>
/// <param name="writer">Serialization writer to use to serialize this model</param>
public virtual void Serialize(ISerializationWriter writer)
{
_ = writer ?? throw new ArgumentNullException(nameof(writer));
writer.WriteObjectValue<File_path_restriction_parameters>("parameters", Parameters);
writer.WriteEnumValue<File_path_restriction_type>("type", Type);
writer.WriteAdditionalData(AdditionalData);
}
}
}
61 changes: 61 additions & 0 deletions src/GitHub/Models/File_path_restriction_parameters.cs
@@ -0,0 +1,61 @@
// <auto-generated/>
using Microsoft.Kiota.Abstractions.Serialization;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System;
namespace GitHub.Models {
#pragma warning disable CS1591
public class File_path_restriction_parameters : IAdditionalDataHolder, IParsable
#pragma warning restore CS1591
{
/// <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; }
/// <summary>The file paths that are restricted from being pushed to the commit graph.</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
#nullable enable
public List<string>? RestrictedFilePaths { get; set; }
#nullable restore
#else
public List<string> RestrictedFilePaths { get; set; }
#endif
/// <summary>
/// Instantiates a new <see cref="File_path_restriction_parameters"/> and sets the default values.
/// </summary>
public File_path_restriction_parameters()
{
AdditionalData = new Dictionary<string, object>();
}
/// <summary>
/// Creates a new instance of the appropriate class based on discriminator value
/// </summary>
/// <returns>A <see cref="File_path_restriction_parameters"/></returns>
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
public static File_path_restriction_parameters CreateFromDiscriminatorValue(IParseNode parseNode)
{
_ = parseNode ?? throw new ArgumentNullException(nameof(parseNode));
return new File_path_restriction_parameters();
}
/// <summary>
/// The deserialization information for the current model
/// </summary>
/// <returns>A IDictionary&lt;string, Action&lt;IParseNode&gt;&gt;</returns>
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
{
return new Dictionary<string, Action<IParseNode>>
{
{"restricted_file_paths", n => { RestrictedFilePaths = n.GetCollectionOfPrimitiveValues<string>()?.ToList(); } },
};
}
/// <summary>
/// Serializes information the current object
/// </summary>
/// <param name="writer">Serialization writer to use to serialize this model</param>
public virtual void Serialize(ISerializationWriter writer)
{
_ = writer ?? throw new ArgumentNullException(nameof(writer));
writer.WriteCollectionOfPrimitiveValues<string>("restricted_file_paths", RestrictedFilePaths);
writer.WriteAdditionalData(AdditionalData);
}
}
}
14 changes: 14 additions & 0 deletions src/GitHub/Models/File_path_restriction_type.cs
@@ -0,0 +1,14 @@
// <auto-generated/>
using System.Runtime.Serialization;
using System;
namespace GitHub.Models {
#pragma warning disable CS1591
public enum File_path_restriction_type
#pragma warning restore CS1591
{
[EnumMember(Value = "file_path_restriction")]
#pragma warning disable CS1591
File_path_restriction,
#pragma warning restore CS1591
}
}
66 changes: 66 additions & 0 deletions src/GitHub/Models/Max_file_path_length.cs
@@ -0,0 +1,66 @@
// <auto-generated/>
using Microsoft.Kiota.Abstractions.Serialization;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System;
namespace GitHub.Models {
/// <summary>
/// Note: max_file_path_length is in beta and subject to change.Prevent commits that include file paths that exceed a specified character limit from being pushed to the commit graph.
/// </summary>
public class Max_file_path_length : 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; }
/// <summary>The parameters property</summary>
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
#nullable enable
public Max_file_path_length_parameters? Parameters { get; set; }
#nullable restore
#else
public Max_file_path_length_parameters Parameters { get; set; }
#endif
/// <summary>The type property</summary>
public Max_file_path_length_type? Type { get; set; }
/// <summary>
/// Instantiates a new <see cref="Max_file_path_length"/> and sets the default values.
/// </summary>
public Max_file_path_length()
{
AdditionalData = new Dictionary<string, object>();
}
/// <summary>
/// Creates a new instance of the appropriate class based on discriminator value
/// </summary>
/// <returns>A <see cref="Max_file_path_length"/></returns>
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
public static Max_file_path_length CreateFromDiscriminatorValue(IParseNode parseNode)
{
_ = parseNode ?? throw new ArgumentNullException(nameof(parseNode));
return new Max_file_path_length();
}
/// <summary>
/// The deserialization information for the current model
/// </summary>
/// <returns>A IDictionary&lt;string, Action&lt;IParseNode&gt;&gt;</returns>
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
{
return new Dictionary<string, Action<IParseNode>>
{
{"parameters", n => { Parameters = n.GetObjectValue<Max_file_path_length_parameters>(Max_file_path_length_parameters.CreateFromDiscriminatorValue); } },
{"type", n => { Type = n.GetEnumValue<Max_file_path_length_type>(); } },
};
}
/// <summary>
/// Serializes information the current object
/// </summary>
/// <param name="writer">Serialization writer to use to serialize this model</param>
public virtual void Serialize(ISerializationWriter writer)
{
_ = writer ?? throw new ArgumentNullException(nameof(writer));
writer.WriteObjectValue<Max_file_path_length_parameters>("parameters", Parameters);
writer.WriteEnumValue<Max_file_path_length_type>("type", Type);
writer.WriteAdditionalData(AdditionalData);
}
}
}

0 comments on commit 1ea21b0

Please sign in to comment.