-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bfd037e
commit 092961c
Showing
141 changed files
with
6,749 additions
and
9,124 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,34 @@ | ||
<Project> | ||
<PropertyGroup> | ||
<LangVersion>latest</LangVersion> | ||
<Nullable>enable</Nullable> | ||
<Authors>Nikita Grishin</Authors> | ||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> | ||
|
||
<CodeAnalysisRuleSet>..\..\..\ruleset.ruleset</CodeAnalysisRuleSet> | ||
<Company>MightyMorphinSpaceEngineers</Company> | ||
<Copyright>Copyright (c) 2023</Copyright> | ||
|
||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
|
||
<GenerateAssemblyInfo>false</GenerateAssemblyInfo> | ||
<GenerateDocumentationFile>true</GenerateDocumentationFile> | ||
<GeneratePackageOnBuild>false</GeneratePackageOnBuild> | ||
|
||
<IsPackable>false</IsPackable> | ||
|
||
<LangVersion>latest</LangVersion> | ||
|
||
<Nullable>enable</Nullable> | ||
|
||
<RepositoryType>git</RepositoryType> | ||
<RepositoryUrl>https://github.com/warning-explosive/Core</RepositoryUrl> | ||
<Copyright>Copyright (c) 2023</Copyright> | ||
<CodeAnalysisRuleSet>..\..\..\ruleset.ruleset</CodeAnalysisRuleSet> | ||
|
||
<RunAnalyzers>true</RunAnalyzers> | ||
<RunAnalyzersDuringBuild>true</RunAnalyzersDuringBuild> | ||
<RunAnalyzersDuringLiveAnalysis>true</RunAnalyzersDuringLiveAnalysis> | ||
<RunAnalyzers>true</RunAnalyzers> | ||
<GenerateAssemblyInfo>false</GenerateAssemblyInfo> | ||
<GeneratePackageOnBuild>false</GeneratePackageOnBuild> | ||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> | ||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> | ||
<GenerateDocumentationFile>true</GenerateDocumentationFile> | ||
|
||
<TargetFramework>netstandard2.1</TargetFramework> | ||
<TieredCompilation>true</TieredCompilation> | ||
<DebugType>full</DebugType> | ||
<DebugSymbols>true</DebugSymbols> | ||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> | ||
</PropertyGroup> | ||
</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,14 @@ | ||
<Project> | ||
<ItemGroup> | ||
<PackageVersion Include="coverlet.msbuild" Version="6.0.2" /> | ||
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="8.0.0" /> | ||
<PackageVersion Include="Microsoft.Extensions.Configuration" Version="8.0.0" /> | ||
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="8.0.0" /> | ||
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="8.0.0" /> | ||
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.11.1" /> | ||
<PackageVersion Include="SimpleInjector" Version="5.4.2" /> | ||
<PackageVersion Include="StyleCop.Analyzers" Version="1.1.118"/> | ||
<PackageVersion Include="xunit" Version="2.9.2" /> | ||
<PackageVersion Include="xunit.runner.visualstudio" Version="2.8.2" /> | ||
</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
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,33 @@ | ||
namespace SpaceEngineers.Core.Basics; | ||
|
||
using System; | ||
using System.Linq; | ||
using System.Reflection; | ||
|
||
public static class AccessorExtensions | ||
{ | ||
private static readonly Type[] IsExternalInitTypes = | ||
new[] | ||
{ | ||
TypeExtensions.FindType("System.Private.CoreLib System.Runtime.CompilerServices.IsExternalInit"), | ||
}; | ||
|
||
public static bool GetIsAccessible(this PropertyInfo property) | ||
{ | ||
var getMethod = property.GetGetMethod(true); | ||
return getMethod != null && getMethod.IsAccessible(); | ||
} | ||
|
||
public static bool SetIsAccessible(this PropertyInfo property) | ||
{ | ||
var setMethod = property.GetSetMethod(true); | ||
return setMethod != null && setMethod.IsAccessible(); | ||
} | ||
|
||
public static bool HasInitializer(this PropertyInfo propertyInfo) | ||
{ | ||
return propertyInfo.SetMethod != default | ||
&& propertyInfo.SetMethod.ReturnParameter != null | ||
&& propertyInfo.SetMethod.ReturnParameter.GetRequiredCustomModifiers().Any(IsExternalInitTypes.Contains); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.