diff --git a/IFCGeoRefCheckerCommand/IFCGeoRefCheckerCommand.csproj b/IFCGeoRefCheckerCommand/IFCGeoRefCheckerCommand.csproj new file mode 100644 index 0000000..40f26f2 --- /dev/null +++ b/IFCGeoRefCheckerCommand/IFCGeoRefCheckerCommand.csproj @@ -0,0 +1,19 @@ + + + + Exe + net6.0 + enable + enable + + + + + + + + + + + + diff --git a/IFCGeoRefCheckerCommand/Program.cs b/IFCGeoRefCheckerCommand/Program.cs new file mode 100644 index 0000000..1d05251 --- /dev/null +++ b/IFCGeoRefCheckerCommand/Program.cs @@ -0,0 +1,23 @@ +using IFCGeorefShared; +using Xbim.Ifc; + +namespace IFCGeoRefCheckerCommand +{ + internal class Program + { + static void Main(string[] args) + { + string ifcFilePath = @"D:\Testdaten\GeoRefChecker\Buerogebaeude.ifc"; + //string ifcFilePath = @"D:\Testdaten\GeoRefChecker\301110Gebaeude-Gruppe.ifc"; + + using (var model = IfcStore.Open(ifcFilePath)) + { + var checker = new GeoRefChecker(model); + + checker.WriteProtocoll(@"D:\TestDaten\GeoRefChecker\IfcGeoRefChecker"); + } + + Console.WriteLine("Check finished"); + } + } +} \ No newline at end of file diff --git a/IFCGeoRefCheckerGUI/App.xaml b/IFCGeoRefCheckerGUI/App.xaml new file mode 100644 index 0000000..63b058a --- /dev/null +++ b/IFCGeoRefCheckerGUI/App.xaml @@ -0,0 +1,9 @@ + + + + + diff --git a/IFCGeoRefCheckerGUI/App.xaml.cs b/IFCGeoRefCheckerGUI/App.xaml.cs new file mode 100644 index 0000000..eb4a190 --- /dev/null +++ b/IFCGeoRefCheckerGUI/App.xaml.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Configuration; +using System.Data; +using System.Linq; +using System.Threading.Tasks; +using System.Windows; + +namespace IFCGeoRefCheckerGUI +{ + /// + /// Interaction logic for App.xaml + /// + public partial class App : Application + { + } +} diff --git a/IFCGeoRefCheckerGUI/AssemblyInfo.cs b/IFCGeoRefCheckerGUI/AssemblyInfo.cs new file mode 100644 index 0000000..8b5504e --- /dev/null +++ b/IFCGeoRefCheckerGUI/AssemblyInfo.cs @@ -0,0 +1,10 @@ +using System.Windows; + +[assembly: ThemeInfo( + ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located + //(used if a resource is not found in the page, + // or application resource dictionaries) + ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located + //(used if a resource is not found in the page, + // app, or any theme specific resource dictionaries) +)] diff --git a/IFCGeoRefCheckerGUI/DelegateCommand.cs b/IFCGeoRefCheckerGUI/DelegateCommand.cs new file mode 100644 index 0000000..3299e8a --- /dev/null +++ b/IFCGeoRefCheckerGUI/DelegateCommand.cs @@ -0,0 +1,30 @@ +using System; +using System.Windows.Input; + +namespace IFCGeoRefCheckerGUI +{ + public class DelegateCommand : ICommand + { + readonly Action? execute; + readonly Predicate? canExecute; + + public DelegateCommand(Action? execute, Predicate? canExecute) + { + this.execute = execute; + this.canExecute = canExecute; + } + + public DelegateCommand(Action excute) : this(excute, null) { } + + public event EventHandler? CanExecuteChanged; + + public void RaiseCanExecuteChanged() => this.CanExecuteChanged?.Invoke(this, EventArgs.Empty); + + public bool CanExecute(object? parameter) => this.canExecute?.Invoke(parameter!) ?? true; + + public void Execute(object? parameter) + { + this.execute?.Invoke(parameter!); + } + } +} diff --git a/IFCGeoRefCheckerGUI/IFCGeoRefCheckerGUI.csproj b/IFCGeoRefCheckerGUI/IFCGeoRefCheckerGUI.csproj new file mode 100644 index 0000000..723556c --- /dev/null +++ b/IFCGeoRefCheckerGUI/IFCGeoRefCheckerGUI.csproj @@ -0,0 +1,34 @@ + + + + WinExe + net6.0-windows + enable + true + true + + + + + + + + + + + + + + + + PreserveNewest + + + + + + + + + + diff --git a/IFCGeoRefCheckerGUI/IfcCheckerService.cs b/IFCGeoRefCheckerGUI/IfcCheckerService.cs new file mode 100644 index 0000000..9edff63 --- /dev/null +++ b/IFCGeoRefCheckerGUI/IfcCheckerService.cs @@ -0,0 +1,25 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +using Xbim.Ifc; + +using IFCGeorefShared; + + +namespace IFCGeoRefCheckerGUI +{ + class IfcCheckerService + { + public GeoRefChecker CheckIFC(string filePath) + { + using (var model = IfcStore.Open(filePath)) + { + var checker = new GeoRefChecker(model); + return checker; + } + } + } +} diff --git a/IFCGeoRefCheckerGUI/MainWindow.xaml b/IFCGeoRefCheckerGUI/MainWindow.xaml new file mode 100644 index 0000000..86bef4b --- /dev/null +++ b/IFCGeoRefCheckerGUI/MainWindow.xaml @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/IFCGeoRefCheckerGUI/MainWindow.xaml.cs b/IFCGeoRefCheckerGUI/MainWindow.xaml.cs new file mode 100644 index 0000000..ab19f2b --- /dev/null +++ b/IFCGeoRefCheckerGUI/MainWindow.xaml.cs @@ -0,0 +1,29 @@ +using IFCGeoRefCheckerGUI.ViewModels; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace IFCGeoRefCheckerGUI +{ + /// + /// Interaction logic for MainWindow.xaml + /// + public partial class MainWindow : Window + { + public MainWindow() + { + InitializeComponent(); + } + } +} diff --git a/IFCGeoRefCheckerGUI/MainWindowAllInOne.xaml b/IFCGeoRefCheckerGUI/MainWindowAllInOne.xaml new file mode 100644 index 0000000..241372d --- /dev/null +++ b/IFCGeoRefCheckerGUI/MainWindowAllInOne.xaml @@ -0,0 +1,151 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +