diff --git a/GUIs.ClipboardWatcher/ClipboardWatcher.vbproj.bak b/GUIs.ClipboardWatcher/ClipboardWatcher.vbproj.bak
deleted file mode 100644
index 079ef485..00000000
--- a/GUIs.ClipboardWatcher/ClipboardWatcher.vbproj.bak
+++ /dev/null
@@ -1,211 +0,0 @@
-
-
-
-
- Debug
- AnyCPU
- {B7D465A2-AE31-4CDF-A8B2-34B42D3EA84E}
- Library
- DigitalData.GUIs.ClipboardWatcher
- DigitalData.GUIs.ClipboardWatcher
- 512
- Windows
- v4.6.1
-
-
- true
- full
- true
- true
- bin\Debug\
- DigitalData.GUIs.ClipboardWatcher.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
-
-
- pdbonly
- false
- true
- true
- bin\Release\
- DigitalData.GUIs.ClipboardWatcher.xml
- 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022
-
-
- On
-
-
- Binary
-
-
- Off
-
-
- On
-
-
-
- False
-
-
-
- False
-
-
-
- False
-
-
- False
- ..\Modules.EDMIAPI\bin\Debug\DigitalData.Modules.EDMI.API.dll
-
-
-
- ..\packages\NLog.4.7.10\lib\net45\NLog.dll
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- frmMatch.vb
-
-
- Form
-
-
- frmTreeView.vb
-
-
- Form
-
-
-
- True
- Application.myapp
-
-
- True
- True
- Resources.resx
-
-
- True
- Settings.settings
- True
-
-
-
-
-
-
- frmMatchLoading.vb
-
-
- Form
-
-
-
-
- frmMatch.vb
-
-
- frmMatch.vb
-
-
- frmMatch.vb
-
-
- frmMatchLoading.vb
-
-
- frmMatchLoading.vb
-
-
- frmTreeView.vb
-
-
- frmTreeView.vb
-
-
-
- VbMyResourcesResXFileCodeGenerator
- Resources.Designer.vb
- My.Resources
- Designer
-
-
- frmMatchLoading.vb
-
-
-
-
-
- MyApplicationCodeGenerator
- Application.Designer.vb
-
-
- SettingsSingleFileGenerator
- My
- Settings.Designer.vb
-
-
-
-
-
- {D20A6BF2-C7C6-4A7A-B34D-FA27D775A049}
- Common
-
-
- {EAF0EA75-5FA7-485D-89C7-B2D843B03A96}
- Database
-
-
- {25017513-0d97-49d3-98d7-ba76d9b251b0}
- EDMI.API
-
-
- {d3c8cfed-d6f6-43a8-9bdf-454145d0352f}
- Language
-
-
- {903b2d7d-3b80-4be9-8713-7447b704e1b0}
- Logging
-
-
- {7c3b0c7e-59fe-4e1a-a655-27ae119f9444}
- Patterns
-
-
- {81cac44f-3711-4c8f-ae98-e02a7448782a}
- ZooFlow
-
-
- {5efaef9b-90b9-4f05-9f70-f79ad77fff86}
- Windows
-
-
-
-
\ No newline at end of file
diff --git a/GUIs.ClipboardWatcher/My Project/licenses.licx b/GUIs.ClipboardWatcher/My Project/licenses.licx
index e69de29b..f44a7f5f 100644
--- a/GUIs.ClipboardWatcher/My Project/licenses.licx
+++ b/GUIs.ClipboardWatcher/My Project/licenses.licx
@@ -0,0 +1 @@
+DevExpress.XtraEditors.TileControl, DevExpress.XtraEditors.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
diff --git a/GUIs.ClipboardWatcher/frmMatch.resx.bak b/GUIs.ClipboardWatcher/frmMatch.resx.bak
deleted file mode 100644
index 652f24a7..00000000
--- a/GUIs.ClipboardWatcher/frmMatch.resx.bak
+++ /dev/null
@@ -1,270 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- 2
-
-
-
- 0
-
-
-
- 6, 13
-
-
- $this
-
-
- 0, 420
-
-
- Label1
-
-
- DevExpress.XtraEditors.TileControl, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- 800, 30
-
-
- SplashScreenManager1
-
-
- 800, 38
-
-
- DevExpress.XtraEditors.XtraForm, DevExpress.Utils.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- Segoe UI, 12pt
-
-
- 0, 0
-
-
- TileControl1
-
-
-
- Fill
-
-
- Daten
-
-
- Top
-
-
- System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- 0, 38
-
-
- 800, 450
-
-
- 5, 5, 5, 5
-
-
- $this
-
-
- Label2
-
-
- DevExpress.XtraEditors.TileGroup, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- Segoe UI, 9.75pt
-
-
- Segoe UI Semibold, 12pt, style=Bold
-
-
- TileGroupDocumentsData
-
-
- Wie wurden die Profile gefunden?
-
-
- frmMatch
-
-
- System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- DevExpress.XtraSplashScreen.SplashScreenManager, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- Es wurde(n) {0} in {1} für Ihre Suche nach '{2}' gefunden:
-
-
- TileGroupDocuments
-
-
- 3
-
-
- Dokumente
-
-
- 800, 382
-
-
- $this
-
-
- 5, 5, 5, 5
-
-
- TileControlMatch
-
-
- 1
-
-
- 0
-
-
- TileGroupData
-
-
- Kombiniert
-
-
- DevExpress.XtraEditors.TileGroup, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- 1
-
-
- Clipboard Watcher - Profile gefunden
-
-
- Bottom
-
-
- DevExpress.XtraEditors.TileGroup, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- True
-
-
\ No newline at end of file
diff --git a/GUIs.ClipboardWatcher/frmMatch.vb b/GUIs.ClipboardWatcher/frmMatch.vb
index ae1b6a73..6105a9b8 100644
--- a/GUIs.ClipboardWatcher/frmMatch.vb
+++ b/GUIs.ClipboardWatcher/frmMatch.vb
@@ -27,18 +27,18 @@ Imports System.Globalization
''' - Clipboard Content as String
'''
Public Class frmMatch
- Private _LogConfig As LogConfig
- Private _Logger As Logger
- Private _Environment As Environment
- Private _Params As ClipboardWatcherParams
- Private _Language As String
+ Private ReadOnly _LogConfig As LogConfig
+ Private ReadOnly _Logger As Logger
+ Private ReadOnly _Environment As Environment
+ Private ReadOnly _Params As ClipboardWatcherParams
+ Private ReadOnly _Language As String
- Private PrimaryFont As New Font("Segoe UI", 12, FontStyle.Bold)
- Private SecondaryFont As New Font("Segoe UI", 10)
- Private TileForeColor As Color = Color.Black
- Private TileBackColor As Color = Color.FromArgb(255, 214, 47)
+ Private ReadOnly PrimaryFont As New Font("Segoe UI", 12, FontStyle.Bold)
+ Private ReadOnly SecondaryFont As New Font("Segoe UI", 10)
+ Private ReadOnly TileForeColor As Color = Color.Black
+ Private ReadOnly TileBackColor As Color = Color.FromArgb(255, 214, 47)
- Private OpenForms As New List(Of IResultForm)
+ Private ReadOnly OpenForms As New List(Of IResultForm)
Private ShouldHideInitially As Boolean = False
Private Const NO_COUNT_SQL As Integer = 99998
@@ -60,7 +60,7 @@ Public Class frmMatch
_Environment = Environment
_Params = Params
- _Language = Language.Utils.NotNull(_Environment.User.Language, State.UserState.LANG_EN_US)
+ _Language = Utils.NotNull(_Environment.User.Language, State.UserState.LANG_EN_US)
Thread.CurrentThread.CurrentUICulture = New CultureInfo(_Language)
End Sub
@@ -144,13 +144,16 @@ Public Class frmMatch
OpenDocumentResults(oProfile, oSearches)
_Logger.Debug($"OpenDocumentResults finished")
Hide()
+
ElseIf oProfile.CountDocs > 0 And oProfile.CountData > 0 Then
_Logger.Debug($"Docs AND Data")
+
ElseIf oProfile.CountDocs = 0 And oProfile.CountData > 0 Then
_Logger.Debug($"ONLY Data")
Dim oSearches = Await oProfileSearch.LoadDataSearchesAsync(oProfile.Guid)
OpenDataResults(oProfile, oSearches)
Hide()
+
End If
End If
Catch ex As Exception
diff --git a/GUIs.ClipboardWatcher/frmMatchLoading.resx.bak b/GUIs.ClipboardWatcher/frmMatchLoading.resx.bak
deleted file mode 100644
index fcdedd5f..00000000
--- a/GUIs.ClipboardWatcher/frmMatchLoading.resx.bak
+++ /dev/null
@@ -1,237 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- tableLayoutPanel1
-
-
-
- 0, 14, 0, 14
-
-
-
- True
-
-
- GrowAndShrink
-
-
-
- 6, 13
-
-
- 246, 39
-
-
- progressPanel1
-
-
- Form1
-
-
- DevExpress.XtraWaitForm.WaitForm, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- 246, 73
-
-
- frmMatchLoading
-
-
- 1
-
-
- 0, 3, 0, 3
-
-
- Fill
-
-
- 1
-
-
- <?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="progressPanel1" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /></Controls><Columns Styles="Percent,100" /><Rows Styles="Percent,100" /></TableLayoutSettings>
-
-
- $this
-
-
- 246, 73
-
-
- Manual
-
-
- 0, 17
-
-
- Bitte warten
-
-
- 0, 0
-
-
- True
-
-
- GrowAndShrink
-
-
- progressPanel1
-
-
- 0
-
-
- 0
-
-
- 0
-
-
- Ergebnisse werden geladen...
-
-
- DevExpress.XtraWaitForm.ProgressPanel, DevExpress.XtraEditors.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- Microsoft Sans Serif, 8.25pt
-
-
- System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- Fill
-
-
- 1
-
-
- Microsoft Sans Serif, 12pt
-
-
- tableLayoutPanel1
-
-
- True
-
-
- fr-FR
-
-
\ No newline at end of file
diff --git a/GUIs.ClipboardWatcher/frmTreeView.resx.bak b/GUIs.ClipboardWatcher/frmTreeView.resx.bak
deleted file mode 100644
index 84d515f4..00000000
--- a/GUIs.ClipboardWatcher/frmTreeView.resx.bak
+++ /dev/null
@@ -1,275 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- text/microsoft-resx
-
-
- 2.0
-
-
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
-
- 800, 450
-
-
-
- 0
-
-
- $this
-
-
- System.Windows.Forms.TreeView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- DevExpress.XtraEditors.XtraForm, DevExpress.Utils.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
-
-
- 800, 450
-
-
- 0
-
-
- 6, 13
-
-
- ImageList1
-
-
- tvProfileMatch
-
-
- Profilsuchen Algorithmus
-
-
- 0
-
-
- 0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AAQEGAAEBFgAD/wEAAf8BgQL/
- BgABgAEBBAABfwEAAfcB7wQAAX8BAAH3Ae8EAAF/AoABAQQAAX8BwgH3Ae8EAAF/Af4B9wHvBAABfwH+
- AYABAQQAAX8B/gH3Ae8EAAF/Af4B9wHvBQABAgGAAQEFAAECAYABAQUAAQIBgAEBBAABwAEAAYABAQQA
- AcABAAL/BAABwAEAAv8EAAT/Af4BAAH+AT8B4AEDAv8B/gEAAf4BPwH/AfsBwAEBAeABAAHAAQMB/AEb
- AcABAQHgAQABwAEDAfwBGwHAAQEB4AEAAcABAwH8ARsBwAEBAeABAAHgAQMB/AEbAcABAQHgAQABgwHA
- AY8B+QHBAYEB4AEAAYMBwAGHAfEBwQGBAeABAAGDAcABwwHjAcABAQHgAQAB4QHDAeEBxwHAAQEB4AEA
- AeABAwHwAYcBwAEBAe8B9wHAAQMB+AEHAfsB3wHoAQcBwAEDAfwBJwH4AR8B/gG/AeYBIwH+AX8E/wH+
- AT8I/xYACw==
-
-
-
-
- Fill
-
-
- System.Windows.Forms.ImageList, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- frmTreeView
-
-
- fr-FR
-
-
- True
-
-
- 17, 17
-
-
\ No newline at end of file
diff --git a/GUIs.Common/Common.vbproj b/GUIs.Common/Common.vbproj
index e4ccd8e6..2c711bad 100644
--- a/GUIs.Common/Common.vbproj
+++ b/GUIs.Common/Common.vbproj
@@ -118,6 +118,7 @@
+
diff --git a/GUIs.Common/DataResultList/frmDataResultList.vb b/GUIs.Common/DataResultList/frmDataResultList.vb
index 1f5ecdc0..a1a54684 100644
--- a/GUIs.Common/DataResultList/frmDataResultList.vb
+++ b/GUIs.Common/DataResultList/frmDataResultList.vb
@@ -30,7 +30,7 @@ Public Class frmDataResultList
Public Property ShouldReturnToPreviousForm As Boolean Implements IResultForm.ShouldReturnToPreviousForm
- Private Property OperationMode As IResultForm.Mode Implements IResultForm.OperationMode
+ Private Property OperationMode As Helpers.OperationMode Implements IResultForm.OperationMode
Public Sub New(LogConfig As LogConfig, Environment As Environment, Params As DataResultParams)
' Dieser Aufruf ist für den Designer erforderlich.
diff --git a/GUIs.Common/DocumentResultList/DocumentResultParams.vb b/GUIs.Common/DocumentResultList/DocumentResultParams.vb
index b383c86c..5d1e5679 100644
--- a/GUIs.Common/DocumentResultList/DocumentResultParams.vb
+++ b/GUIs.Common/DocumentResultList/DocumentResultParams.vb
@@ -1,4 +1,6 @@
-Public Class DocumentResultParams
+Imports DigitalData.GUIs.Common.Helpers
+
+Public Class DocumentResultParams
'''
''' WindowGuid is used to save layout data
'''
@@ -6,6 +8,7 @@
Public WindowTitle As String = ""
Public Results As New List(Of DocumentResult)
Public ColumnNames As New ColumnNames
+ Public OperationModeOverride As OperationMode = OperationMode.None
End Class
Public Class DocumentResult
@@ -16,4 +19,5 @@ Public Class ColumnNames
Public ObjectIdColumn As String = "DocId"
Public FullPathColumn As String = "FULL_FILENAME"
Public FilenameColumn As String = "Name"
+ Public IconColumn As String = "ICON"
End Class
diff --git a/GUIs.Common/DocumentResultList/frmDocumentResultList.vb b/GUIs.Common/DocumentResultList/frmDocumentResultList.vb
index 85b7c3dc..2e61de82 100644
--- a/GUIs.Common/DocumentResultList/frmDocumentResultList.vb
+++ b/GUIs.Common/DocumentResultList/frmDocumentResultList.vb
@@ -7,7 +7,6 @@ Imports DevExpress.XtraBars
Imports DevExpress.XtraEditors
Imports DevExpress.XtraGrid
Imports DevExpress.XtraGrid.Columns
-Imports DevExpress.XtraGrid.Menu
Imports DevExpress.XtraGrid.Views.BandedGrid
Imports DevExpress.XtraGrid.Views.Base
Imports DevExpress.XtraGrid.Views.Grid
@@ -16,21 +15,20 @@ Imports DevExpress.XtraPrinting
Imports DigitalData.Modules.Config
Imports DigitalData.Modules.EDMI.API
Imports DigitalData.Modules.EDMI.API.Client
+Imports DigitalData.Modules.EDMI.API.EDMIServiceReference
Imports DigitalData.Modules.Language
Imports DigitalData.Modules.Logging
Imports DigitalData.Modules.ZooFlow
-Imports DigitalData.Modules.Windows
-Imports DigitalData.Modules.Filesystem
Public Class frmDocumentResultList
Implements IResultForm
' These are NOT constants, only defaults
' Can be changed when calling frmDocumentResultList
- Private COLUMN_FILEPATH As String = "FULL_FILENAME"
- Private COLUMN_FILENAME As String = "Filename"
- Private COLUMN_DOCID As String = "DocID"
- Private COLUMN_ICON As String = "ICON"
+ Private ReadOnly COLUMN_FILEPATH As String = "FULL_FILENAME"
+ Private ReadOnly COLUMN_FILENAME As String = "Filename"
+ Private ReadOnly COLUMN_DOCID As String = "DocID"
+ Private ReadOnly COLUMN_ICON As String = "ICON"
' Constants
Private Const OPEN_FILE As String = "Datei öffnen"
@@ -43,16 +41,17 @@ Public Class frmDocumentResultList
' Helper Classes
Private _IDBClient As Client
- Private _LogConfig As LogConfig
- Private _Logger As Logger
- Private _Config As ConfigManager(Of DocumentResultConfig)
- Private _Environment As Environment
- Private _Params As DocumentResultParams
- Private _ResultLists As List(Of DocumentResult)
- Private _Helpers As DocumentResultList
- Private _Filesystem As Modules.Filesystem.File
- Private _GridBuilder As GridBuilder
- Private _File As Modules.Windows.File
+ Private ReadOnly _LogConfig As LogConfig
+ Private ReadOnly _Logger As Logger
+ Private ReadOnly _Config As ConfigManager(Of DocumentResultConfig)
+ Private ReadOnly _Environment As Environment
+ Private ReadOnly _Params As DocumentResultParams
+ Private ReadOnly _ResultLists As List(Of DocumentResult)
+ Private ReadOnly _Helpers As DocumentResultList
+ Private ReadOnly _Filesystem As Modules.Filesystem.File
+ Private ReadOnly _GridBuilder As GridBuilder
+ Private ReadOnly _File As Modules.Windows.File
+ Private ReadOnly _OpenDocuments As New DocumentResultCache(50000000)
' Runtime variables
Private _IsLoading As Boolean = True
@@ -63,13 +62,13 @@ Public Class frmDocumentResultList
'Private _HashOriginalFile As String = Nothing
'Private _HashOpenedFile As String = Nothing
- Private WithEvents _FileOpenTimer As New Timer
- Private _OpenDocuments As New DocumentResultCache(50000000)
Private _CurrentDocument As DocumentResultInfo = Nothing
Private _CurrentDocumentId As Long = Nothing
- Private _Language As String
+ Private ReadOnly _Language As String
- Private Property OperationMode As IResultForm.Mode Implements IResultForm.OperationMode
+ Private WithEvents _FileOpenTimer As New Timer
+
+ Private Property OperationMode As Helpers.OperationMode Implements IResultForm.OperationMode
Public Property ShouldReturnToPreviousForm As Boolean = False Implements IResultForm.ShouldReturnToPreviousForm
@@ -83,6 +82,7 @@ Public Class frmDocumentResultList
COLUMN_DOCID = Params.ColumnNames.ObjectIdColumn
COLUMN_FILENAME = Params.ColumnNames.FilenameColumn
COLUMN_FILEPATH = Params.ColumnNames.FullPathColumn
+ COLUMN_ICON = Params.ColumnNames.IconColumn
_LogConfig = LogConfig
_Logger = LogConfig.GetLogger()
@@ -97,15 +97,28 @@ Public Class frmDocumentResultList
_Language = Utils.NotNull(_Environment.User.Language, State.UserState.LANG_EN_US)
End Sub
+ Private Function GetOperationMode() As Helpers.OperationMode
+ Dim oOperationMode = OperationMode.None
+
+ If _Environment.Service.IsActive AndAlso _Environment.Service.Address <> String.Empty Then
+ oOperationMode = Helpers.OperationMode.WithAppServer
+ Else
+ oOperationMode = Helpers.OperationMode.NoAppServer
+ End If
+
+ If _Params.OperationModeOverride <> Helpers.OperationMode.None Then
+ oOperationMode = _Params.OperationModeOverride
+ End If
+
+ Return oOperationMode
+ End Function
+
Private Sub frmDocumentResultList_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Try
- If _Environment.Service.IsActive AndAlso _Environment.Service.Address <> String.Empty Then
- OperationMode = IResultForm.Mode.WithAppServer
- Else
- OperationMode = IResultForm.Mode.NoAppServer
- End If
-
- If OperationMode = IResultForm.Mode.WithAppServer Then
+ ' Operation mode is either guessed from service settings
+ ' or explictly set from OperationModeOverride in Params
+ OperationMode = GetOperationMode()
+ If OperationMode = Helpers.OperationMode.WithAppServer Then
InitAppServer()
End If
@@ -125,7 +138,7 @@ Public Class frmDocumentResultList
SplitContainerControl2.SplitterPosition = _Config.Config.SplitContainer2Distance
SwitchDetailContainerHorizontal.Checked = _Config.Config.SplitContainer2Horizontal
- If OperationMode <> IResultForm.Mode.NoAppServer Then
+ If OperationMode <> Helpers.OperationMode.NoAppServer Then
' Location and size will be managed by the ZooFlow Search Window
If Utils.IsVisibleOnAnyScreen(_Config.Config.WindowLocation) Then
If Utils.LocationIsVisible(_Config.Config.WindowLocation) Then
@@ -136,8 +149,8 @@ Public Class frmDocumentResultList
End If
End If
- SwitchMainContainerHorizontal.Visibility = DevExpress.XtraBars.BarItemVisibility.Never
- SwitchDetailContainerHorizontal.Visibility = DevExpress.XtraBars.BarItemVisibility.Never
+ SwitchMainContainerHorizontal.Visibility = BarItemVisibility.Never
+ SwitchDetailContainerHorizontal.Visibility = BarItemVisibility.Never
End If
_GridBuilder.
@@ -171,11 +184,33 @@ Public Class frmDocumentResultList
DocumentViewer1.CloseDocument()
- If OperationMode = IResultForm.Mode.NoAppServer Then
- oDocumentInfo = LoadFile_Legacy(oRow)
- ElseIf OperationMode = IResultForm.Mode.WithAppServer Then
- oDocumentInfo = LoadFile_IDB(oRow)
- End If
+ Select Case OperationMode
+ Case Helpers.OperationMode.NoAppServer
+ oDocumentInfo = LoadFile_Legacy(oRow)
+
+ If oDocumentInfo.Contents IsNot Nothing Then
+ Dim oFileInfo As New FileInfo(oDocumentInfo.FullPath)
+ DocumentViewer1.LoadFile(oFileInfo.Name, New MemoryStream(oDocumentInfo.Contents))
+ Else
+ DocumentViewer1.LoadFile(oDocumentInfo.FullPath)
+ End If
+
+ Case Helpers.OperationMode.WithAppServer
+ oDocumentInfo = LoadFile_IDB(oRow)
+
+ If oDocumentInfo.Contents IsNot Nothing Then
+ Dim oFileInfo As New FileInfo(oDocumentInfo.FullPath)
+ DocumentViewer1.LoadFile(oFileInfo.Name, New MemoryStream(oDocumentInfo.Contents))
+ Else
+ DocumentViewer1.LoadFile(oDocumentInfo.FullPath)
+ End If
+
+
+ Case Helpers.OperationMode.ZooFlow
+ oDocumentInfo = LoadFile_ZooFlow(oRow)
+
+
+ End Select
If IsNothing(oDocumentInfo) Then
Show_Warning("File could not be loaded!")
@@ -191,7 +226,6 @@ Public Class frmDocumentResultList
If oDocumentInfo.Contents IsNot Nothing Then
Dim oFileInfo As New FileInfo(oDocumentInfo.FullPath)
-
DocumentViewer1.LoadFile(oFileInfo.Name, New MemoryStream(oDocumentInfo.Contents))
Else
DocumentViewer1.LoadFile(oDocumentInfo.FullPath)
@@ -281,6 +315,27 @@ Public Class frmDocumentResultList
End Try
End Function
+ Private Function LoadFile_ZooFlow(GridRow As DataRow)
+ Try
+ Dim oObjectId = GridRow.Item(COLUMN_DOCID)
+ _Logger.Debug("Loading FileObject for ObjectId: [{0}]", oObjectId)
+
+ ' This needs to be Sync bc otherwise the PopupMenuShowing event will fire before this method loaded the FileObject
+ Dim oFileObject As FileObject = _IDBClient.GetFileObject(oObjectId)
+ Dim oResultDocumentInfo As New DocumentResultInfo() With {
+ .AccessRight = "",
+ .FullPath = "",
+ .Contents = oFileObject._FileContents
+ }
+ _Logger.Debug("Successfully loaded Information for ObjectId: [{0}]", oObjectId)
+
+ Catch ex As Exception
+ _Logger.Error(ex)
+ Return Nothing
+
+ End Try
+ End Function
+
Private Function LoadFile_AsByteArray(DocumentInfo As DocumentResultInfo) As DocumentResultInfo
Try
_Logger.Debug("Loading File [{0}]", DocumentInfo.FullPath)
@@ -380,7 +435,7 @@ Public Class frmDocumentResultList
Throw New ApplicationException($"Datatable is missing DocId Column [{COLUMN_DOCID}] for search {Result.Title}!")
End If
- If OperationMode = IResultForm.Mode.NoAppServer And Result.Datatable.Columns.Contains(COLUMN_FILEPATH) = False Then
+ If OperationMode = Helpers.OperationMode.NoAppServer And Result.Datatable.Columns.Contains(COLUMN_FILEPATH) = False Then
Throw New ApplicationException($"Datatable is missing Filepath Column [{COLUMN_FILEPATH}] for search {Result.Title}!")
End If
@@ -516,7 +571,7 @@ Public Class frmDocumentResultList
oFilePathColumn.Visible = False
' Hide Fullpath column completely in AppServer-Mode
- If OperationMode = IResultForm.Mode.WithAppServer Then
+ If OperationMode = Helpers.OperationMode.WithAppServer Then
oFilePathColumn.OptionsColumn.ShowInCustomizationForm = False
End If
End If
@@ -877,7 +932,7 @@ Public Class frmDocumentResultList
_CurrentDocumentId = oObjectId
- If OperationMode = IResultForm.Mode.WithAppServer Then
+ If OperationMode = Helpers.OperationMode.WithAppServer Then
If oRight = Rights.AccessRight.FULL Or oRight = Rights.AccessRight.VIEW_EXPORT Then
MenuFullAccess_IDB.ShowPopup(oPoint)
Else
diff --git a/GUIs.Common/Helpers.vb b/GUIs.Common/Helpers.vb
new file mode 100644
index 00000000..41ccd0a9
--- /dev/null
+++ b/GUIs.Common/Helpers.vb
@@ -0,0 +1,8 @@
+Public Class Helpers
+ Public Enum OperationMode
+ WithAppServer
+ NoAppServer
+ ZooFlow
+ None
+ End Enum
+End Class
diff --git a/GUIs.Common/IResultForm.vb b/GUIs.Common/IResultForm.vb
index 896ff0d4..1614fd56 100644
--- a/GUIs.Common/IResultForm.vb
+++ b/GUIs.Common/IResultForm.vb
@@ -1,10 +1,7 @@
-Public Interface IResultForm
- Enum Mode
- WithAppServer
- NoAppServer
- End Enum
+Imports DigitalData.GUIs.Common.Helpers
- Property OperationMode As Mode
+Public Interface IResultForm
+ Property OperationMode As OperationMode
Property ShouldReturnToPreviousForm As Boolean
Function RefreshResults(pResults As IEnumerable(Of BaseResult)) As Boolean
diff --git a/GUIs.Common/My Project/licenses.licx b/GUIs.Common/My Project/licenses.licx
index e69de29b..a42d698e 100644
--- a/GUIs.Common/My Project/licenses.licx
+++ b/GUIs.Common/My Project/licenses.licx
@@ -0,0 +1,3 @@
+DevExpress.XtraEditors.Repository.RepositoryItemTextEdit, DevExpress.XtraEditors.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
+DevExpress.XtraGrid.GridControl, DevExpress.XtraGrid.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
+DevExpress.XtraBars.Ribbon.RibbonControl, DevExpress.XtraBars.v21.2, Version=21.2.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
diff --git a/GUIs.ZooFlow/Globix/ClassEmailHeaderExtractor.vb b/GUIs.ZooFlow/Globix/ClassEmailHeaderExtractor.vb
deleted file mode 100644
index 40199418..00000000
--- a/GUIs.ZooFlow/Globix/ClassEmailHeaderExtractor.vb
+++ /dev/null
@@ -1,112 +0,0 @@
-Imports Independentsoft
-Imports System.Text.RegularExpressions
-
-Public Class ClassEmailHeaderExtractor
- '''
- ''' Extrahiert die Headerinformationen aus einer .msg Datei mithilfe der MSG.NET Klasse
- '''
- ''' Der Pfad einer .msg Datei
- ''' Headerinformationen als String oder Nothing wenn ein Fehler aufgetreten ist.
- Public Shared Function getMessageHeaders(path As String) As String
- Try
- Dim msg As New Msg.Message(path)
- Dim headers = msg.TransportMessageHeaders.Replace(vbCrLf, " ")
- Return headers
- Catch ex As Exception
- Return Nothing
- End Try
- End Function
-
- '''
- ''' Extrahiert die Headerinformationen aus einem msg Objekt mithilfe der MSG.NET Klasse
- '''
- ''' Eine Email vom Typ Msg.Message
- ''' Headerinformationen als String oder Nothing wenn ein Fehler aufgetreten ist.
- Public Shared Function getMessageHeaders(msg As Msg.Message) As String
- Try
- Dim headers = msg.TransportMessageHeaders.Replace(vbCrLf, " ")
- Return headers
- Catch ex As Exception
- Return Nothing
- End Try
- End Function
-
- '''
- ''' Extrahiert aus den Headerinformationen anhand einer Liste von Regular Expressions eine Absenderadresse.
- '''
- ''' Headerinformationen die von getMessageHeaders erzeugt wurden.
- ''' Eine Liste von Regular Expressions
- ''' Die Ergebnisgruppe, die die Adresse enthält
- ''' Eine Emailadresse oder Nothing, wenn keine der Regular Expressions ein Ergebnis lieferte.
- Public Shared Function extractFromAddress(messageHeaders As String, RegexList As List(Of Regex), Optional RegexGroup As Integer = 1) As String
- If IsNothing(messageHeaders) Then
- Return Nothing
- End If
-
- For Each rx In RegexList
- Dim match As Match = rx.Match(messageHeaders)
- Dim email As String = match.Groups(RegexGroup).Value
-
- If Not String.IsNullOrWhiteSpace(email) Then
- Return email
- End If
- Next
-
- Return Nothing
- End Function
- Public Shared Function extractFromHeader(messageHeaders As String, Regex As String) As String
- Try
- Dim result As String = ""
- Dim i As Integer = 0
- If IsNothing(messageHeaders) Then
- Return Nothing
- End If
- ' einen Regulären Ausdruck laden
- Dim strRegex As String = Regex
- Dim myRegex As New Regex(strRegex, RegexOptions.IgnorePatternWhitespace)
- Dim strTargetString As String = messageHeaders.Trim
- ' die Vorkommen im String auslesen
- For Each myMatch As Match In myRegex.Matches(strTargetString)
- If myMatch.Success Then
- If myMatch.Value <> "" Then
- If i = 0 Then
- result = myMatch.Value.ToString
- Else
- result = result & ";" & myMatch.Value.ToString
- End If
- i += 1
- End If
- End If
- Next
- Return result
- Catch ex As Exception
- MsgBox("Unexpected Error in extractFromHeader: " & vbNewLine & ex.Message, MsgBoxStyle.Critical)
- Return Nothing
- End Try
-
- End Function
-
- '''
- ''' Extrahiert aus den Headerinformationen anhand einer Liste von Regular Expressions eine Empfängeradresse.
- '''
- ''' Headerinformationen die von getMessageHeaders erzeugt wurden.
- ''' Eine Liste von Regular Expressions
- ''' Die Ergebnisgruppe, die die Adresse enthält
- ''' Eine Emailadresse oder Nothing, wenn keine der Regular Expressions ein Ergebnis lieferte.
- Public Shared Function extractToAddress(messageHeaders As String, RegexList As List(Of Regex), Optional RegexGroup As Integer = 1) As String
- If IsNothing(messageHeaders) Then
- Return Nothing
- End If
-
- For Each rx In RegexList
- Dim match As Match = rx.Match(messageHeaders)
- Dim email As String = match.Groups(RegexGroup).Value
-
- If Not String.IsNullOrWhiteSpace(email) Then
- Return email
- End If
- Next
-
- Return Nothing
- End Function
-End Class
diff --git a/GUIs.ZooFlow/Globix/ClassFolderwatcher.vb b/GUIs.ZooFlow/Globix/ClassFolderwatcher.vb
index a11d5b3b..80a49e3c 100644
--- a/GUIs.ZooFlow/Globix/ClassFolderwatcher.vb
+++ b/GUIs.ZooFlow/Globix/ClassFolderwatcher.vb
@@ -20,14 +20,9 @@ Public Class ClassFolderwatcher
'Gestartet also Stoppen
FWFolderWatcher.EnableRaisingEvents = False
My.Application.Globix.Folderwatchstarted = False
- 'FolderWatch neu instanzieren
- FWFolderWatcher = New FileSystemWatcher(My.Application.Globix.CurrentFolderWatchPath, "*.*")
- Logger.Info(" >> FolderWatch neu instanziert")
- FWFolderWatcher.IncludeSubdirectories = False
- FWFolderWatcher.EnableRaisingEvents = True
- AddHandler FWFolderWatcher.Created, AddressOf OnCreated
+
+ FWFolderWatcher = StartFolderwatcherForPath(My.Application.Globix.CurrentFolderWatchPath)
My.Application.Globix.Folderwatchstarted = True
- 'SaveConfigValue("my.Application.Globix.Folderwatchstarted", "True")
My.UIConfig.Globix.FolderWatchStarted = True
My.UIConfigManager.Save()
End If
@@ -43,13 +38,10 @@ Public Class ClassFolderwatcher
If FWScan.EnableRaisingEvents = True Then
'Gestartet also Stoppen
FWScan.EnableRaisingEvents = False
+
'FolderWatch neu instanzieren
- FWScan = New System.IO.FileSystemWatcher(My.Application.Globix.CURRENT_SCAN_FOLDERWATCH, "*.*")
- Logger.Info(" >> FolderWatchScan neu instanziert")
- FWScan.IncludeSubdirectories = False
- FWScan.EnableRaisingEvents = True
- AddHandler FWScan.Created, AddressOf OnCreated
- 'SaveConfigValue("FWSCAN_started", "True")
+ FWScan = StartFolderwatcherForPath(My.Application.Globix.CURRENT_SCAN_FOLDERWATCH)
+
My.UIConfig.Globix.FolderWatchScanStarted = True
My.UIConfigManager.Save()
End If
@@ -60,28 +52,16 @@ Public Class ClassFolderwatcher
End Sub
Public Sub StartStop_FolderWatch()
Try
- If FWFolderWatcher Is Nothing Then
- FWFolderWatcher = New System.IO.FileSystemWatcher(My.Application.Globix.CurrentFolderWatchPath, "*.*")
- Logger.Info(" >> FolderWatch Gestartet")
- FWFolderWatcher.IncludeSubdirectories = False
- FWFolderWatcher.EnableRaisingEvents = True
- AddHandler FWFolderWatcher.Created, AddressOf OnCreated
+ If FWFolderWatcher Is Nothing OrElse FWFolderWatcher.EnableRaisingEvents = False Then
+ ' Folderwatch neu instanzieren
+ FWFolderWatcher = StartFolderwatcherForPath(My.Application.Globix.CurrentFolderWatchPath)
My.Application.Globix.Folderwatchstarted = True
My.UIConfig.Globix.FolderWatchStarted = True
My.UIConfigManager.Save()
+
End If
- If FWFolderWatcher.EnableRaisingEvents = False Then
- ' Dim watcher As New FileSystemWatcher()
- ' watcher.Path = CURRENT_FOLDERWATCH
- FWFolderWatcher = New System.IO.FileSystemWatcher(My.Application.Globix.CurrentFolderWatchPath, "*.*")
- Logger.Info(" >> FolderWatch Gestartet")
- FWFolderWatcher.IncludeSubdirectories = False
- FWFolderWatcher.EnableRaisingEvents = True
- AddHandler FWFolderWatcher.Created, AddressOf OnCreated
- My.Application.Globix.Folderwatchstarted = True
- My.UIConfig.Globix.FolderWatchStarted = True
- My.UIConfigManager.Save()
- Else
+
+ If FWFolderWatcher.EnableRaisingEvents = True Then
'Gestartet also Stoppen
FWFolderWatcher.EnableRaisingEvents = False
My.Application.Globix.Folderwatchstarted = False
@@ -161,6 +141,21 @@ Public Class ClassFolderwatcher
Return False
End If
End Function
+
+ Private Function StartFolderwatcherForPath(pPath As String) As FileSystemWatcher
+ Dim oWatcher = New FileSystemWatcher(pPath, "*.*") With {
+ .IncludeSubdirectories = False,
+ .EnableRaisingEvents = True
+ }
+ AddHandler oWatcher.Created, AddressOf OnCreated
+ Logger.Debug("Folder Watcher started for Path [{0}]", pPath)
+
+ My.UIConfig.Globix.FolderWatchScanStarted = True
+ My.UIConfigManager.Save()
+
+ Return oWatcher
+ End Function
+
Private Sub OnCreated(source As Object, e As FileSystemEventArgs)
Try
If Not IsNothing(My.Application.Globix.DTEXCLUDE_FILES) Then
diff --git a/GUIs.ZooFlow/ZooFlow.vbproj b/GUIs.ZooFlow/ZooFlow.vbproj
index 16880422..3a51fc62 100644
--- a/GUIs.ZooFlow/ZooFlow.vbproj
+++ b/GUIs.ZooFlow/ZooFlow.vbproj
@@ -275,7 +275,6 @@
True
MyDataset.xsd
-
frmGlobixBasicConfig.vb
diff --git a/Modules.EDMIAPI/Client.vb b/Modules.EDMIAPI/Client.vb
index b9d98da5..0b008467 100644
--- a/Modules.EDMIAPI/Client.vb
+++ b/Modules.EDMIAPI/Client.vb
@@ -11,25 +11,27 @@ Public Class Client
Private Const KIND_TYPE_DOC = "DOC"
+ Private ReadOnly _LogConfig As LogConfig
Private ReadOnly _logger As Logger
Private ReadOnly _channelFactory As ChannelFactory(Of IEDMIServiceChannel)
Private ReadOnly _IPAddressServer As String
+ Private ReadOnly _PortServer As Integer
Private _dummy_table_attributes As DataTable
Private _channel As IEDMIServiceChannel
Private _FileEx As Filesystem.File
-
'''
''' Creates a new EDMI Client object
'''
- ''' LogConfig object
- ''' The IP address/hostname and port, separated by semicolon or colon, ex localhost:9000
- Public Sub New(LogConfig As LogConfig, ServiceAdress As String)
- _logger = LogConfig.GetLogger()
- _FileEx = New Filesystem.File(LogConfig)
+ ''' LogConfig object
+ ''' The IP address/hostname and port, separated by semicolon or colon, ex. 1.2.3.4:9000
+ Public Sub New(pLogConfig As LogConfig, pServiceAdress As String)
+ _LogConfig = pLogConfig
+ _logger = pLogConfig.GetLogger()
+ _FileEx = New Filesystem.File(pLogConfig)
- Dim oServiceAddress As String = ServiceAdress
+ Dim oServiceAddress As String = pServiceAdress
Dim oAddressArray() As String
If oServiceAddress.Contains(";") Then
@@ -40,8 +42,10 @@ Public Class Client
Try
_IPAddressServer = oAddressArray(0)
+ _PortServer = oAddressArray(1)
+
Dim oBinding = Channel.GetBinding()
- Dim oAddress = New EndpointAddress($"net.tcp://{oAddressArray(0)}:{oAddressArray(1)}/DigitalData/Services/Main")
+ Dim oAddress = New EndpointAddress($"net.tcp://{_IPAddressServer}:{_PortServer}/DigitalData/Services/Main")
Dim oFactory = New ChannelFactory(Of IEDMIServiceChannel)(oBinding, oAddress)
_channelFactory = oFactory
@@ -243,6 +247,29 @@ Public Class Client
End Try
End Function
+ Public Function GetFileObject(pObjectId As Long) As FileObject
+ Try
+ Dim oGetFileObject As New Modules.Zooflow.GetFileObject(_LogConfig, Me)
+ Dim oFileObject = oGetFileObject.Run(pObjectId)
+ Return oFileObject
+ Catch ex As Exception
+ _logger.Error(ex)
+ Return Nothing
+ End Try
+ End Function
+
+ Public Async Function GetFileObjectAsync(pObjectId As Long) As Task(Of FileObject)
+ Try
+ Dim oGetFileObject As New Modules.Zooflow.GetFileObject(_LogConfig, Me)
+ Dim oFileObject = Await oGetFileObject.RunAsync(pObjectId)
+ Return oFileObject
+ Catch ex As Exception
+ _logger.Error(ex)
+ Return Nothing
+ End Try
+ End Function
+
+
'''
''' Sets a value to an attribute
'''
@@ -466,7 +493,6 @@ Public Class Client
End Try
End Function
-
Private Function GetAttributesForObject(pObjectId As Long, pLanguage As String) As List(Of ObjectAttribute)
Dim oAttributes As New List(Of ObjectAttribute)
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse.datasource b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse.datasource
new file mode 100644
index 00000000..df13dd7d
--- /dev/null
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse.datasource
@@ -0,0 +1,10 @@
+
+
+
+ DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
+
\ No newline at end of file
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.Methods.GetFileObject.xsd b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.Methods.GetFileObject.xsd
new file mode 100644
index 00000000..c0bd799b
--- /dev/null
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.Methods.GetFileObject.xsd
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.wsdl b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.wsdl
index b5182607..a5f4ff8e 100644
--- a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.wsdl
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.wsdl
@@ -15,6 +15,7 @@
+
@@ -136,6 +137,12 @@
+
+
+
+
+
+
@@ -244,6 +251,10 @@
+
+
+
+
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.xsd b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.xsd
index 84c580cb..38cca34e 100644
--- a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.xsd
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/DigitalData.Services.EDMIService.xsd
@@ -4,6 +4,7 @@
+
@@ -202,6 +203,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -212,7 +227,7 @@
-
+
@@ -228,7 +243,7 @@
-
+
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.svcmap b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.svcmap
index 08a1ba92..3fd71f59 100644
--- a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.svcmap
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.svcmap
@@ -37,6 +37,7 @@
+
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.vb b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.vb
index 33d0d301..f9f6c6da 100644
--- a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.vb
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/Reference.vb
@@ -26,6 +26,7 @@ Namespace EDMIServiceReference
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.NewFileResponse)), _
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.SetAttributeValueResponse)), _
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.ImportFileResponse)), _
+ System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.GetFileObjectResponse)), _
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.TableResult))> _
Partial Public Class BaseResponse
Inherits Object
@@ -129,6 +130,9 @@ Namespace EDMIServiceReference
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.ImportFileRequest)), _
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.ImportFileResponse)), _
System.Runtime.Serialization.KnownTypeAttribute(GetType(String())), _
+ System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.GetFileObjectRequest)), _
+ System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.GetFileObjectResponse)), _
+ System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.FileObject)), _
System.Runtime.Serialization.KnownTypeAttribute(GetType(EDMIServiceReference.RightsAccessRight))> _
Partial Public Class ScalarResult
Inherits EDMIServiceReference.BaseResponse
@@ -234,6 +238,31 @@ Namespace EDMIServiceReference
End Property
End Class
+ _
+ Partial Public Class GetFileObjectResponse
+ Inherits EDMIServiceReference.BaseResponse
+
+ _
+ Private FileObjectField As EDMIServiceReference.FileObject
+
+ _
+ Public Property FileObject() As EDMIServiceReference.FileObject
+ Get
+ Return Me.FileObjectField
+ End Get
+ Set
+ If (Object.ReferenceEquals(Me.FileObjectField, value) <> true) Then
+ Me.FileObjectField = value
+ Me.RaisePropertyChanged("FileObject")
+ End If
+ End Set
+ End Property
+ End Class
+
_
+ Partial Public Class GetFileObjectRequest
+ Inherits Object
+ Implements System.Runtime.Serialization.IExtensibleDataObject, System.ComponentModel.INotifyPropertyChanged
+
+ _
+ Private extensionDataField As System.Runtime.Serialization.ExtensionDataObject
+
+ _
+ Private LoadFileContentsField As Boolean
+
+ _
+ Private ObjectIdField As Long
+
+ _
+ Public Property ExtensionData() As System.Runtime.Serialization.ExtensionDataObject Implements System.Runtime.Serialization.IExtensibleDataObject.ExtensionData
+ Get
+ Return Me.extensionDataField
+ End Get
+ Set
+ Me.extensionDataField = value
+ End Set
+ End Property
+
+ _
+ Public Property LoadFileContents() As Boolean
+ Get
+ Return Me.LoadFileContentsField
+ End Get
+ Set
+ If (Me.LoadFileContentsField.Equals(value) <> true) Then
+ Me.LoadFileContentsField = value
+ Me.RaisePropertyChanged("LoadFileContents")
+ End If
+ End Set
+ End Property
+
+ _
+ Public Property ObjectId() As Long
+ Get
+ Return Me.ObjectIdField
+ End Get
+ Set
+ If (Me.ObjectIdField.Equals(value) <> true) Then
+ Me.ObjectIdField = value
+ Me.RaisePropertyChanged("ObjectId")
+ End If
+ End Set
+ End Property
+
+ Public Event PropertyChanged As System.ComponentModel.PropertyChangedEventHandler Implements System.ComponentModel.INotifyPropertyChanged.PropertyChanged
+
+ Protected Sub RaisePropertyChanged(ByVal propertyName As String)
+ Dim propertyChanged As System.ComponentModel.PropertyChangedEventHandler = Me.PropertyChangedEvent
+ If (Not (propertyChanged) Is Nothing) Then
+ propertyChanged(Me, New System.ComponentModel.PropertyChangedEventArgs(propertyName))
+ End If
+ End Sub
+ End Class
+
+ _
+ Partial Public Class FileObject
+ Inherits Object
+ Implements System.Runtime.Serialization.IExtensibleDataObject, System.ComponentModel.INotifyPropertyChanged
+
+ _
+ Private extensionDataField As System.Runtime.Serialization.ExtensionDataObject
+
+ Private _AccessRightsField As String
+
+ Private _FileContentsField() As Byte
+
+ Private _FileHashField As String
+
+ Private _FileSizeField As Long
+
+ Private _ObjectIdField As Long
+
+ _
+ Public Property ExtensionData() As System.Runtime.Serialization.ExtensionDataObject Implements System.Runtime.Serialization.IExtensibleDataObject.ExtensionData
+ Get
+ Return Me.extensionDataField
+ End Get
+ Set
+ Me.extensionDataField = value
+ End Set
+ End Property
+
+ _
+ Public Property _AccessRights() As String
+ Get
+ Return Me._AccessRightsField
+ End Get
+ Set
+ If (Object.ReferenceEquals(Me._AccessRightsField, value) <> true) Then
+ Me._AccessRightsField = value
+ Me.RaisePropertyChanged("_AccessRights")
+ End If
+ End Set
+ End Property
+
+ _
+ Public Property _FileContents() As Byte()
+ Get
+ Return Me._FileContentsField
+ End Get
+ Set
+ If (Object.ReferenceEquals(Me._FileContentsField, value) <> true) Then
+ Me._FileContentsField = value
+ Me.RaisePropertyChanged("_FileContents")
+ End If
+ End Set
+ End Property
+
+ _
+ Public Property _FileHash() As String
+ Get
+ Return Me._FileHashField
+ End Get
+ Set
+ If (Object.ReferenceEquals(Me._FileHashField, value) <> true) Then
+ Me._FileHashField = value
+ Me.RaisePropertyChanged("_FileHash")
+ End If
+ End Set
+ End Property
+
+ _
+ Public Property _FileSize() As Long
+ Get
+ Return Me._FileSizeField
+ End Get
+ Set
+ If (Me._FileSizeField.Equals(value) <> true) Then
+ Me._FileSizeField = value
+ Me.RaisePropertyChanged("_FileSize")
+ End If
+ End Set
+ End Property
+
+ _
+ Public Property _ObjectId() As Long
+ Get
+ Return Me._ObjectIdField
+ End Get
+ Set
+ If (Me._ObjectIdField.Equals(value) <> true) Then
+ Me._ObjectIdField = value
+ Me.RaisePropertyChanged("_ObjectId")
+ End If
+ End Set
+ End Property
+
+ Public Event PropertyChanged As System.ComponentModel.PropertyChangedEventHandler Implements System.ComponentModel.INotifyPropertyChanged.PropertyChanged
+
+ Protected Sub RaisePropertyChanged(ByVal propertyName As String)
+ Dim propertyChanged As System.ComponentModel.PropertyChangedEventHandler = Me.PropertyChangedEvent
+ If (Not (propertyChanged) Is Nothing) Then
+ propertyChanged(Me, New System.ComponentModel.PropertyChangedEventArgs(propertyName))
+ End If
+ End Sub
+ End Class
+
_
Public Enum RightsAccessRight As Integer
@@ -1353,6 +1553,12 @@ Namespace EDMIServiceReference
_
Function ImportFileAsync(ByVal Data As EDMIServiceReference.ImportFileRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.ImportFileResponse)
+ _
+ Function GetFileObject(ByVal Data As EDMIServiceReference.GetFileObjectRequest) As EDMIServiceReference.GetFileObjectResponse
+
+ _
+ Function GetFileObjectAsync(ByVal Data As EDMIServiceReference.GetFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.GetFileObjectResponse)
+
'CODEGEN: Der Nachrichtenvertrag wird generiert, da der Wrappername (DocumentStreamRequest) von Nachricht "DocumentStreamRequest" nicht mit dem Standardwert (GetFileByObjectId) übereinstimmt.
_
Function EDMIServiceReference_IEDMIService_GetFileByObjectId(ByVal request As EDMIServiceReference.DocumentStreamRequest) As EDMIServiceReference.DocumentStreamResponse Implements EDMIServiceReference.IEDMIService.GetFileByObjectId
Return MyBase.Channel.GetFileByObjectId(request)
diff --git a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/service.wsdl b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/service.wsdl
index 28c3fba3..2719bd87 100644
--- a/Modules.EDMIAPI/Connected Services/EDMIServiceReference/service.wsdl
+++ b/Modules.EDMIAPI/Connected Services/EDMIServiceReference/service.wsdl
@@ -200,6 +200,15 @@
+
+
+
+
+
+
+
+
+
diff --git a/Modules.EDMIAPI/EDMI.API.vbproj b/Modules.EDMIAPI/EDMI.API.vbproj
index d5ef560c..453e7b8d 100644
--- a/Modules.EDMIAPI/EDMI.API.vbproj
+++ b/Modules.EDMIAPI/EDMI.API.vbproj
@@ -76,6 +76,7 @@
+
True
True
@@ -122,6 +123,9 @@
Reference.svcmap
+
+ Reference.svcmap
+
Reference.svcmap
@@ -158,6 +162,9 @@
Designer
+
+ Designer
+
Designer
diff --git a/Modules.EDMIAPI/Modules/ZooFlow/GetFileObject.vb b/Modules.EDMIAPI/Modules/ZooFlow/GetFileObject.vb
new file mode 100644
index 00000000..73f05eb6
--- /dev/null
+++ b/Modules.EDMIAPI/Modules/ZooFlow/GetFileObject.vb
@@ -0,0 +1,44 @@
+Imports DigitalData.Modules.EDMI.API.EDMIServiceReference
+Imports DigitalData.Modules.Logging
+
+Namespace Modules.Zooflow
+ Public Class GetFileObject
+ Private ReadOnly LogConfig As LogConfig
+ Private ReadOnly Logger As Logger
+ Private ReadOnly Channel As IEDMIServiceChannel
+
+ Public Sub New(pLogConfig As LogConfig, pChannel As IEDMIServiceChannel)
+ LogConfig = pLogConfig
+ Logger = pLogConfig.GetLogger()
+ Channel = pChannel
+ End Sub
+
+ Public Async Function RunAsync(pObjectId As Long) As Task(Of FileObject)
+ Try
+ Dim oResult = Await Channel.GetFileObjectAsync(New GetFileObjectRequest With {.ObjectId = pObjectId})
+ If oResult.OK Then
+ Return oResult.FileObject
+ Else
+ Return Nothing
+ End If
+ Catch ex As Exception
+ Logger.Error(ex)
+ Return Nothing
+ End Try
+ End Function
+
+ Public Function Run(pObjectId As Long) As FileObject
+ Try
+ Dim oResult = Channel.GetFileObject(New GetFileObjectRequest With {.ObjectId = pObjectId})
+ If oResult.OK Then
+ Return oResult.FileObject
+ Else
+ Return Nothing
+ End If
+ Catch ex As Exception
+ Logger.Error(ex)
+ Return Nothing
+ End Try
+ End Function
+ End Class
+End Namespace
\ No newline at end of file
diff --git a/Modules.Language/DataRowEx.vb b/Modules.Language/DataTableEx.vb
similarity index 50%
rename from Modules.Language/DataRowEx.vb
rename to Modules.Language/DataTableEx.vb
index 23245305..fb130dfa 100644
--- a/Modules.Language/DataRowEx.vb
+++ b/Modules.Language/DataTableEx.vb
@@ -1,6 +1,6 @@
Imports System.Runtime.CompilerServices
-Public Module DataRowEx
+Public Module DataTableEx
Public Function ItemEx(Of T)(pRow As DataRow, pFieldName As String, Optional pDefaultValue As T = Nothing) As T
Try
@@ -9,4 +9,16 @@ Public Module DataRowEx
Return Nothing
End Try
End Function
+
+
+ Public Function First(pTable As DataTable) As DataRow
+ Try
+ If pTable Is Nothing OrElse pTable.Rows.Count = 0 Then
+ Return Nothing
+ End If
+ Return pTable.Rows.Item(0)
+ Catch ex As Exception
+ Return Nothing
+ End Try
+ End Function
End Module
diff --git a/Modules.Language/Language.vbproj b/Modules.Language/Language.vbproj
index 3384ce30..1598a26f 100644
--- a/Modules.Language/Language.vbproj
+++ b/Modules.Language/Language.vbproj
@@ -74,7 +74,7 @@
-
+
diff --git a/Modules.Language/My Project/AssemblyInfo.vb b/Modules.Language/My Project/AssemblyInfo.vb
index 3a88ea93..f066e253 100644
--- a/Modules.Language/My Project/AssemblyInfo.vb
+++ b/Modules.Language/My Project/AssemblyInfo.vb
@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben:
'
-
-
+
+
diff --git a/Service.EDMIService/EDMIService.vb b/Service.EDMIService/EDMIService.vb
index cd4a0ba1..cca35d6b 100644
--- a/Service.EDMIService/EDMIService.vb
+++ b/Service.EDMIService/EDMIService.vb
@@ -77,6 +77,12 @@ Public Class EDMIService
Return oImportFile.Run(pData)
End Function
+ Public Function GetFileObject(pData As GetFileObject.GetFileObjectRequest) As GetFileObject.GetFileObjectResponse Implements IEDMIService.GetFileObject
+ _Logger.Debug("Start of Method [GetFileObject]")
+ Dim oGetFileObject As New GetFileObject.GetFileObjectMethod(LogConfig, MSSQL_IDB, GlobalState)
+ Return oGetFileObject.Run(pData)
+ End Function
+
#Region "=== Heartbeat ==="
Public Function Heartbeat() As Boolean Implements IEDMIService.Heartbeat
Return True
diff --git a/Service.EDMIService/EDMIService.vbproj b/Service.EDMIService/EDMIService.vbproj
index da72cb41..f5272e03 100644
--- a/Service.EDMIService/EDMIService.vbproj
+++ b/Service.EDMIService/EDMIService.vbproj
@@ -138,6 +138,10 @@
+
+
+
+
diff --git a/Service.EDMIService/IEDMIService.vb b/Service.EDMIService/IEDMIService.vb
index 717056d6..77976c41 100644
--- a/Service.EDMIService/IEDMIService.vb
+++ b/Service.EDMIService/IEDMIService.vb
@@ -72,6 +72,8 @@ Interface IEDMIService
Function ImportFile(Data As GlobalIndexer.ImportFile.ImportFileRequest) As GlobalIndexer.ImportFile.ImportFileResponse
+
+ Function GetFileObject(Data As GetFileObject.GetFileObjectRequest) As GetFileObject.GetFileObjectResponse
#End Region
#Region "Document (Old)"
diff --git a/Service.EDMIService/Methods/GetFileObject/FileObject.vb b/Service.EDMIService/Methods/GetFileObject/FileObject.vb
new file mode 100644
index 00000000..6ffed104
--- /dev/null
+++ b/Service.EDMIService/Methods/GetFileObject/FileObject.vb
@@ -0,0 +1,20 @@
+Imports System.Runtime.Serialization
+
+Namespace Methods.GetFileObject
+
+ Public Class FileObject
+
+ Public Property ObjectId As Long
+
+ Public Property AccessRights As String
+
+ Public Property FileExtension As String
+
+ Public Property FileHash As String
+
+ Public Property FileSize As Long
+
+ Public Property FileContents As Byte()
+ End Class
+
+End Namespace
\ No newline at end of file
diff --git a/Service.EDMIService/Methods/GetFileObject/GetFileObjectMethod.vb b/Service.EDMIService/Methods/GetFileObject/GetFileObjectMethod.vb
new file mode 100644
index 00000000..be5d6102
--- /dev/null
+++ b/Service.EDMIService/Methods/GetFileObject/GetFileObjectMethod.vb
@@ -0,0 +1,88 @@
+Imports DigitalData.Modules.Database
+Imports DigitalData.Modules.Logging
+Imports DigitalData.Modules.Language
+Imports System.IO
+
+Namespace Methods.GetFileObject
+ Public Class GetFileObjectMethod
+ Inherits BaseMethod
+
+ Public Sub New(pLogConfig As LogConfig, pMSSQLServer As MSSQLServer, pGlobalState As GlobalState)
+ MyBase.New(pLogConfig, pMSSQLServer, pGlobalState)
+ End Sub
+
+ Public Function Run(pData As GetFileObjectRequest) As GetFileObjectResponse
+ Try
+ If Helpers.TestObjectIdExists(pData.ObjectId) = False Then
+ LogAndThrow("ObjectId does not exist!")
+ End If
+
+ Dim oSQL = $"SELECT * FROM VWIDB_FILE_OBJECT WHERE IDB_OBJ_ID = {pData.ObjectId}"
+ Dim oTable = Database.GetDatatable(oSQL)
+
+ If oTable Is Nothing OrElse oTable.Rows.Count = 0 Then
+ LogAndThrow("Error while getting FileObject data!")
+ End If
+
+ Dim oRow As DataRow = oTable.First()
+ Dim oFileHash As String = oRow.ItemEx("FILE_HASH", "")
+ Dim oFileSize As Long = oRow.ItemEx(Of Long)("FILE_SIZE", 0)
+
+ Dim oFileObject As New FileObject With {
+ .ObjectId = pData.ObjectId,
+ .FileHash = oFileHash,
+ .FileSize = oFileSize
+ }
+
+ If pData.LoadFileContents = True Then
+ Dim oFilePath = oRow.ItemEx("RELPATH", "")
+ Dim oFileName = oRow.ItemEx("Filename", "")
+ Dim oFullFileName = Path.Combine(oFilePath, oFileName)
+
+ If File.Exists(oFullFileName) = False Then
+ Throw New FileNotFoundException("FileObject not Found!", oFullFileName)
+ End If
+
+ Dim oContents As Byte() = LoadFileContents(oFullFileName)
+
+ If oContents Is Nothing Then
+ Throw New FileNotFoundException("FileObject not Found!", oFullFileName)
+ End If
+
+ oFileObject.FileContents = oContents
+
+ End If
+
+ Return New GetFileObjectResponse(oFileObject)
+
+ Catch ex As FileNotFoundException
+ Logger.Error(ex)
+ Return New GetFileObjectResponse(ex, ex.FileName)
+
+ Catch ex As Exception
+ Logger.Error(ex)
+ Return New GetFileObjectResponse(ex)
+
+ End Try
+ End Function
+
+ Private Function LoadFileContents(pFilePath As String) As Byte()
+ Try
+ Using oFileStream As New FileStream(pFilePath, FileMode.Open, FileAccess.Read)
+ Using oMemoryStream As New MemoryStream()
+ oFileStream.CopyTo(oMemoryStream)
+ Dim oContents = oMemoryStream.ToArray()
+
+ Return oContents
+ End Using
+ End Using
+
+ Catch ex As Exception
+ Logger.Error(ex)
+ Return Nothing
+
+ End Try
+ End Function
+ End Class
+
+End Namespace
\ No newline at end of file
diff --git a/Service.EDMIService/Methods/GetFileObject/GetFileObjectRequest.vb b/Service.EDMIService/Methods/GetFileObject/GetFileObjectRequest.vb
new file mode 100644
index 00000000..59aa5e75
--- /dev/null
+++ b/Service.EDMIService/Methods/GetFileObject/GetFileObjectRequest.vb
@@ -0,0 +1,14 @@
+Imports System.Runtime.Serialization
+
+Namespace Methods.GetFileObject
+
+
+ Public Class GetFileObjectRequest
+
+ Public Property ObjectId As Long
+
+ Public Property LoadFileContents As Boolean = False
+ End Class
+
+End Namespace
+
diff --git a/Service.EDMIService/Methods/GetFileObject/GetFileObjectResponse.vb b/Service.EDMIService/Methods/GetFileObject/GetFileObjectResponse.vb
new file mode 100644
index 00000000..70b7b41c
--- /dev/null
+++ b/Service.EDMIService/Methods/GetFileObject/GetFileObjectResponse.vb
@@ -0,0 +1,21 @@
+Imports System.Runtime.Serialization
+
+Namespace Methods.GetFileObject
+
+
+ Public Class GetFileObjectResponse
+ Inherits Messages.BaseResponse
+
+
+ Public Property FileObject As FileObject
+
+ Public Sub New(pFileObject As FileObject)
+ MyBase.New()
+ FileObject = pFileObject
+ End Sub
+
+ Public Sub New(pException As Exception, Optional pDetails As String = "")
+ MyBase.New(pException, pDetails)
+ End Sub
+ End Class
+End Namespace
diff --git a/Service.EDMIService/Methods/NewFile/NewFileMethod.vb b/Service.EDMIService/Methods/NewFile/NewFileMethod.vb
index 3d21fae3..239d6ae3 100644
--- a/Service.EDMIService/Methods/NewFile/NewFileMethod.vb
+++ b/Service.EDMIService/Methods/NewFile/NewFileMethod.vb
@@ -83,12 +83,12 @@ Public Class NewFileMethod
Dim oFileObjectInfo As IO.FileInfo = New IO.FileInfo(oFilePath)
Dim oFileObjectSize As Long = pData.File.FileContents.Length
- Dim oFileObjectExtension As String = oFileObjectInfo.Extension.Substring(1)
Dim oFileObjectName As String = oFileObjectInfo.Name
+ Dim oOriginalExtension As String = pData.File.FileInfoRaw.Extension.Substring(1)
Logger.Debug("File Information for [{0}]:", oFileObjectName)
Logger.Debug("Size: [{0}]", oFileObjectSize)
- Logger.Debug("Extension: [{0}]", oFileObjectExtension)
+ Logger.Debug("Original Extension: [{0}]", oOriginalExtension)
Logger.Debug("Checksum: [{0}]", pData.File.FileChecksum)
Try
@@ -110,7 +110,7 @@ Public Class NewFileMethod
Dim oSQL As String = $"EXEC PRIDB_NEW_IDBFO
'{oFinalPath}',
'{oFileObjectName}',
- '{oFileObjectExtension}',
+ '{oOriginalExtension}',
{oFileObjectSize},
'{pData.File.FileChecksum}' ,
'{pData.User.UserName}',
@@ -218,6 +218,7 @@ Public Class NewFileMethod
End Function
Private Function GetFileObjectFileName(IDB_OBJ_ID As Long, pFilename As String, pKeepFilename As Boolean) As String
+ ' TODO: save actual extensions
If pKeepFilename Then
Return pFilename
Else
diff --git a/Service.EDMIService/My Project/AssemblyInfo.vb b/Service.EDMIService/My Project/AssemblyInfo.vb
index 5fe0b647..93e175f7 100644
--- a/Service.EDMIService/My Project/AssemblyInfo.vb
+++ b/Service.EDMIService/My Project/AssemblyInfo.vb
@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben:
'
-
-
+
+