Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update JCOBridge to version 2.5.2 #120

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ jobs:
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Install local file to be used within Javadoc plugin of generated POM
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.1 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.2 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
shell: bash

- name: Create Jars
Expand Down Expand Up @@ -136,7 +136,7 @@ jobs:
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Install local file to be used within Javadoc plugin of generated POM
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.1 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.2 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
shell: bash

- name: Create Jars
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ jobs:

- name: Maven preparation (step 2)
if: matrix.language == 'java'
run: mvn "install:install-file" "-DgroupId=JCOBridge" "-DartifactId=JCOBridge" "-Dversion=2.5.1" "-Dpackaging=jar" "-Dfile=./bin/net6.0/JCOBridge.jar"
run: mvn "install:install-file" "-DgroupId=JCOBridge" "-DartifactId=JCOBridge" "-Dversion=2.5.2" "-Dpackaging=jar" "-Dfile=./bin/net6.0/JCOBridge.jar"

- if: matrix.language == 'java'
run: mvn --file ./src/java/jnet/pom.xml --no-transfer-progress package
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pullrequest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Install local file to be used within Javadoc plugin of generated POM
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.1 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.2 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
shell: bash

- name: Create Jars
Expand Down Expand Up @@ -117,7 +117,7 @@ jobs:
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Install local file to be used within Javadoc plugin of generated POM
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.1 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.2 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
shell: bash

- name: Create Jars
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Install local file to be used within Javadoc plugin of generated POM
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.1 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.2 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
shell: bash

- name: Create Jars
Expand Down Expand Up @@ -102,7 +102,7 @@ jobs:
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Install local file to be used within Javadoc plugin of generated POM
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.1 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
run: mvn install:install-file -DgroupId=JCOBridge -DartifactId=JCOBridge -Dversion=2.5.2 -Dpackaging=jar -Dfile=./bin/net6.0/JCOBridge.jar
shell: bash

- name: Create Jars
Expand Down
2 changes: 1 addition & 1 deletion src/java/jnet/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
<maven.compiler.target>8</maven.compiler.target>
<classpathfile>${basedir}/classpathfile.classpath</classpathfile>
<jnetversion>1.5.0.0</jnetversion>
<jcobridgeversion>2.5.1</jcobridgeversion>
<jcobridgeversion>2.5.2</jcobridgeversion>
</properties>
<distributionManagement>
<snapshotRepository>
Expand Down
2 changes: 1 addition & 1 deletion src/net/JNet/JNet.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="MASES.CLIParser" Version="3.1.2" />
<PackageReference Include="MASES.JCOBridge" Version="2.5.1">
<PackageReference Include="MASES.JCOBridge" Version="2.5.2">
<IncludeAssets>All</IncludeAssets>
<PrivateAssets>None</PrivateAssets>
</PackageReference>
Expand Down
2 changes: 1 addition & 1 deletion src/net/JNetReflector/JNetReflector.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="MASES.CLIParser" Version="3.1.2" />
<PackageReference Include="MASES.JCOBridge" Version="2.5.1">
<PackageReference Include="MASES.JCOBridge" Version="2.5.2">
<IncludeAssets>All</IncludeAssets>
<PrivateAssets>None</PrivateAssets>
</PackageReference>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
<Reference Include="Microsoft.CSharp" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="MASES.JCOBridge" Version="2.5.1" IncludeAssets="All" PrivateAssets="None" />
<PackageReference Include="MASES.JCOBridge" Version="2.5.2" IncludeAssets="All" PrivateAssets="None" />
</ItemGroup>
</Project>
24 changes: 22 additions & 2 deletions tests/net/JNetTest/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
using Java.Util;
using MASES.JNetTest.Common;
using MASES.JNet.Extensions;
using System.Diagnostics;

namespace MASES.JNetTest
{
Expand Down Expand Up @@ -59,8 +60,27 @@ static void TestExtensions()
var map = dict.ToMap();
var newDict = map.ToDictiony();

var collection = newDict.Values.ToJCollection();
var list = collection.ToList();
const int execution = 10000;
Stopwatch w = Stopwatch.StartNew();
ArrayList<string> alist = new Java.Util.ArrayList<string>();
for (int i = 0; i < execution; i++)
{
alist.Add(i.ToString());
}
w.Stop();
System.Console.WriteLine($"ArrayList Elapsed ticks: {w.ElapsedTicks}");
w.Restart();
System.Collections.Generic.List<string> nlist = new System.Collections.Generic.List<string>();
for (int i = 0; i < execution; i++)
{
nlist.Add(i.ToString());
}
w.Stop();
System.Console.WriteLine($"System.Collections.Generic.List Elapsed ticks: {w.ElapsedTicks}");

//var collection = newDict.Values.ToJCollection();
//var intermediate = collection.ToList<Map.Entry<string, string>>();
var list = ((Collection<string>)alist).ToList(); // Raise an exception because iterator returns java/util/HashMap$Node which is not convertible to string
}
}
}