Skip to content

Commit

Permalink
Separated out Quic from the main project as it requires preview featu…
Browse files Browse the repository at this point in the history
…res.
  • Loading branch information
DJGosnell committed Aug 24, 2023
1 parent cc7ae1f commit 2d11f65
Show file tree
Hide file tree
Showing 9 changed files with 41 additions and 33 deletions.
1 change: 1 addition & 0 deletions src/NexNet.IntegrationTests/BaseTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
using System.Security.Authentication;
using System.Security.Cryptography.X509Certificates;
using NexNet.IntegrationTests.TestInterfaces;
using NexNet.Quic;
using NexNet.Transports;
using NUnit.Framework;
using NUnit.Framework.Internal;
Expand Down
1 change: 1 addition & 0 deletions src/NexNet.IntegrationTests/NexNet.IntegrationTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

<ItemGroup>
<ProjectReference Include="..\NexNet.Generator\NexNet.Generator.csproj" />
<ProjectReference Include="..\NexNet.Quic\NexNet.Quic.csproj" />
<ProjectReference Include="..\NexNet\NexNet.csproj" />
<ProjectReference Include="..\NexNet.Generator\NexNet.Generator.csproj" OutputItemType="Analyzer" ReferenceOutputAssembly="false" SetTargetFramework="TargetFramework=netstandard2.0" />
</ItemGroup>
Expand Down
20 changes: 20 additions & 0 deletions src/NexNet.Quic/NexNet.Quic.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<EnablePreviewFeatures>true</EnablePreviewFeatures>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\NexNet\NexNet.csproj" />
</ItemGroup>
<ItemGroup>
<!-- Platforms supported by this SDK for analyzer warnings. Spec: https://github.com/dotnet/designs/blob/main/accepted/2020/platform-exclusion/platform-exclusion.md -->
<SupportedPlatform Include="Linux" />
<SupportedPlatform Include="macOS" />
<SupportedPlatform Include="Windows" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
using System;
using System.Net;
using System.Net.Quic;
using System.Net;
using System.Net.Security;
using System.Net.Sockets;
using System.Runtime.Versioning;
using System.Threading;
using System.Threading.Tasks;
using NexNet.Transports;

namespace NexNet.Transports;
namespace NexNet.Quic;

/// <summary>
/// Configurations for the client to connect to a QUIC NexNet server.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
using System;
using System.Collections.Generic;
using System.IO.Pipelines;
using System.Net;
using System.IO.Pipelines;
using System.Net.Quic;
using System.Net.Security;
using System.Net.Sockets;
using System.Threading;
using System.Threading.Tasks;
using Pipelines.Sockets.Unofficial;
using NexNet.Transports;

#pragma warning disable CA1416

namespace NexNet.Transports;
namespace NexNet.Quic;

internal class QuicTransport : ITransport
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,10 @@
using System;
using System.Collections.Generic;
using System.Net;
using System.Net.Quic;
using System.Net.Quic;
using System.Net.Security;
using System.Net.Sockets;
using System.Threading;
using System.Threading.Tasks;
using Pipelines.Sockets.Unofficial;
using NexNet.Transports;

#pragma warning disable CA1416

namespace NexNet.Transports;
namespace NexNet.Quic;

internal class QuicTransportListener : ITransportListener
{
Expand Down
6 changes: 6 additions & 0 deletions src/NexNet.sln
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "github", "github", "{AFD63E
..\.github\workflows\dotnet.yml = ..\.github\workflows\dotnet.yml
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NexNet.Quic", "NexNet.Quic\NexNet.Quic.csproj", "{AB75B6D0-0DC0-4E3A-A3A7-320DFB6B09C5}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -44,6 +46,10 @@ Global
{156ED4BC-EF04-4230-9AED-7E1058130BB5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{156ED4BC-EF04-4230-9AED-7E1058130BB5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{156ED4BC-EF04-4230-9AED-7E1058130BB5}.Release|Any CPU.Build.0 = Release|Any CPU
{AB75B6D0-0DC0-4E3A-A3A7-320DFB6B09C5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{AB75B6D0-0DC0-4E3A-A3A7-320DFB6B09C5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{AB75B6D0-0DC0-4E3A-A3A7-320DFB6B09C5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{AB75B6D0-0DC0-4E3A-A3A7-320DFB6B09C5}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
8 changes: 1 addition & 7 deletions src/NexNet/NexNet.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,12 @@
<DefineConstants>$(DefineConstants);SOCKET_STREAM_BUFFERS;RANGES</DefineConstants>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<LangVersion>latest</LangVersion>
<EnablePreviewFeatures>true</EnablePreviewFeatures>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<Description>Communication system to two way communication between a single server and multiple clients.</Description>
<Version>0.1.1</Version>
</PropertyGroup>
<ItemGroup>
<!-- Platforms supported by this SDK for analyzer warnings. Spec: https://github.com/dotnet/designs/blob/main/accepted/2020/platform-exclusion/platform-exclusion.md -->
<SupportedPlatform Include="Linux" />
<SupportedPlatform Include="macOS" />
<SupportedPlatform Include="Windows" />
</ItemGroup>

<ItemGroup>
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
<_Parameter1>NexNet.IntegrationTests</_Parameter1>
Expand Down
1 change: 1 addition & 0 deletions src/NexNetDemo/NexNetDemo.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\NexNet.Generator\NexNet.Generator.csproj" OutputItemType="Analyzer" ReferenceOutputAssembly="false" SetTargetFramework="TargetFramework=netstandard2.0" />
<ProjectReference Include="..\NexNet.Quic\NexNet.Quic.csproj" />
</ItemGroup>

<ItemGroup>
Expand Down

0 comments on commit 2d11f65

Please sign in to comment.