You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by fl...@apache.org on 2021/04/28 14:30:00 UTC
[tinkerpop] 02/03: Update projects to .NET5
This is an automated email from the ASF dual-hosted git repository.
florianhockmann pushed a commit to branch TINKERPOP-2348
in repository https://gitbox.apache.org/repos/asf/tinkerpop.git
commit 9e93416b9c021cdaa2e560090a32d67aa9bb6f3c
Author: Florian Hockmann <fh...@florian-hockmann.de>
AuthorDate: Wed Apr 28 16:25:21 2021 +0200
Update projects to .NET5
---
.../src/Gremlin.Net.Template/Gremlin.Net.Template.csproj | 3 ++-
gremlin-dotnet/src/Gremlin.Net.Template/Program.cs | 14 ++++++--------
gremlin-dotnet/src/Gremlin.Net.Template/Service.cs | 2 +-
.../Gremlin.Net.Benchmarks/Gremlin.Net.Benchmarks.csproj | 2 +-
.../Gremlin.Net.IntegrationTest.csproj | 2 +-
.../Gremlin.Net.Template.IntegrationTest.csproj | 2 +-
.../test/Gremlin.Net.UnitTest/Gremlin.Net.UnitTest.csproj | 2 +-
7 files changed, 13 insertions(+), 14 deletions(-)
diff --git a/gremlin-dotnet/src/Gremlin.Net.Template/Gremlin.Net.Template.csproj b/gremlin-dotnet/src/Gremlin.Net.Template/Gremlin.Net.Template.csproj
index 434b52b..72d94df 100644
--- a/gremlin-dotnet/src/Gremlin.Net.Template/Gremlin.Net.Template.csproj
+++ b/gremlin-dotnet/src/Gremlin.Net.Template/Gremlin.Net.Template.csproj
@@ -19,7 +19,8 @@ limitations under the License.
<PropertyGroup>
<OutputType>Exe</OutputType>
- <TargetFramework>netcoreapp3.1</TargetFramework>
+ <TargetFramework>net5.0</TargetFramework>
+ <Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
diff --git a/gremlin-dotnet/src/Gremlin.Net.Template/Program.cs b/gremlin-dotnet/src/Gremlin.Net.Template/Program.cs
index 93018e7..4e61f36 100644
--- a/gremlin-dotnet/src/Gremlin.Net.Template/Program.cs
+++ b/gremlin-dotnet/src/Gremlin.Net.Template/Program.cs
@@ -37,15 +37,13 @@ namespace Gremlin.Net.Template
private static void Main()
{
- using (var client = new GremlinClient(new GremlinServer(GremlinServerHostname, GremlinServerPort)))
+ using var client = new GremlinClient(new GremlinServer(GremlinServerHostname, GremlinServerPort));
+ var g = Traversal().WithRemote(new DriverRemoteConnection(client));
+ var service = new Service(g);
+ var creators = service.FindCreatorsOfSoftware("lop");
+ foreach (var c in creators)
{
- var g = Traversal().WithRemote(new DriverRemoteConnection(client));
- var service = new Service(g);
- var creators = service.FindCreatorsOfSoftware("lop");
- foreach (var c in creators)
- {
- Console.WriteLine(c);
- }
+ Console.WriteLine(c);
}
}
}
diff --git a/gremlin-dotnet/src/Gremlin.Net.Template/Service.cs b/gremlin-dotnet/src/Gremlin.Net.Template/Service.cs
index 4ded6d3..d4ba4eb 100644
--- a/gremlin-dotnet/src/Gremlin.Net.Template/Service.cs
+++ b/gremlin-dotnet/src/Gremlin.Net.Template/Service.cs
@@ -35,7 +35,7 @@ namespace Gremlin.Net.Template
_g = g;
}
- public IList<string> FindCreatorsOfSoftware(string softwareName)
+ public IList<string?> FindCreatorsOfSoftware(string softwareName)
{
return _g.V().HasLabel("software").Has("name", softwareName).In("created").Values<string>("name").ToList();
}
diff --git a/gremlin-dotnet/test/Gremlin.Net.Benchmarks/Gremlin.Net.Benchmarks.csproj b/gremlin-dotnet/test/Gremlin.Net.Benchmarks/Gremlin.Net.Benchmarks.csproj
index 53f21d0..db59b7e 100644
--- a/gremlin-dotnet/test/Gremlin.Net.Benchmarks/Gremlin.Net.Benchmarks.csproj
+++ b/gremlin-dotnet/test/Gremlin.Net.Benchmarks/Gremlin.Net.Benchmarks.csproj
@@ -2,7 +2,7 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
- <TargetFramework>netcoreapp3.1</TargetFramework>
+ <TargetFramework>net5.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
diff --git a/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gremlin.Net.IntegrationTest.csproj b/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gremlin.Net.IntegrationTest.csproj
index afbaf8e..1a13d96 100644
--- a/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gremlin.Net.IntegrationTest.csproj
+++ b/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gremlin.Net.IntegrationTest.csproj
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
- <TargetFramework>netcoreapp3.1</TargetFramework>
+ <TargetFramework>net5.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<None Update="appsettings.json">
diff --git a/gremlin-dotnet/test/Gremlin.Net.Template.IntegrationTest/Gremlin.Net.Template.IntegrationTest.csproj b/gremlin-dotnet/test/Gremlin.Net.Template.IntegrationTest/Gremlin.Net.Template.IntegrationTest.csproj
index ceb3c97..60085d8 100644
--- a/gremlin-dotnet/test/Gremlin.Net.Template.IntegrationTest/Gremlin.Net.Template.IntegrationTest.csproj
+++ b/gremlin-dotnet/test/Gremlin.Net.Template.IntegrationTest/Gremlin.Net.Template.IntegrationTest.csproj
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
- <TargetFramework>netcoreapp3.1</TargetFramework>
+ <TargetFramework>net5.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
diff --git a/gremlin-dotnet/test/Gremlin.Net.UnitTest/Gremlin.Net.UnitTest.csproj b/gremlin-dotnet/test/Gremlin.Net.UnitTest/Gremlin.Net.UnitTest.csproj
index 90296be..f8fada8 100644
--- a/gremlin-dotnet/test/Gremlin.Net.UnitTest/Gremlin.Net.UnitTest.csproj
+++ b/gremlin-dotnet/test/Gremlin.Net.UnitTest/Gremlin.Net.UnitTest.csproj
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
- <TargetFramework>netcoreapp3.1</TargetFramework>
+ <TargetFramework>net5.0</TargetFramework>
<AssemblyOriginatorKeyFile>../../build/tinkerpop.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
<PublicSign Condition="'$(OS)' != 'Windows_NT'">true</PublicSign>