Initial commit – alle alten Commits entfernt
This commit is contained in:
44
Models/Enum.cs
Normal file
44
Models/Enum.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace System
|
||||
{
|
||||
/// <summary>
|
||||
/// Definiert den Typen der App
|
||||
/// </summary>
|
||||
public enum AppType
|
||||
{
|
||||
/// <summary>
|
||||
/// Keine bekannte Typen Zuordnung
|
||||
/// </summary>
|
||||
None = 0,
|
||||
|
||||
/// <summary>
|
||||
/// Eine Benutzer-App
|
||||
/// </summary>
|
||||
User = 1,
|
||||
|
||||
/// <summary>
|
||||
/// Eine Administrations-App
|
||||
/// </summary>
|
||||
Admin = 2,
|
||||
|
||||
/// <summary>
|
||||
/// Eine Favoriten-App
|
||||
/// </summary>
|
||||
Favorites = 3,
|
||||
|
||||
/// <summary>
|
||||
/// Eine Menü-App
|
||||
/// </summary>
|
||||
Menu = 4,
|
||||
|
||||
/// <summary>
|
||||
/// Eine Citrix-App
|
||||
/// </summary>
|
||||
Citrix = 5
|
||||
}
|
||||
}
|
||||
1040
Models/Models.cs
Normal file
1040
Models/Models.cs
Normal file
File diff suppressed because it is too large
Load Diff
71
Models/Models.csproj
Normal file
71
Models/Models.csproj
Normal file
@@ -0,0 +1,71 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{04DDE1A2-453D-4717-9221-5B9C5A49F010}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Models</RootNamespace>
|
||||
<AssemblyName>Models</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<Deterministic>true</Deterministic>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="CustomControls">
|
||||
<HintPath>..\..\DLLs\CustomControls\bin\Debug\CustomControls.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Extensions, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\DLLs\Extensions\bin\Debug\Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
<Reference Include="SystemManagement">
|
||||
<HintPath>..\..\DLLs\SystemManagement\bin\Debug\SystemManagement.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Win32API">
|
||||
<HintPath>..\..\DLLs\Win32API\bin\Debug\Win32API.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Enum.cs" />
|
||||
<Compile Include="Models.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="StructureCheck.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
||||
36
Models/Properties/AssemblyInfo.cs
Normal file
36
Models/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// Allgemeine Informationen über eine Assembly werden über die folgenden
|
||||
// Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern,
|
||||
// die einer Assembly zugeordnet sind.
|
||||
[assembly: AssemblyTitle("Models")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("Models")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2021")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Durch Festlegen von ComVisible auf FALSE werden die Typen in dieser Assembly
|
||||
// für COM-Komponenten unsichtbar. Wenn Sie auf einen Typ in dieser Assembly von
|
||||
// COM aus zugreifen müssen, sollten Sie das ComVisible-Attribut für diesen Typ auf "True" festlegen.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// Die folgende GUID bestimmt die ID der Typbibliothek, wenn dieses Projekt für COM verfügbar gemacht wird
|
||||
[assembly: Guid("04dde1a2-453d-4717-9221-5b9c5a49f010")]
|
||||
|
||||
// Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten:
|
||||
//
|
||||
// Hauptversion
|
||||
// Nebenversion
|
||||
// Buildnummer
|
||||
// Revision
|
||||
//
|
||||
// Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden,
|
||||
// indem Sie "*" wie unten gezeigt eingeben:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
70
Models/StructureCheck.cs
Normal file
70
Models/StructureCheck.cs
Normal file
@@ -0,0 +1,70 @@
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace Models
|
||||
{
|
||||
public class Compare
|
||||
{
|
||||
/// <summary>
|
||||
/// Vergleicht die JSON-Datei-Struktur mit dem Vorlagen-Model
|
||||
/// </summary>
|
||||
/// <returns>Gibt die fehlenden Eigenschaften aus</returns>
|
||||
public static IEnumerable<JsonPropertyAttribute> Structure<T>(string filepath)
|
||||
{
|
||||
foreach (var property in typeof(T).GetProperties())
|
||||
{
|
||||
if (!Exists(filepath, property.GetPropertyAttribute<JsonPropertyAttribute>().PropertyName))
|
||||
{
|
||||
yield return property.GetPropertyAttribute<JsonPropertyAttribute>();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Vergleicht die JSON-Datei-Struktur mit dem Vorlagen-Model
|
||||
/// </summary>
|
||||
/// <returns>Gibt die fehlenden Eigenschaften aus</returns>
|
||||
public static IEnumerable<JsonPropertyAttribute> StructurePrevalence(string filepath)
|
||||
{
|
||||
foreach (var property in new AppList<App>().GetType().GetProperties())
|
||||
{
|
||||
if (!Exists(filepath, property.GetPropertyAttribute<JsonPropertyAttribute>().PropertyName))
|
||||
{
|
||||
yield return property.GetPropertyAttribute<JsonPropertyAttribute>();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Vergleicht die JSON-Datei-Struktur mit dem Vorlagen-Model
|
||||
/// </summary>
|
||||
/// <returns>Gibt die fehlenden Eigenschaften aus</returns>
|
||||
public static IEnumerable<string> StructureUserConfig(string filepath)
|
||||
{
|
||||
foreach (var property in new Config.User().GetType().GetProperties())
|
||||
{
|
||||
if (!Exists(filepath, property.GetPropertyAttribute<JsonPropertyAttribute>().PropertyName))
|
||||
{
|
||||
yield return property.GetPropertyAttribute<JsonPropertyAttribute>().PropertyName;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private static bool Exists(string path, string propertyname)
|
||||
{
|
||||
dynamic jsonobject = JsonConvert.DeserializeObject(string.Concat(JObject.Parse(File.ReadAllText(path))), new JsonSerializerSettings() { NullValueHandling = NullValueHandling.Include, Formatting = Formatting.Indented });
|
||||
return jsonobject.ContainsKey(propertyname);
|
||||
}
|
||||
}
|
||||
}
|
||||
BIN
Models/bin/Debug/CustomControls.dll
Normal file
BIN
Models/bin/Debug/CustomControls.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/CustomControls.pdb
Normal file
BIN
Models/bin/Debug/CustomControls.pdb
Normal file
Binary file not shown.
BIN
Models/bin/Debug/CustomGraphics.dll
Normal file
BIN
Models/bin/Debug/CustomGraphics.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/CustomGraphics.pdb
Normal file
BIN
Models/bin/Debug/CustomGraphics.pdb
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Extensions.dll
Normal file
BIN
Models/bin/Debug/Extensions.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Extensions.pdb
Normal file
BIN
Models/bin/Debug/Extensions.pdb
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Models.dll
Normal file
BIN
Models/bin/Debug/Models.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Models.pdb
Normal file
BIN
Models/bin/Debug/Models.pdb
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Newtonsoft.Json.dll
Normal file
BIN
Models/bin/Debug/Newtonsoft.Json.dll
Normal file
Binary file not shown.
11305
Models/bin/Debug/Newtonsoft.Json.xml
Normal file
11305
Models/bin/Debug/Newtonsoft.Json.xml
Normal file
File diff suppressed because it is too large
Load Diff
BIN
Models/bin/Debug/SystemManagement.dll
Normal file
BIN
Models/bin/Debug/SystemManagement.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/SystemManagement.pdb
Normal file
BIN
Models/bin/Debug/SystemManagement.pdb
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Win32API.dll
Normal file
BIN
Models/bin/Debug/Win32API.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/Win32API.pdb
Normal file
BIN
Models/bin/Debug/Win32API.pdb
Normal file
Binary file not shown.
BIN
Models/bin/Debug/XObjects.dll
Normal file
BIN
Models/bin/Debug/XObjects.dll
Normal file
Binary file not shown.
BIN
Models/bin/Debug/XObjects.pdb
Normal file
BIN
Models/bin/Debug/XObjects.pdb
Normal file
Binary file not shown.
@@ -0,0 +1,4 @@
|
||||
// <autogenerated />
|
||||
using System;
|
||||
using System.Reflection;
|
||||
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
|
||||
BIN
Models/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache
Normal file
BIN
Models/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache
Normal file
Binary file not shown.
BIN
Models/obj/Debug/Models.csproj.AssemblyReference.cache
Normal file
BIN
Models/obj/Debug/Models.csproj.AssemblyReference.cache
Normal file
Binary file not shown.
0
Models/obj/Debug/Models.csproj.CopyComplete
Normal file
0
Models/obj/Debug/Models.csproj.CopyComplete
Normal file
1
Models/obj/Debug/Models.csproj.CoreCompileInputs.cache
Normal file
1
Models/obj/Debug/Models.csproj.CoreCompileInputs.cache
Normal file
@@ -0,0 +1 @@
|
||||
36c636c7f289954fe33825e6d1befa138661f2c1
|
||||
21
Models/obj/Debug/Models.csproj.FileListAbsolute.txt
Normal file
21
Models/obj/Debug/Models.csproj.FileListAbsolute.txt
Normal file
@@ -0,0 +1,21 @@
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Models.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Models.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\CustomControls.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Extensions.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Newtonsoft.Json.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\SystemManagement.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Win32API.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\CustomGraphics.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\XObjects.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\CustomControls.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Extensions.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Newtonsoft.Json.xml
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\SystemManagement.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\Win32API.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\CustomGraphics.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\bin\Debug\XObjects.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\obj\Debug\Models.csproj.CoreCompileInputs.cache
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\obj\Debug\Models.csproj.CopyComplete
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\obj\Debug\Models.dll
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\obj\Debug\Models.pdb
|
||||
D:\Anwendungsentwicklung\C#\GFATask\Models\obj\Debug\Models.csproj.AssemblyReference.cache
|
||||
BIN
Models/obj/Debug/Models.dll
Normal file
BIN
Models/obj/Debug/Models.dll
Normal file
Binary file not shown.
BIN
Models/obj/Debug/Models.pdb
Normal file
BIN
Models/obj/Debug/Models.pdb
Normal file
Binary file not shown.
@@ -0,0 +1,4 @@
|
||||
// <autogenerated />
|
||||
using System;
|
||||
using System.Reflection;
|
||||
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
|
||||
BIN
Models/obj/Release/Models.csproj.AssemblyReference.cache
Normal file
BIN
Models/obj/Release/Models.csproj.AssemblyReference.cache
Normal file
Binary file not shown.
4
Models/packages.config
Normal file
4
Models/packages.config
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Newtonsoft.Json" version="13.0.1" targetFramework="net48" />
|
||||
</packages>
|
||||
Reference in New Issue
Block a user