-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #164 from timiimit/organize-repo
Organize repo - Major codebase change
- Loading branch information
Showing
118 changed files
with
3,326 additions
and
4,139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
using System.Text; | ||
using UT4MasterServer.Helpers; | ||
using UT4MasterServer.Common.Helpers; | ||
|
||
namespace XUnit.Tests; | ||
|
||
|
File renamed without changes.
7 changes: 3 additions & 4 deletions
7
...hentication/BasicAuthenticationHandler.cs → ...hentication/BasicAuthenticationHandler.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...rver/Authentication/EpicClientIdentity.cs → ...rver.Authentication/EpicClientIdentity.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...Server/Authentication/EpicUserIdentity.cs → ...Server.Authentication/EpicUserIdentity.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
19 changes: 19 additions & 0 deletions
19
UT4MasterServer.Authentication/UT4MasterServer.Authentication.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>net6.0</TargetFramework> | ||
<ImplicitUsings>enable</ImplicitUsings> | ||
<Nullable>enable</Nullable> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Microsoft.AspNetCore.Authentication" Version="2.2.0" /> | ||
<PackageReference Include="Microsoft.AspNetCore.Authorization" Version="2.2.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\UT4MasterServer.Models\UT4MasterServer.Models.csproj" /> | ||
<ProjectReference Include="..\UT4MasterServer.Services\UT4MasterServer.Services.csproj" /> | ||
</ItemGroup> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
namespace UT4MasterServer.Common.Enums; | ||
|
||
public enum GameServerTrust | ||
{ | ||
Epic = 0, | ||
Trusted = 1, | ||
Untrusted = 2 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
namespace UT4MasterServer.Common.Enums; | ||
|
||
public enum OwnerType | ||
{ | ||
Default = 1, | ||
} |
2 changes: 1 addition & 1 deletion
2
UT4MasterServer/Enums/StatisticWindow.cs → ...terServer.Common/Enums/StatisticWindow.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
namespace UT4MasterServer.Enums; | ||
namespace UT4MasterServer.Common.Enums; | ||
|
||
public enum StatisticWindow | ||
{ | ||
|
6 changes: 3 additions & 3 deletions
6
UT4MasterServer/Other/EpicID.cs → UT4MasterServer.Common/EpicID.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...rver/Exceptions/InvalidEpicIDException.cs → ...mmon/Exceptions/InvalidEpicIDException.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
UT4MasterServer/Other/DateTimeExtension.cs → ...erver.Common/Helpers/DateTimeExtension.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
UT4MasterServer/Helpers/PasswordHelper.cs → ...erServer.Common/Helpers/PasswordHelper.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
using System.Buffers; | ||
using System.Text; | ||
|
||
namespace UT4MasterServer.Common.Helpers; | ||
|
||
public static class StreamExtensions | ||
{ | ||
public static async Task<string> ReadAsStringAsync(this Stream stream, int maxByteLength) | ||
{ | ||
return Encoding.UTF8.GetString(await stream.ReadAsBytesAsync(maxByteLength)); | ||
} | ||
|
||
public static async Task<byte[]> ReadAsBytesAsync(this Stream stream, int maxByteLength) | ||
{ | ||
var bytes = ArrayPool<byte>.Shared.Rent(maxByteLength); | ||
int fillCount = 0; | ||
|
||
while (true) | ||
{ | ||
int readCount = await stream.ReadAsync(bytes.AsMemory(fillCount, bytes.Length - fillCount)); | ||
|
||
if (readCount <= 0) | ||
{ | ||
// EOF reached | ||
break; | ||
} | ||
|
||
fillCount += readCount; | ||
} | ||
|
||
byte[] ret = new byte[fillCount]; | ||
Array.Copy(bytes, ret, fillCount); | ||
ArrayPool<byte>.Shared.Return(bytes); | ||
|
||
return ret; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
UT4MasterServer/Helpers/ValidationHelper.cs → ...Server.Common/Helpers/ValidationHelper.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>net6.0</TargetFramework> | ||
<ImplicitUsings>enable</ImplicitUsings> | ||
<Nullable>enable</Nullable> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="MongoDB.Bson" Version="2.19.0" /> | ||
</ItemGroup> | ||
|
||
</Project> |
12 changes: 6 additions & 6 deletions
12
...er/Authentication/ClientIdentification.cs → ...sterServer.Models/ClientIdentification.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...quests/AdminPanelChangePasswordRequest.cs → ...equest/AdminPanelChangePasswordRequest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
UT4MasterServer/Models/Requests/GrantXP.cs → ...rver.Models/DTO/Request/GrantXPRequest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
UT4MasterServer/Models/Requests/SetStars.cs → ...ver.Models/DTO/Request/SetStarsRequest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 10 additions & 13 deletions
23
UT4MasterServer/Models/Error.cs → ...rver.Models/DTO/Response/ErrorResponse.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.