EDMI: Update Service, Add TestObjectIdExists, Work on GetVariableValue

This commit is contained in:
Jonathan Jenne 2021-07-05 16:31:22 +02:00
parent bd6fa93a45
commit 3ef80383ea
12 changed files with 405 additions and 238 deletions

View File

@ -10,11 +10,12 @@ Public Class Client
Private Const INVALID_OBEJCT_ID As Long = 0 Private Const INVALID_OBEJCT_ID As Long = 0
Private Const KIND_TYPE_DOC = "DOC" Private Const KIND_TYPE_DOC = "DOC"
Public Const DEFAULT_SERVICE_PORT = 9000
Private ReadOnly _logger As Logger Private ReadOnly _logger As Logger
Private ReadOnly _channelFactory As ChannelFactory(Of IEDMIServiceChannel) Private ReadOnly _channelFactory As ChannelFactory(Of IEDMIServiceChannel)
Private ReadOnly _IPAddressServer As String Private ReadOnly _IPAddressServer As String
Private _dummy_table_attributes As DataTable
Private _channel As IEDMIServiceChannel Private _channel As IEDMIServiceChannel
Public Class StreamedFile Public Class StreamedFile
@ -107,8 +108,6 @@ Public Class Client
End Try End Try
End Function End Function
''' <summary> ''' <summary>
''' TODO: Creates a new object ''' TODO: Creates a new object
''' </summary> ''' </summary>
@ -140,10 +139,12 @@ Public Class Client
''' <returns>The ObjectId of the newly generated filesystem object</returns> ''' <returns>The ObjectId of the newly generated filesystem object</returns>
Public Async Function NewFileAsync(pFilePath As String, pAddedWho As String, pAddedWhen As Date, pObjectStoreType As String, pBusinessEntity As String, Optional pImportOptions As NewFileOptions = Nothing) As Task(Of Long) Public Async Function NewFileAsync(pFilePath As String, pAddedWho As String, pAddedWhen As Date, pObjectStoreType As String, pBusinessEntity As String, Optional pImportOptions As NewFileOptions = Nothing) As Task(Of Long)
Try Try
' Set default options
If pImportOptions Is Nothing Then If pImportOptions Is Nothing Then
pImportOptions = New NewFileOptions() pImportOptions = New NewFileOptions()
End If End If
' Check if file exists
If File.Exists(pFilePath) = False Then If File.Exists(pFilePath) = False Then
Throw New FileNotFoundException("ImportFileAsync: Path does not exist") Throw New FileNotFoundException("ImportFileAsync: Path does not exist")
End If End If
@ -151,6 +152,7 @@ Public Class Client
Dim oFileInfo As New FileInfo(pFilePath) Dim oFileInfo As New FileInfo(pFilePath)
Dim oExtension As String = oFileInfo.Extension Dim oExtension As String = oFileInfo.Extension
' Creating new ObjectId
Dim oObjectIdResponse = Await _channel.NewObjectIdAsync(New NewObjectIdRequest With { Dim oObjectIdResponse = Await _channel.NewObjectIdAsync(New NewObjectIdRequest With {
.BusinessEntity = pBusinessEntity, .BusinessEntity = pBusinessEntity,
.KindType = KIND_TYPE_DOC, .KindType = KIND_TYPE_DOC,
@ -161,6 +163,7 @@ Public Class Client
Throw New ApplicationException("ImportFileAsync: Could not get ObjectId") Throw New ApplicationException("ImportFileAsync: Could not get ObjectId")
End If End If
' Create new FileObject for ObjectId
Dim oFilePathResponse = Await _channel.NewFileObjectAsync(New NewFileObjectRequest With { Dim oFilePathResponse = Await _channel.NewFileObjectAsync(New NewFileObjectRequest With {
.DateImported = pAddedWhen, .DateImported = pAddedWhen,
.Extension = oExtension, .Extension = oExtension,
@ -173,6 +176,7 @@ Public Class Client
Throw New ApplicationException("ImportFileAsync: Could not get FileObject Path") Throw New ApplicationException("ImportFileAsync: Could not get FileObject Path")
End If End If
' Importing the file now
Using oFileStream As New FileStream(pFilePath, FileMode.Open, FileAccess.Read) Using oFileStream As New FileStream(pFilePath, FileMode.Open, FileAccess.Read)
Using oMemoryStream As New MemoryStream() Using oMemoryStream As New MemoryStream()
oFileStream.CopyTo(oMemoryStream) oFileStream.CopyTo(oMemoryStream)
@ -208,13 +212,15 @@ Public Class Client
''' <summary> ''' <summary>
''' Sets a value to an attribute ''' Sets a value to an attribute
''' </summary> ''' </summary>
''' <param name="pAttributeName"></param> ''' <param name="pObjectId">IDB ObjectId</param>
''' <param name="pAttributeType"></param> ''' <param name="pAttributeName">Name of the attribute</param>
''' <param name="pAttributeType">The type of Attribute</param>
''' <param name="pValue"></param> ''' <param name="pValue"></param>
''' <param name="pOptions"></param> ''' <param name="pOptions"></param>
''' <returns></returns> ''' <returns></returns>
Public Function SetVariableValue(pObjectId As Long, pAttributeName As String, pAttributeType As AttributeType, pValue As Object, Optional pOptions As SetVariableValueOptions = Nothing) As Boolean Public Function SetVariableValue(pObjectId As Long, pAttributeName As String, pAttributeType As AttributeType, pValue As Object, Optional pOptions As SetVariableValueOptions = Nothing) As Boolean
Try Try
' Set default options
If pOptions Is Nothing Then If pOptions Is Nothing Then
pOptions = New SetVariableValueOptions() pOptions = New SetVariableValueOptions()
End If End If
@ -222,68 +228,93 @@ Public Class Client
Dim oLanguage = NotNull(pOptions.Language, GetUserLanguage()) Dim oLanguage = NotNull(pOptions.Language, GetUserLanguage())
Dim oUsername = NotNull(pOptions.Username, Environment.UserName) Dim oUsername = NotNull(pOptions.Username, Environment.UserName)
Try
Dim oResponse = _channel.TestObjectIdExists(New TestObjectIdExistsRequest With {.ObjectId = pObjectId})
If oResponse.Exists = False Then
Return False
End If
Catch ex As Exception
_logger.Error(ex)
Return False
End Try
' TODO: Check if Attribute exists
Dim oType = pValue.GetType.Name Dim oType = pValue.GetType.Name
If oType = GetType(DataTable).Name Then If oType = GetType(DataTable).Name Then
Dim oDTMyNewValues As DataTable = pValue Dim oValueTable As DataTable = pValue
Dim oOldAttributeResult As Object Dim oCurrentValue As Object
Dim oTypeOldResult As Object Dim oCurrentValueType As String
If pOptions.CheckDeleted = True Then If pOptions.CheckDeleted = True Then
oOldAttributeResult = GetVariableValue(pAttributeName, pAttributeType) Dim oOptions As New GetVariableValueOptions With {
oTypeOldResult = oOldAttributeResult.GetType.Name .Language = oLanguage,
If oTypeOldResult = GetType(DataTable).Name Then .Username = oUsername
Dim oOldValues As DataTable = oOldAttributeResult }
If oOldValues.Rows.Count > 1 Then
' Get current value
oCurrentValue = GetVariableValue(pObjectId, pAttributeName, pAttributeType, oOptions)
' Get current type
oCurrentValueType = oCurrentValue.GetType.Name
' If current value is datatable
If oCurrentValueType = GetType(DataTable).Name Then
' Convert value to Datatable
Dim oCurrentTable As DataTable = oCurrentValue
If oCurrentTable.Rows.Count > 1 Then
'now Checking whether the old row still remains in Vector? If not it will be deleted as it cannot be replaced in multivalues 'now Checking whether the old row still remains in Vector? If not it will be deleted as it cannot be replaced in multivalues
For Each oOldValueRow As DataRow In oOldValues.Rows For Each oRow As DataRow In oCurrentTable.Rows
Dim oExists As Boolean = False Dim oExists As Boolean = False
For Each oNewValueRow As DataRow In oDTMyNewValues.Rows For Each oNewValueRow As DataRow In oValueTable.Rows
Dim oInfo = $"Checking oldValue[{oOldValueRow.Item(0)}] vs NewValue [{oNewValueRow.Item(1)}]" Dim oInfo = $"Checking oldValue[{oRow.Item(0)}] vs NewValue [{oNewValueRow.Item(1)}]"
If oNewValueRow.Item(1).ToString.ToUpper = oOldValueRow.Item(0).ToString.ToUpper Then If oNewValueRow.Item(1).ToString.ToUpper = oRow.Item(0).ToString.ToUpper Then
oExists = True oExists = True
Exit For Exit For
End If End If
Next Next
If oExists = False Then If oExists = False Then
Dim oInfo = $"Value [{oOldValueRow.Item(0)}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!" _logger.Debug($"Value [{oRow.Item(0)}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!")
_logger.Debug(oInfo) DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oRow.Item(0))
SetVariableValue(pObjectId, My.Application.Globix.CURRENT_PROFILE_LOG_INDEX, AttributeType.Varchar, oInfo)
DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oOldValueRow.Item(0))
End If End If
Next Next
End If End If
Else Else
If oDTMyNewValues.Rows.Count > 1 Then If oValueTable.Rows.Count > 1 Then
Dim oExists As Boolean = False Dim oExists As Boolean = False
For Each oNewValueRow As DataRow In oDTMyNewValues.Rows For Each oNewValueRow As DataRow In oValueTable.Rows
Dim oInfo1 = $"Checking oldValue[{oOldAttributeResult}] vs NewValue [{oNewValueRow.Item(1)}]" _logger.Debug($"Checking oldValue[{oCurrentValue}] vs NewValue [{oNewValueRow.Item(1)}]")
If oNewValueRow.Item(1).ToString.ToUpper = oOldAttributeResult.ToString.ToUpper Then
If oNewValueRow.Item(1).ToString.ToUpper = oCurrentValue.ToString.ToUpper Then
oExists = True oExists = True
Exit For Exit For
End If End If
Next Next
If oExists = False Then If oExists = False Then
Dim oInfo = $"Value [{oOldAttributeResult}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!" _logger.Debug($"Value [{oCurrentValue}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!")
_logger.Debug(oInfo) DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oCurrentValue)
SetVariableValue(pObjectId, My.Application.Globix.CURRENT_PROFILE_LOG_INDEX, AttributeType.Varchar, oInfo)
DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oOldAttributeResult)
End If End If
Else Else
Dim oInfo = $"Value [{oOldAttributeResult}] of Attribute [{pAttributeName}] obviously was updated during runtime - will be deleted!" _logger.Debug($"Value [{oCurrentValue}] of Attribute [{pAttributeName}] obviously was updated during runtime - will be deleted!")
_logger.Debug(oInfo) DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oCurrentValue)
SetVariableValue(pObjectId, My.Application.Globix.CURRENT_PROFILE_LOG_INDEX, AttributeType.Varchar, oInfo)
DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oOldAttributeResult)
End If End If
End If End If
End If End If
For Each oNewValueRow As DataRow In oDTMyNewValues.Rows For Each oNewValueRow As DataRow In oValueTable.Rows
Dim oSuccess As Boolean = False Dim oSuccess As Boolean = False
Dim oSQL = $"DECLARE @NEW_OBJ_MD_ID BIGINT Dim oSQL = $"DECLARE @NEW_OBJ_MD_ID BIGINT
EXEC PRIDB_NEW_OBJ_DATA({pObjectId}, '{pAttributeName}', '{oUsername}', '{oNewValueRow.Item(1)}', '{oLanguage}', 0, @OMD_ID = @NEW_OBJ_MD_ID OUTPUT)" EXEC PRIDB_NEW_OBJ_DATA({pObjectId}, '{pAttributeName}', '{oUsername}', '{oNewValueRow.Item(1)}', '{oLanguage}', 0, @OMD_ID = @NEW_OBJ_MD_ID OUTPUT)"
@ -324,21 +355,57 @@ Public Class Client
Dim oLanguage = NotNull(pOptions.Language, GetUserLanguage()) Dim oLanguage = NotNull(pOptions.Language, GetUserLanguage())
Dim oUsername = NotNull(pOptions.Username, Environment.UserName) Dim oUsername = NotNull(pOptions.Username, Environment.UserName)
' Check if ObjectId exists
Try Try
Dim oSingleAttribute As Boolean Dim oResponse = _channel.TestObjectIdExists(New TestObjectIdExistsRequest With {.ObjectId = pObjectId})
If oResponse.Exists = False Then
Return Nothing
End If
Catch ex As Exception
_logger.Error(ex)
Return Nothing
End Try
' Get Attributes and Values from Database
Dim oTable As DataTable
Try
Dim oResult As TableResult = _channel.ReturnDatatable_MSSQL_IDB($"EXEC [PRIDB_GET_VALUE_DT]({pObjectId}, '{oLanguage}')")
If oResult.OK = False Then
Throw New ApplicationException(oResult.ErrorMessage)
End If
If oResult.Table Is Nothing OrElse oResult.Table.Rows.Count = 0 Then
Return Nothing
End If
oTable = oResult.Table
Catch ex As Exception
_logger.Error(ex)
Return Nothing
End Try
' TODO: Check if Attribute exists & REfactor
Try
Dim oVectorAttribute As Boolean = False
Select Case pAttributeType Select Case pAttributeType
Case AttributeType.VectorInteger Case AttributeType.VectorInteger
oSingleAttribute = False oVectorAttribute = True
Case AttributeType.VectorString Case AttributeType.VectorString
oSingleAttribute = False oVectorAttribute = True
Case Else Case Else
oSingleAttribute = True oVectorAttribute = False
End Select End Select
Dim oAttributeValue As Object = Nothing Dim oAttributeValue As Object = Nothing
If Not IsNothing(My.Tables.DTIDB_DOC_DATA) Then If Not IsNothing(_dummy_table_attributes) Then
If oSingleAttribute = True And My.Tables.DTIDB_DOC_DATA.Rows.Count = 1 And pOptions.FromIDB = False Then If oVectorAttribute = True And _dummy_table_attributes.Rows.Count = 1 And pOptions.FromIDB = False Then
Try Try
If pAttributeName = "IDBCreatedWhen" Then If pAttributeName = "IDBCreatedWhen" Then
pAttributeName = "ADDED_WHEN" pAttributeName = "ADDED_WHEN"
@ -350,7 +417,7 @@ Public Class Client
pAttributeName = "CHANGED_WHO" pAttributeName = "CHANGED_WHO"
End If End If
oAttributeValue = My.Tables.DTIDB_DOC_DATA.Rows(0).Item(pAttributeName) oAttributeValue = _dummy_table_attributes.Rows(0).Item(pAttributeName)
Catch ex As Exception Catch ex As Exception
_logger.Debug($"Error getting Attribute from IDB_DT_DOC_DATA: {ex.Message}") _logger.Debug($"Error getting Attribute from IDB_DT_DOC_DATA: {ex.Message}")
End Try End Try
@ -367,17 +434,18 @@ Public Class Client
Dim oDatatable As TableResult = _channel.ReturnDatatable_MSSQL_IDB(oFNSQL) Dim oDatatable As TableResult = _channel.ReturnDatatable_MSSQL_IDB(oFNSQL)
If oDatatable.OK = False Then If oDatatable.OK = False Then
_logger.Warn(oDatatable.ErrorMessage) Throw New ApplicationException(oDatatable.ErrorMessage)
Return Nothing
End If End If
If oDatatable.Table.Rows.Count = 1 Then If oDatatable.Table.Rows.Count = 1 Then
oAttributeValue = oDatatable.Table.Rows.Item(0).Item(0) oAttributeValue = oDatatable.Table.Rows.Item(0).Item(0)
End If End If
Return oAttributeValue Return oAttributeValue
Catch ex As Exception Catch ex As Exception
_logger.Error(ex) _logger.Error(ex)
Return Nothing Return Nothing
End Try End Try
End Function End Function
@ -397,90 +465,6 @@ Public Class Client
End Try End Try
End Function End Function
'Public Function CreateObjectId(pKindType As String, pWho As String, pBusinessEntity As String) As Long
' Try
' Dim oResponse = _channel.NewObjectId(New NewObjectIdRequest With {
' .KindType = pKindType,
' .BusinessEntity = pBusinessEntity,
' .Who = pWho
' })
' Return oResponse.ObjectId
' Catch ex As Exception
' _logger.Error(ex)
' Throw ex
' End Try
'End Function
'Public Function CreateFileStoreObject(pObjectId As Long, pStoreType As String, pDate As String, pExtension As String, pKeepExtension As String) As String
' Try
' ' Remove dot in Extension
' If pExtension.StartsWith(".") Then
' pExtension = pExtension.Substring(1)
' End If
' Dim oArgs As New NewFileObjectRequest With {
' .ObjectId = pObjectId,
' .StoreType = pStoreType,
' .DateImported = pDate,
' .Extension = pExtension,
' .KeepExtension = pKeepExtension
' }
' Dim oResponse = _channel.NewFileObject(oArgs)
' Return oResponse.FileObjectPath
' Catch ex As Exception
' _logger.Error(ex)
' Throw ex
' End Try
'End Function
'Public Async Function ImportFileObjectAsync(pContent As Byte(), pWho As String, pObjectId As Long, pObjectStoreType As String, pFileObjectPath As String) As Task(Of Boolean)
' Try
' Dim oData As New ImportFileIntoFileObjectRequest() With {
' .Contents = pContent,
' .Who = pWho,
' .FilePath = pFileObjectPath,
' .ObjectId = pObjectId,
' .ObjectStoreType = pObjectStoreType
' }
' Dim oResponse = Await _channel.ImportFileIntoFileObjectAsync(oData)
' Return oResponse.Result
' Catch ex As Exception
' _logger.Error(ex)
' Return False
' End Try
'End Function
'Public Async Function GetFileByObjectIdAsync(ObjectId As Long) As Task(Of StreamedFile)
' Try
' Dim oData As New DocumentStreamRequest() With {.ObjectId = ObjectId}
' Dim oResponse As DocumentStreamResponse = Await _channel.GetFileByObjectIdAsync(oData)
' Dim oMemoryStream As New MemoryStream()
' oResponse.FileContents.CopyTo(oMemoryStream)
' oMemoryStream.Position = 0
' Return New StreamedFile() With {
' .Stream = oMemoryStream,
' .FileName = oResponse.FileName
' }
' Catch ex As Exception
' _logger.Error(ex)
' Throw ex
' End Try
'End Function
'Public Async Function ListFilesForUserAsync() As Task(Of FileList)
' Try
' Dim oResponse As DocumentListResponse = Await _channel.ListFilesForUserAsync(New ListFilesForUserRequest())
' Return New FileList() With {
' .Datatable = oResponse.Datatable
' }
' Catch ex As Exception
' _logger.Error(ex)
' Throw ex
' End Try
'End Function
Public Function GetDatatableFromIDB(SQL As String) As TableResult Public Function GetDatatableFromIDB(SQL As String) As TableResult
Try Try
Dim oResponse = _channel.ReturnDatatable_MSSQL_IDB(SQL) Dim oResponse = _channel.ReturnDatatable_MSSQL_IDB(SQL)

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="TestObjectIdExistsResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.TestObjectIdExistsResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@ -178,6 +178,15 @@
<wsdl:message name="IEDMIService_ImportFileIntoFileObject_UnexpectedErrorFaultFault_FaultMessage"> <wsdl:message name="IEDMIService_ImportFileIntoFileObject_UnexpectedErrorFaultFault_FaultMessage">
<wsdl:part xmlns:q19="http://schemas.datacontract.org/2004/07/DigitalData.Services.EDMIService.Exceptions" name="detail" element="q19:UnexpectedErrorFault" /> <wsdl:part xmlns:q19="http://schemas.datacontract.org/2004/07/DigitalData.Services.EDMIService.Exceptions" name="detail" element="q19:UnexpectedErrorFault" />
</wsdl:message> </wsdl:message>
<wsdl:message name="TestObjectIdExistsRequest">
<wsdl:part name="parameters" element="tns:TestObjectIdExistsRequest" />
</wsdl:message>
<wsdl:message name="TestObjectIdExistsResponse">
<wsdl:part name="parameters" element="tns:TestObjectIdExistsResponse" />
</wsdl:message>
<wsdl:message name="IEDMIService_TestObjectIdExists_UnexpectedErrorFaultFault_FaultMessage">
<wsdl:part xmlns:q20="http://schemas.datacontract.org/2004/07/DigitalData.Services.EDMIService.Exceptions" name="detail" element="q20:UnexpectedErrorFault" />
</wsdl:message>
<wsdl:portType name="IEDMIService"> <wsdl:portType name="IEDMIService">
<wsdl:operation name="Heartbeat"> <wsdl:operation name="Heartbeat">
<wsdl:input wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/Heartbeat" message="tns:IEDMIService_Heartbeat_InputMessage" /> <wsdl:input wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/Heartbeat" message="tns:IEDMIService_Heartbeat_InputMessage" />
@ -270,5 +279,10 @@
<wsdl:output wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObjectResponse" name="ImportFileIntoFileObjectResponse" message="tns:ImportFileIntoFileObjectResponse" /> <wsdl:output wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObjectResponse" name="ImportFileIntoFileObjectResponse" message="tns:ImportFileIntoFileObjectResponse" />
<wsdl:fault wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObjectUnexpectedErrorFaultFault" name="UnexpectedErrorFaultFault" message="tns:IEDMIService_ImportFileIntoFileObject_UnexpectedErrorFaultFault_FaultMessage" /> <wsdl:fault wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObjectUnexpectedErrorFaultFault" name="UnexpectedErrorFaultFault" message="tns:IEDMIService_ImportFileIntoFileObject_UnexpectedErrorFaultFault_FaultMessage" />
</wsdl:operation> </wsdl:operation>
<wsdl:operation name="TestObjectIdExists">
<wsdl:input wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExists" name="TestObjectIdExistsRequest" message="tns:TestObjectIdExistsRequest" />
<wsdl:output wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExistsResponse" name="TestObjectIdExistsResponse" message="tns:TestObjectIdExistsResponse" />
<wsdl:fault wsaw:Action="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExistsUnexpectedErrorFaultFault" name="UnexpectedErrorFaultFault" message="tns:IEDMIService_TestObjectIdExists_UnexpectedErrorFaultFault_FaultMessage" />
</wsdl:operation>
</wsdl:portType> </wsdl:portType>
</wsdl:definitions> </wsdl:definitions>

View File

@ -278,4 +278,20 @@
</xs:sequence> </xs:sequence>
</xs:complexType> </xs:complexType>
</xs:element> </xs:element>
<xs:element name="TestObjectIdExistsRequest">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="ObjectId" type="xs:long" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="TestObjectIdExistsResponse">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="Deleted" type="xs:boolean" />
<xs:element minOccurs="0" name="Exists" type="xs:boolean" />
<xs:element minOccurs="0" name="Inactive" type="xs:boolean" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema> </xs:schema>

View File

@ -475,6 +475,16 @@ Namespace EDMIServiceReference
<System.ServiceModel.OperationContractAttribute(Action:="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObject", ReplyAction:="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObjectResp"& _ <System.ServiceModel.OperationContractAttribute(Action:="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObject", ReplyAction:="http://DigitalData.Services.EDMIService/IEDMIService/ImportFileIntoFileObjectResp"& _
"onse")> _ "onse")> _
Function ImportFileIntoFileObjectAsync(ByVal request As EDMIServiceReference.ImportFileIntoFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.ImportFileIntoFileObjectResponse) Function ImportFileIntoFileObjectAsync(ByVal request As EDMIServiceReference.ImportFileIntoFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.ImportFileIntoFileObjectResponse)
<System.ServiceModel.OperationContractAttribute(Action:="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExists", ReplyAction:="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExistsResponse"), _
System.ServiceModel.FaultContractAttribute(GetType(EDMIServiceReference.UnexpectedErrorFault), Action:="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExistsUnexpected"& _
"ErrorFaultFault", Name:="UnexpectedErrorFault", [Namespace]:="http://schemas.datacontract.org/2004/07/DigitalData.Services.EDMIService.Exceptio"& _
"ns")> _
Function TestObjectIdExists(ByVal request As EDMIServiceReference.TestObjectIdExistsRequest) As EDMIServiceReference.TestObjectIdExistsResponse
'CODEGEN: Der Nachrichtenvertrag wird generiert, da der Vorgang mehrere Rückgabewerte aufweist.
<System.ServiceModel.OperationContractAttribute(Action:="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExists", ReplyAction:="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExistsResponse")> _
Function TestObjectIdExistsAsync(ByVal request As EDMIServiceReference.TestObjectIdExistsRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.TestObjectIdExistsResponse)
End Interface End Interface
<System.Diagnostics.DebuggerStepThroughAttribute(), _ <System.Diagnostics.DebuggerStepThroughAttribute(), _
@ -756,16 +766,16 @@ Namespace EDMIServiceReference
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=0)> _ <System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=0)> _
Public Contents() As Byte Public Contents() As Byte
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=1)> <System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=1)> _
Public FilePath As String Public FilePath As String
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=2)> <System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=2)> _
Public ObjectId As Long Public ObjectId As Long
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=3)> <System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=3)> _
Public ObjectStoreType As String Public ObjectStoreType As String
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=4)> <System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=4)> _
Public Who As String Public Who As String
Public Sub New() Public Sub New()
@ -782,13 +792,13 @@ Namespace EDMIServiceReference
End Sub End Sub
End Class End Class
<System.Diagnostics.DebuggerStepThroughAttribute(), <System.Diagnostics.DebuggerStepThroughAttribute(), _
System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0"), System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0"), _
System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced), System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced), _
System.ServiceModel.MessageContractAttribute(WrapperName:="ImportFileIntoFileObjectResponse", WrapperNamespace:="http://DigitalData.Services.EDMIService", IsWrapped:=True)> System.ServiceModel.MessageContractAttribute(WrapperName:="ImportFileIntoFileObjectResponse", WrapperNamespace:="http://DigitalData.Services.EDMIService", IsWrapped:=true)> _
Partial Public Class ImportFileIntoFileObjectResponse Partial Public Class ImportFileIntoFileObjectResponse
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=0)> <System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=0)> _
Public Result As Boolean Public Result As Boolean
Public Sub New() Public Sub New()
@ -801,13 +811,57 @@ Namespace EDMIServiceReference
End Sub End Sub
End Class End Class
<System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")> <System.Diagnostics.DebuggerStepThroughAttribute(), _
System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0"), _
System.ServiceModel.MessageContractAttribute(WrapperName:="TestObjectIdExistsRequest", WrapperNamespace:="http://DigitalData.Services.EDMIService", IsWrapped:=true)> _
Partial Public Class TestObjectIdExistsRequest
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=0)> _
Public ObjectId As Long
Public Sub New()
MyBase.New
End Sub
Public Sub New(ByVal ObjectId As Long)
MyBase.New
Me.ObjectId = ObjectId
End Sub
End Class
<System.Diagnostics.DebuggerStepThroughAttribute(), _
System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0"), _
System.ServiceModel.MessageContractAttribute(WrapperName:="TestObjectIdExistsResponse", WrapperNamespace:="http://DigitalData.Services.EDMIService", IsWrapped:=true)> _
Partial Public Class TestObjectIdExistsResponse
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=0)> _
Public Deleted As Boolean
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=1)> _
Public Exists As Boolean
<System.ServiceModel.MessageBodyMemberAttribute([Namespace]:="http://DigitalData.Services.EDMIService", Order:=2)> _
Public Inactive As Boolean
Public Sub New()
MyBase.New
End Sub
Public Sub New(ByVal Deleted As Boolean, ByVal Exists As Boolean, ByVal Inactive As Boolean)
MyBase.New
Me.Deleted = Deleted
Me.Exists = Exists
Me.Inactive = Inactive
End Sub
End Class
<System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")> _
Public Interface IEDMIServiceChannel Public Interface IEDMIServiceChannel
Inherits EDMIServiceReference.IEDMIService, System.ServiceModel.IClientChannel Inherits EDMIServiceReference.IEDMIService, System.ServiceModel.IClientChannel
End Interface End Interface
<System.Diagnostics.DebuggerStepThroughAttribute(), <System.Diagnostics.DebuggerStepThroughAttribute(), _
System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")> System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")> _
Partial Public Class EDMIServiceClient Partial Public Class EDMIServiceClient
Inherits System.ServiceModel.ClientBase(Of EDMIServiceReference.IEDMIService) Inherits System.ServiceModel.ClientBase(Of EDMIServiceReference.IEDMIService)
Implements EDMIServiceReference.IEDMIService Implements EDMIServiceReference.IEDMIService
@ -920,7 +974,7 @@ Namespace EDMIServiceReference
Return MyBase.Channel.ExecuteNonQuery_MSSQL_ECMAsync(SQL) Return MyBase.Channel.ExecuteNonQuery_MSSQL_ECMAsync(SQL)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_ImportFile(ByVal request As EDMIServiceReference.DocumentImportRequest) As EDMIServiceReference.DocumentImportResponse Implements EDMIServiceReference.IEDMIService.ImportFile Function EDMIServiceReference_IEDMIService_ImportFile(ByVal request As EDMIServiceReference.DocumentImportRequest) As EDMIServiceReference.DocumentImportResponse Implements EDMIServiceReference.IEDMIService.ImportFile
Return MyBase.Channel.ImportFile(request) Return MyBase.Channel.ImportFile(request)
End Function End Function
@ -936,7 +990,7 @@ Namespace EDMIServiceReference
Return retVal.ObjectId Return retVal.ObjectId
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_ImportFileAsync(ByVal request As EDMIServiceReference.DocumentImportRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.DocumentImportResponse) Implements EDMIServiceReference.IEDMIService.ImportFileAsync Function EDMIServiceReference_IEDMIService_ImportFileAsync(ByVal request As EDMIServiceReference.DocumentImportRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.DocumentImportResponse) Implements EDMIServiceReference.IEDMIService.ImportFileAsync
Return MyBase.Channel.ImportFileAsync(request) Return MyBase.Channel.ImportFileAsync(request)
End Function End Function
@ -951,7 +1005,7 @@ Namespace EDMIServiceReference
Return CType(Me,EDMIServiceReference.IEDMIService).ImportFileAsync(inValue) Return CType(Me,EDMIServiceReference.IEDMIService).ImportFileAsync(inValue)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_GetFileByObjectId(ByVal request As EDMIServiceReference.DocumentStreamRequest) As EDMIServiceReference.DocumentStreamResponse Implements EDMIServiceReference.IEDMIService.GetFileByObjectId Function EDMIServiceReference_IEDMIService_GetFileByObjectId(ByVal request As EDMIServiceReference.DocumentStreamRequest) As EDMIServiceReference.DocumentStreamResponse Implements EDMIServiceReference.IEDMIService.GetFileByObjectId
Return MyBase.Channel.GetFileByObjectId(request) Return MyBase.Channel.GetFileByObjectId(request)
End Function End Function
@ -964,7 +1018,7 @@ Namespace EDMIServiceReference
Return retVal.FileName Return retVal.FileName
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_GetFileByObjectIdAsync(ByVal request As EDMIServiceReference.DocumentStreamRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.DocumentStreamResponse) Implements EDMIServiceReference.IEDMIService.GetFileByObjectIdAsync Function EDMIServiceReference_IEDMIService_GetFileByObjectIdAsync(ByVal request As EDMIServiceReference.DocumentStreamRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.DocumentStreamResponse) Implements EDMIServiceReference.IEDMIService.GetFileByObjectIdAsync
Return MyBase.Channel.GetFileByObjectIdAsync(request) Return MyBase.Channel.GetFileByObjectIdAsync(request)
End Function End Function
@ -975,7 +1029,7 @@ Namespace EDMIServiceReference
Return CType(Me,EDMIServiceReference.IEDMIService).GetFileByObjectIdAsync(inValue) Return CType(Me,EDMIServiceReference.IEDMIService).GetFileByObjectIdAsync(inValue)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_GetFileInfoByObjectId(ByVal request As EDMIServiceReference.DocumentInfoRequest) As EDMIServiceReference.DocumentInfoResponse Implements EDMIServiceReference.IEDMIService.GetFileInfoByObjectId Function EDMIServiceReference_IEDMIService_GetFileInfoByObjectId(ByVal request As EDMIServiceReference.DocumentInfoRequest) As EDMIServiceReference.DocumentInfoResponse Implements EDMIServiceReference.IEDMIService.GetFileInfoByObjectId
Return MyBase.Channel.GetFileInfoByObjectId(request) Return MyBase.Channel.GetFileInfoByObjectId(request)
End Function End Function
@ -993,7 +1047,7 @@ Namespace EDMIServiceReference
Return MyBase.Channel.GetFileInfoByObjectIdAsync(request) Return MyBase.Channel.GetFileInfoByObjectIdAsync(request)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_ListFilesForUser(ByVal request As EDMIServiceReference.ListFilesForUserRequest) As EDMIServiceReference.DocumentListResponse Implements EDMIServiceReference.IEDMIService.ListFilesForUser Function EDMIServiceReference_IEDMIService_ListFilesForUser(ByVal request As EDMIServiceReference.ListFilesForUserRequest) As EDMIServiceReference.DocumentListResponse Implements EDMIServiceReference.IEDMIService.ListFilesForUser
Return MyBase.Channel.ListFilesForUser(request) Return MyBase.Channel.ListFilesForUser(request)
End Function End Function
@ -1004,7 +1058,7 @@ Namespace EDMIServiceReference
Return retVal.Datatable Return retVal.Datatable
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_ListFilesForUserAsync(ByVal request As EDMIServiceReference.ListFilesForUserRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.DocumentListResponse) Implements EDMIServiceReference.IEDMIService.ListFilesForUserAsync Function EDMIServiceReference_IEDMIService_ListFilesForUserAsync(ByVal request As EDMIServiceReference.ListFilesForUserRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.DocumentListResponse) Implements EDMIServiceReference.IEDMIService.ListFilesForUserAsync
Return MyBase.Channel.ListFilesForUserAsync(request) Return MyBase.Channel.ListFilesForUserAsync(request)
End Function End Function
@ -1014,7 +1068,7 @@ Namespace EDMIServiceReference
Return CType(Me,EDMIServiceReference.IEDMIService).ListFilesForUserAsync(inValue) Return CType(Me,EDMIServiceReference.IEDMIService).ListFilesForUserAsync(inValue)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_NewObjectId(ByVal request As EDMIServiceReference.NewObjectIdRequest) As EDMIServiceReference.NewObjectIdResponse Implements EDMIServiceReference.IEDMIService.NewObjectId Function EDMIServiceReference_IEDMIService_NewObjectId(ByVal request As EDMIServiceReference.NewObjectIdRequest) As EDMIServiceReference.NewObjectIdResponse Implements EDMIServiceReference.IEDMIService.NewObjectId
Return MyBase.Channel.NewObjectId(request) Return MyBase.Channel.NewObjectId(request)
End Function End Function
@ -1028,7 +1082,7 @@ Namespace EDMIServiceReference
Return retVal.ObjectId Return retVal.ObjectId
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_NewObjectIdAsync(ByVal request As EDMIServiceReference.NewObjectIdRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.NewObjectIdResponse) Implements EDMIServiceReference.IEDMIService.NewObjectIdAsync Function EDMIServiceReference_IEDMIService_NewObjectIdAsync(ByVal request As EDMIServiceReference.NewObjectIdRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.NewObjectIdResponse) Implements EDMIServiceReference.IEDMIService.NewObjectIdAsync
Return MyBase.Channel.NewObjectIdAsync(request) Return MyBase.Channel.NewObjectIdAsync(request)
End Function End Function
@ -1041,7 +1095,7 @@ Namespace EDMIServiceReference
Return CType(Me,EDMIServiceReference.IEDMIService).NewObjectIdAsync(inValue) Return CType(Me,EDMIServiceReference.IEDMIService).NewObjectIdAsync(inValue)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_NewFileObject(ByVal request As EDMIServiceReference.NewFileObjectRequest) As EDMIServiceReference.NewFileObjectResponse Implements EDMIServiceReference.IEDMIService.NewFileObject Function EDMIServiceReference_IEDMIService_NewFileObject(ByVal request As EDMIServiceReference.NewFileObjectRequest) As EDMIServiceReference.NewFileObjectResponse Implements EDMIServiceReference.IEDMIService.NewFileObject
Return MyBase.Channel.NewFileObject(request) Return MyBase.Channel.NewFileObject(request)
End Function End Function
@ -1057,7 +1111,7 @@ Namespace EDMIServiceReference
Return retVal.FileObjectPath Return retVal.FileObjectPath
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_NewFileObjectAsync(ByVal request As EDMIServiceReference.NewFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.NewFileObjectResponse) Implements EDMIServiceReference.IEDMIService.NewFileObjectAsync Function EDMIServiceReference_IEDMIService_NewFileObjectAsync(ByVal request As EDMIServiceReference.NewFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.NewFileObjectResponse) Implements EDMIServiceReference.IEDMIService.NewFileObjectAsync
Return MyBase.Channel.NewFileObjectAsync(request) Return MyBase.Channel.NewFileObjectAsync(request)
End Function End Function
@ -1072,7 +1126,7 @@ Namespace EDMIServiceReference
Return CType(Me,EDMIServiceReference.IEDMIService).NewFileObjectAsync(inValue) Return CType(Me,EDMIServiceReference.IEDMIService).NewFileObjectAsync(inValue)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_ImportFileIntoFileObject(ByVal request As EDMIServiceReference.ImportFileIntoFileObjectRequest) As EDMIServiceReference.ImportFileIntoFileObjectResponse Implements EDMIServiceReference.IEDMIService.ImportFileIntoFileObject Function EDMIServiceReference_IEDMIService_ImportFileIntoFileObject(ByVal request As EDMIServiceReference.ImportFileIntoFileObjectRequest) As EDMIServiceReference.ImportFileIntoFileObjectResponse Implements EDMIServiceReference.IEDMIService.ImportFileIntoFileObject
Return MyBase.Channel.ImportFileIntoFileObject(request) Return MyBase.Channel.ImportFileIntoFileObject(request)
End Function End Function
@ -1088,7 +1142,7 @@ Namespace EDMIServiceReference
Return retVal.Result Return retVal.Result
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> <System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_ImportFileIntoFileObjectAsync(ByVal request As EDMIServiceReference.ImportFileIntoFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.ImportFileIntoFileObjectResponse) Implements EDMIServiceReference.IEDMIService.ImportFileIntoFileObjectAsync Function EDMIServiceReference_IEDMIService_ImportFileIntoFileObjectAsync(ByVal request As EDMIServiceReference.ImportFileIntoFileObjectRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.ImportFileIntoFileObjectResponse) Implements EDMIServiceReference.IEDMIService.ImportFileIntoFileObjectAsync
Return MyBase.Channel.ImportFileIntoFileObjectAsync(request) Return MyBase.Channel.ImportFileIntoFileObjectAsync(request)
End Function End Function
@ -1102,5 +1156,23 @@ Namespace EDMIServiceReference
inValue.Who = Who inValue.Who = Who
Return CType(Me,EDMIServiceReference.IEDMIService).ImportFileIntoFileObjectAsync(inValue) Return CType(Me,EDMIServiceReference.IEDMIService).ImportFileIntoFileObjectAsync(inValue)
End Function End Function
<System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)> _
Function EDMIServiceReference_IEDMIService_TestObjectIdExists(ByVal request As EDMIServiceReference.TestObjectIdExistsRequest) As EDMIServiceReference.TestObjectIdExistsResponse Implements EDMIServiceReference.IEDMIService.TestObjectIdExists
Return MyBase.Channel.TestObjectIdExists(request)
End Function
Public Function TestObjectIdExists(ByVal ObjectId As Long, <System.Runtime.InteropServices.OutAttribute()> ByRef Exists As Boolean, <System.Runtime.InteropServices.OutAttribute()> ByRef Inactive As Boolean) As Boolean
Dim inValue As EDMIServiceReference.TestObjectIdExistsRequest = New EDMIServiceReference.TestObjectIdExistsRequest()
inValue.ObjectId = ObjectId
Dim retVal As EDMIServiceReference.TestObjectIdExistsResponse = CType(Me,EDMIServiceReference.IEDMIService).TestObjectIdExists(inValue)
Exists = retVal.Exists
Inactive = retVal.Inactive
Return retVal.Deleted
End Function
Public Function TestObjectIdExistsAsync(ByVal request As EDMIServiceReference.TestObjectIdExistsRequest) As System.Threading.Tasks.Task(Of EDMIServiceReference.TestObjectIdExistsResponse) Implements EDMIServiceReference.IEDMIService.TestObjectIdExistsAsync
Return MyBase.Channel.TestObjectIdExistsAsync(request)
End Function
End Class End Class
End Namespace End Namespace

View File

@ -261,6 +261,18 @@
<soap12:fault use="literal" name="UnexpectedErrorFaultFault" namespace="" /> <soap12:fault use="literal" name="UnexpectedErrorFaultFault" namespace="" />
</wsdl:fault> </wsdl:fault>
</wsdl:operation> </wsdl:operation>
<wsdl:operation name="TestObjectIdExists">
<soap12:operation soapAction="http://DigitalData.Services.EDMIService/IEDMIService/TestObjectIdExists" style="document" />
<wsdl:input name="TestObjectIdExistsRequest">
<soap12:body use="literal" />
</wsdl:input>
<wsdl:output name="TestObjectIdExistsResponse">
<soap12:body use="literal" />
</wsdl:output>
<wsdl:fault name="UnexpectedErrorFaultFault">
<soap12:fault use="literal" name="UnexpectedErrorFaultFault" namespace="" />
</wsdl:fault>
</wsdl:operation>
</wsdl:binding> </wsdl:binding>
<wsdl:service name="EDMIService"> <wsdl:service name="EDMIService">
<wsdl:port name="NetTcpBinding_IEDMIService" binding="tns:NetTcpBinding_IEDMIService"> <wsdl:port name="NetTcpBinding_IEDMIService" binding="tns:NetTcpBinding_IEDMIService">

View File

@ -1,4 +1,6 @@
Public Class Constants Public Class Constants
Public Const DEFAULT_SERVICE_PORT = 9000
Public Enum DatabaseType Public Enum DatabaseType
ECM ECM
IDB IDB

View File

@ -142,6 +142,9 @@
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TableResult.datasource"> <None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TableResult.datasource">
<DependentUpon>Reference.svcmap</DependentUpon> <DependentUpon>Reference.svcmap</DependentUpon>
</None> </None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TestObjectIdExistsResponse.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.xsd"> <None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.xsd">
<SubType>Designer</SubType> <SubType>Designer</SubType>
</None> </None>

View File

@ -469,6 +469,32 @@ Public Class EDMIService
End Try End Try
End Function End Function
Public Function TestObjectIdExists(Data As TestObjectIdExistsRequest) As TestObjectIdExistsResponse Implements IEDMIService.TestObjectIdExists
Try
Dim oSQL As String = $"SELECT IDB_OBJ_ID, ACTIVE, DELETED FROM TBIDB_OBJECT WHERE IDB_OBJ_ID = {Data.ObjectId}"
Dim oTable As DataTable = MSSQL_IDB.GetDatatable(oSQL)
If IsNothing(oTable) OrElse oTable.Rows.Count = 0 Then
_Logger.Warn("ObjectId {0} does not exist")
Return New TestObjectIdExistsResponse(False)
End If
Dim oRow As DataRow = oTable.Rows.Item(0)
Dim oActive = Utils.NotNull(oRow.Item("ACTIVE"), False)
Dim oDeleted = Utils.NotNull(oRow.Item("DELETED"), False)
Return New TestObjectIdExistsResponse(True) With {
.Deleted = oDeleted,
.Inactive = Not oActive
}
Catch ex As Exception
_Logger.Error(ex)
Return New TestObjectIdExistsResponse(False)
End Try
End Function
Public Function NewFileObject(Data As NewFileObjectRequest) As NewFileObjectResponse Implements IEDMIService.NewFileObject Public Function NewFileObject(Data As NewFileObjectRequest) As NewFileObjectResponse Implements IEDMIService.NewFileObject
Try Try
Dim oStoreType As String = Data.StoreType Dim oStoreType As String = Data.StoreType

View File

@ -131,6 +131,28 @@ Namespace Messages
End Class End Class
#End Region #End Region
#Region "Helpers"
<MessageContract>
Public Class TestObjectIdExistsRequest
<MessageBodyMember>
Public ObjectId As Long
End Class
<MessageContract>
Public Class TestObjectIdExistsResponse
Public Sub New(pExists As Boolean)
Exists = pExists
End Sub
<MessageBodyMember>
Public Exists As Boolean = False
<MessageBodyMember>
Public Inactive As Boolean = False
<MessageBodyMember>
Public Deleted As Boolean = False
End Class
#End Region
End Namespace End Namespace

View File

@ -92,4 +92,10 @@ Interface IEDMIService
Function ImportFileIntoFileObject(Data As ImportFileIntoFileObjectRequest) As ImportFileIntoFileObjectResponse Function ImportFileIntoFileObject(Data As ImportFileIntoFileObjectRequest) As ImportFileIntoFileObjectResponse
#End Region #End Region
#Region "Helpers"
<OperationContract>
<FaultContract(GetType(UnexpectedErrorFault))>
Function TestObjectIdExists(Data As TestObjectIdExistsRequest) As TestObjectIdExistsResponse
#End Region
End Interface End Interface

View File

@ -38,7 +38,7 @@ Public Class WindowsService
Try Try
Dim oServicePath As String = AppDomain.CurrentDomain.BaseDirectory Dim oServicePath As String = AppDomain.CurrentDomain.BaseDirectory
_LogConfig = New LogConfig(LogConfig.PathType.CustomPath, IO.Path.Combine(oServicePath, "Log")) _LogConfig = New LogConfig(LogConfig.PathType.CustomPath, IO.Path.Combine(oServicePath, "Log"), Nothing, Nothing, Nothing, 3)
_Logger = _LogConfig.GetLogger() _Logger = _LogConfig.GetLogger()
Try Try