'' ------------------------------------------------------------------------------
''
'' Generated by Xsd2Code++. Version 6.0.0.0. www.xsd2code.com
'' {"TargetFramework":"Net47","NameSpace":"UeberlassungsmeldungNCTSDE_009","Language":"VisualBasic","Properties":{},"XmlAttribute":{"Enabled":true},"ClassParams":{},"Serialization":{"ShouldSerialize":{},"AdditionalSerializers":{},"XmlSerializerEvent":{},"XmlOutput":{},"JsonOutput":{},"Enabled":true,"DefaultEncoder":"ASCII"},"Miscellaneous":{}}
''
'' ------------------------------------------------------------------------------
#Disable Warning
Imports System
Imports System.Diagnostics
Imports System.Xml.Serialization
Imports System.Runtime.Serialization
Imports System.Collections
Imports System.Xml.Schema
Imports System.ComponentModel
Imports System.Xml
Imports System.IO
Imports System.Text
Imports System.Collections.Generic
Namespace UeberlassungsmeldungNCTSDE_009
Partial Public Class UeberlassungsmeldungMRTyp
Inherits DatenaustauschNCTSTyp
#Region "Private fields"
Private _einzelUeberlassungsmeldung As EinzelUeberlassungsmeldungTyp
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._einzelUeberlassungsmeldung = New EinzelUeberlassungsmeldungTyp()
End Sub
Public Property EinzelUeberlassungsmeldung() As EinzelUeberlassungsmeldungTyp
Get
Return Me._einzelUeberlassungsmeldung
End Get
Set
Me._einzelUeberlassungsmeldung = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(UeberlassungsmeldungMRTyp))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize UeberlassungsmeldungMRTyp object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes UeberlassungsmeldungMRTyp object
'''
''' string to deserialize
''' Output UeberlassungsmeldungMRTyp object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As UeberlassungsmeldungMRTyp, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, UeberlassungsmeldungMRTyp)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As UeberlassungsmeldungMRTyp) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As UeberlassungsmeldungMRTyp
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), UeberlassungsmeldungMRTyp)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As UeberlassungsmeldungMRTyp
Return CType(SerializerXml.Deserialize(s), UeberlassungsmeldungMRTyp)
End Function
#End Region
'''
''' Serializes current UeberlassungsmeldungMRTyp object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an UeberlassungsmeldungMRTyp object
'''
''' File to load and deserialize
''' Output UeberlassungsmeldungMRTyp object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As UeberlassungsmeldungMRTyp, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, UeberlassungsmeldungMRTyp)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As UeberlassungsmeldungMRTyp) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As UeberlassungsmeldungMRTyp
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class EinzelUeberlassungsmeldungTyp
#Region "Private fields"
Private _objektIdentifizierung As ObjektIdentifizierungMRTyp
Private _kopfDaten As KopfDatenUeberlassungsmeldungTyp
Private _warenPosition As List(Of WarenPositionUeberlassungsmeldungTyp)
Private _transitOperation As TransitOperationMRType
Private _attachments As List(Of AttachmentMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._attachments = New List(Of AttachmentMRType)()
Me._transitOperation = New TransitOperationMRType()
Me._warenPosition = New List(Of WarenPositionUeberlassungsmeldungTyp)()
Me._kopfDaten = New KopfDatenUeberlassungsmeldungTyp()
Me._objektIdentifizierung = New ObjektIdentifizierungMRTyp()
End Sub
Public Property ObjektIdentifizierung() As ObjektIdentifizierungMRTyp
Get
Return Me._objektIdentifizierung
End Get
Set
Me._objektIdentifizierung = Value
End Set
End Property
Public Property KopfDaten() As KopfDatenUeberlassungsmeldungTyp
Get
Return Me._kopfDaten
End Get
Set
Me._kopfDaten = Value
End Set
End Property
Public Property WarenPosition() As List(Of WarenPositionUeberlassungsmeldungTyp)
Get
Return Me._warenPosition
End Get
Set
Me._warenPosition = Value
End Set
End Property
Public Property TransitOperation() As TransitOperationMRType
Get
Return Me._transitOperation
End Get
Set
Me._transitOperation = Value
End Set
End Property
Public Property Attachments() As List(Of AttachmentMRType)
Get
Return Me._attachments
End Get
Set
Me._attachments = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(EinzelUeberlassungsmeldungTyp))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize EinzelUeberlassungsmeldungTyp object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes EinzelUeberlassungsmeldungTyp object
'''
''' string to deserialize
''' Output EinzelUeberlassungsmeldungTyp object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As EinzelUeberlassungsmeldungTyp, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, EinzelUeberlassungsmeldungTyp)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As EinzelUeberlassungsmeldungTyp) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As EinzelUeberlassungsmeldungTyp
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), EinzelUeberlassungsmeldungTyp)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As EinzelUeberlassungsmeldungTyp
Return CType(SerializerXml.Deserialize(s), EinzelUeberlassungsmeldungTyp)
End Function
#End Region
'''
''' Serializes current EinzelUeberlassungsmeldungTyp object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an EinzelUeberlassungsmeldungTyp object
'''
''' File to load and deserialize
''' Output EinzelUeberlassungsmeldungTyp object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As EinzelUeberlassungsmeldungTyp, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, EinzelUeberlassungsmeldungTyp)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As EinzelUeberlassungsmeldungTyp) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As EinzelUeberlassungsmeldungTyp
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ObjektIdentifizierungMRTyp
#Region "Private fields"
Private _objektName As String
Private _objektAlias As String
Private _eDIFACTNachrichtenNr As String
Private _zeitpunktEingang As Date
Private _shipmentReferenz As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property ObjektName() As String
Get
Return Me._objektName
End Get
Set
Me._objektName = Value
End Set
End Property
Public Property ObjektAlias() As String
Get
Return Me._objektAlias
End Get
Set
Me._objektAlias = Value
End Set
End Property
Public Property EDIFACTNachrichtenNr() As String
Get
Return Me._eDIFACTNachrichtenNr
End Get
Set
Me._eDIFACTNachrichtenNr = Value
End Set
End Property
Public Property ZeitpunktEingang() As Date
Get
Return Me._zeitpunktEingang
End Get
Set
Me._zeitpunktEingang = Value
End Set
End Property
Public Property ShipmentReferenz() As String
Get
Return Me._shipmentReferenz
End Get
Set
Me._shipmentReferenz = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ObjektIdentifizierungMRTyp))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ObjektIdentifizierungMRTyp object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ObjektIdentifizierungMRTyp object
'''
''' string to deserialize
''' Output ObjektIdentifizierungMRTyp object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ObjektIdentifizierungMRTyp, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ObjektIdentifizierungMRTyp)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ObjektIdentifizierungMRTyp) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ObjektIdentifizierungMRTyp
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ObjektIdentifizierungMRTyp)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ObjektIdentifizierungMRTyp
Return CType(SerializerXml.Deserialize(s), ObjektIdentifizierungMRTyp)
End Function
#End Region
'''
''' Serializes current ObjektIdentifizierungMRTyp object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ObjektIdentifizierungMRTyp object
'''
''' File to load and deserialize
''' Output ObjektIdentifizierungMRTyp object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ObjektIdentifizierungMRTyp, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ObjektIdentifizierungMRTyp)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ObjektIdentifizierungMRTyp) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ObjektIdentifizierungMRTyp
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class AttachmentMRType
#Region "Private fields"
Private _technicalContent As String
Private _originalFilename As String
Private _fileFormat As String
Private _dataEncoding As String
Private _data As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property TechnicalContent() As String
Get
Return Me._technicalContent
End Get
Set
Me._technicalContent = Value
End Set
End Property
Public Property OriginalFilename() As String
Get
Return Me._originalFilename
End Get
Set
Me._originalFilename = Value
End Set
End Property
Public Property FileFormat() As String
Get
Return Me._fileFormat
End Get
Set
Me._fileFormat = Value
End Set
End Property
Public Property DataEncoding() As String
Get
Return Me._dataEncoding
End Get
Set
Me._dataEncoding = Value
End Set
End Property
Public Property Data() As String
Get
Return Me._data
End Get
Set
Me._data = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(AttachmentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize AttachmentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes AttachmentMRType object
'''
''' string to deserialize
''' Output AttachmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AttachmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AttachmentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AttachmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As AttachmentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), AttachmentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As AttachmentMRType
Return CType(SerializerXml.Deserialize(s), AttachmentMRType)
End Function
#End Region
'''
''' Serializes current AttachmentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an AttachmentMRType object
'''
''' File to load and deserialize
''' Output AttachmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AttachmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AttachmentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AttachmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As AttachmentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class InwardProcessingGoodsReferenceMRType
#Region "Private fields"
Private _sequenceNumber As String
Private _accessViaATLAS As String
Private _registrationNumber As String
Private _deprecatedFurtherRegistrationnumber As String
Private _goodsItemNumber As String
Private _goodsRelatedData As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property SequenceNumber() As String
Get
Return Me._sequenceNumber
End Get
Set
Me._sequenceNumber = Value
End Set
End Property
Public Property AccessViaATLAS() As String
Get
Return Me._accessViaATLAS
End Get
Set
Me._accessViaATLAS = Value
End Set
End Property
Public Property RegistrationNumber() As String
Get
Return Me._registrationNumber
End Get
Set
Me._registrationNumber = Value
End Set
End Property
Public Property DeprecatedFurtherRegistrationnumber() As String
Get
Return Me._deprecatedFurtherRegistrationnumber
End Get
Set
Me._deprecatedFurtherRegistrationnumber = Value
End Set
End Property
Public Property GoodsItemNumber() As String
Get
Return Me._goodsItemNumber
End Get
Set
Me._goodsItemNumber = Value
End Set
End Property
Public Property GoodsRelatedData() As String
Get
Return Me._goodsRelatedData
End Get
Set
Me._goodsRelatedData = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(InwardProcessingGoodsReferenceMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize InwardProcessingGoodsReferenceMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes InwardProcessingGoodsReferenceMRType object
'''
''' string to deserialize
''' Output InwardProcessingGoodsReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As InwardProcessingGoodsReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, InwardProcessingGoodsReferenceMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As InwardProcessingGoodsReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As InwardProcessingGoodsReferenceMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), InwardProcessingGoodsReferenceMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As InwardProcessingGoodsReferenceMRType
Return CType(SerializerXml.Deserialize(s), InwardProcessingGoodsReferenceMRType)
End Function
#End Region
'''
''' Serializes current InwardProcessingGoodsReferenceMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an InwardProcessingGoodsReferenceMRType object
'''
''' File to load and deserialize
''' Output InwardProcessingGoodsReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As InwardProcessingGoodsReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, InwardProcessingGoodsReferenceMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As InwardProcessingGoodsReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As InwardProcessingGoodsReferenceMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class InwardProcessingMRType
#Region "Private fields"
Private _transference As String
Private _typeOfAuthorisation As String
Private _referenceNumberOfAuthorisation As String
Private _simplyGrantedAuthorisation As String
Private _customsOfficeOfSupervision As String
Private _inwardProcessingGoodsReference As List(Of InwardProcessingGoodsReferenceMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._inwardProcessingGoodsReference = New List(Of InwardProcessingGoodsReferenceMRType)()
End Sub
Public Property Transference() As String
Get
Return Me._transference
End Get
Set
Me._transference = Value
End Set
End Property
Public Property TypeOfAuthorisation() As String
Get
Return Me._typeOfAuthorisation
End Get
Set
Me._typeOfAuthorisation = Value
End Set
End Property
Public Property ReferenceNumberOfAuthorisation() As String
Get
Return Me._referenceNumberOfAuthorisation
End Get
Set
Me._referenceNumberOfAuthorisation = Value
End Set
End Property
Public Property SimplyGrantedAuthorisation() As String
Get
Return Me._simplyGrantedAuthorisation
End Get
Set
Me._simplyGrantedAuthorisation = Value
End Set
End Property
Public Property CustomsOfficeOfSupervision() As String
Get
Return Me._customsOfficeOfSupervision
End Get
Set
Me._customsOfficeOfSupervision = Value
End Set
End Property
Public Property InwardProcessingGoodsReference() As List(Of InwardProcessingGoodsReferenceMRType)
Get
Return Me._inwardProcessingGoodsReference
End Get
Set
Me._inwardProcessingGoodsReference = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(InwardProcessingMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize InwardProcessingMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes InwardProcessingMRType object
'''
''' string to deserialize
''' Output InwardProcessingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As InwardProcessingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, InwardProcessingMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As InwardProcessingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As InwardProcessingMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), InwardProcessingMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As InwardProcessingMRType
Return CType(SerializerXml.Deserialize(s), InwardProcessingMRType)
End Function
#End Region
'''
''' Serializes current InwardProcessingMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an InwardProcessingMRType object
'''
''' File to load and deserialize
''' Output InwardProcessingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As InwardProcessingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, InwardProcessingMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As InwardProcessingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As InwardProcessingMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class GoodsReductionAfterTreatmentMRType
#Region "Private fields"
Private _quantityOfGoodsReductionAfterTreatment As Decimal
Private _measurementUnitOfGoodsReductionAfterTreatment As String
Private _qualifierOfGoodsReductionAfterTreatment As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property QuantityOfGoodsReductionAfterTreatment() As Decimal
Get
Return Me._quantityOfGoodsReductionAfterTreatment
End Get
Set
Me._quantityOfGoodsReductionAfterTreatment = Value
End Set
End Property
Public Property MeasurementUnitOfGoodsReductionAfterTreatment() As String
Get
Return Me._measurementUnitOfGoodsReductionAfterTreatment
End Get
Set
Me._measurementUnitOfGoodsReductionAfterTreatment = Value
End Set
End Property
Public Property QualifierOfGoodsReductionAfterTreatment() As String
Get
Return Me._qualifierOfGoodsReductionAfterTreatment
End Get
Set
Me._qualifierOfGoodsReductionAfterTreatment = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(GoodsReductionAfterTreatmentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize GoodsReductionAfterTreatmentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes GoodsReductionAfterTreatmentMRType object
'''
''' string to deserialize
''' Output GoodsReductionAfterTreatmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GoodsReductionAfterTreatmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GoodsReductionAfterTreatmentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GoodsReductionAfterTreatmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As GoodsReductionAfterTreatmentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), GoodsReductionAfterTreatmentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As GoodsReductionAfterTreatmentMRType
Return CType(SerializerXml.Deserialize(s), GoodsReductionAfterTreatmentMRType)
End Function
#End Region
'''
''' Serializes current GoodsReductionAfterTreatmentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an GoodsReductionAfterTreatmentMRType object
'''
''' File to load and deserialize
''' Output GoodsReductionAfterTreatmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GoodsReductionAfterTreatmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GoodsReductionAfterTreatmentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GoodsReductionAfterTreatmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As GoodsReductionAfterTreatmentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class GoodsReductionMRType
#Region "Private fields"
Private _quantityOfGoodsReduction As Decimal
Private _measurementUnitOfGoodsReduction As String
Private _qualifierOfGoodsReduction As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property QuantityOfGoodsReduction() As Decimal
Get
Return Me._quantityOfGoodsReduction
End Get
Set
Me._quantityOfGoodsReduction = Value
End Set
End Property
Public Property MeasurementUnitOfGoodsReduction() As String
Get
Return Me._measurementUnitOfGoodsReduction
End Get
Set
Me._measurementUnitOfGoodsReduction = Value
End Set
End Property
Public Property QualifierOfGoodsReduction() As String
Get
Return Me._qualifierOfGoodsReduction
End Get
Set
Me._qualifierOfGoodsReduction = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(GoodsReductionMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize GoodsReductionMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes GoodsReductionMRType object
'''
''' string to deserialize
''' Output GoodsReductionMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GoodsReductionMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GoodsReductionMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GoodsReductionMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As GoodsReductionMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), GoodsReductionMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As GoodsReductionMRType
Return CType(SerializerXml.Deserialize(s), GoodsReductionMRType)
End Function
#End Region
'''
''' Serializes current GoodsReductionMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an GoodsReductionMRType object
'''
''' File to load and deserialize
''' Output GoodsReductionMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GoodsReductionMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GoodsReductionMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GoodsReductionMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As GoodsReductionMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class CustomsWarehousingGoodsReferenceMRType
#Region "Private fields"
Private _sequenceNumber As String
Private _commodityCode As String
Private _accessViaATLAS As String
Private _usualTreatment As String
Private _registrationNumber As String
Private _deprecatedFurtherRegistrationnumber As String
Private _goodsItemNumber As String
Private _complement As String
Private _goodsReduction As GoodsReductionMRType
Private _goodsReductionAfterTreatment As GoodsReductionAfterTreatmentMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._goodsReductionAfterTreatment = New GoodsReductionAfterTreatmentMRType()
Me._goodsReduction = New GoodsReductionMRType()
End Sub
Public Property SequenceNumber() As String
Get
Return Me._sequenceNumber
End Get
Set
Me._sequenceNumber = Value
End Set
End Property
Public Property CommodityCode() As String
Get
Return Me._commodityCode
End Get
Set
Me._commodityCode = Value
End Set
End Property
Public Property AccessViaATLAS() As String
Get
Return Me._accessViaATLAS
End Get
Set
Me._accessViaATLAS = Value
End Set
End Property
Public Property UsualTreatment() As String
Get
Return Me._usualTreatment
End Get
Set
Me._usualTreatment = Value
End Set
End Property
Public Property RegistrationNumber() As String
Get
Return Me._registrationNumber
End Get
Set
Me._registrationNumber = Value
End Set
End Property
Public Property DeprecatedFurtherRegistrationnumber() As String
Get
Return Me._deprecatedFurtherRegistrationnumber
End Get
Set
Me._deprecatedFurtherRegistrationnumber = Value
End Set
End Property
Public Property GoodsItemNumber() As String
Get
Return Me._goodsItemNumber
End Get
Set
Me._goodsItemNumber = Value
End Set
End Property
Public Property Complement() As String
Get
Return Me._complement
End Get
Set
Me._complement = Value
End Set
End Property
Public Property GoodsReduction() As GoodsReductionMRType
Get
Return Me._goodsReduction
End Get
Set
Me._goodsReduction = Value
End Set
End Property
Public Property GoodsReductionAfterTreatment() As GoodsReductionAfterTreatmentMRType
Get
Return Me._goodsReductionAfterTreatment
End Get
Set
Me._goodsReductionAfterTreatment = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(CustomsWarehousingGoodsReferenceMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize CustomsWarehousingGoodsReferenceMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes CustomsWarehousingGoodsReferenceMRType object
'''
''' string to deserialize
''' Output CustomsWarehousingGoodsReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CustomsWarehousingGoodsReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CustomsWarehousingGoodsReferenceMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CustomsWarehousingGoodsReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As CustomsWarehousingGoodsReferenceMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), CustomsWarehousingGoodsReferenceMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As CustomsWarehousingGoodsReferenceMRType
Return CType(SerializerXml.Deserialize(s), CustomsWarehousingGoodsReferenceMRType)
End Function
#End Region
'''
''' Serializes current CustomsWarehousingGoodsReferenceMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an CustomsWarehousingGoodsReferenceMRType object
'''
''' File to load and deserialize
''' Output CustomsWarehousingGoodsReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CustomsWarehousingGoodsReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CustomsWarehousingGoodsReferenceMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CustomsWarehousingGoodsReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As CustomsWarehousingGoodsReferenceMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class CustomsWarehousingMRType
#Region "Private fields"
Private _lRN As String
Private _transference As String
Private _typeOfAuthorisation As String
Private _referenceNumberOfAuthorisation As String
Private _customsWarehousingGoodsReference As List(Of CustomsWarehousingGoodsReferenceMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._customsWarehousingGoodsReference = New List(Of CustomsWarehousingGoodsReferenceMRType)()
End Sub
Public Property LRN() As String
Get
Return Me._lRN
End Get
Set
Me._lRN = Value
End Set
End Property
Public Property Transference() As String
Get
Return Me._transference
End Get
Set
Me._transference = Value
End Set
End Property
Public Property TypeOfAuthorisation() As String
Get
Return Me._typeOfAuthorisation
End Get
Set
Me._typeOfAuthorisation = Value
End Set
End Property
Public Property ReferenceNumberOfAuthorisation() As String
Get
Return Me._referenceNumberOfAuthorisation
End Get
Set
Me._referenceNumberOfAuthorisation = Value
End Set
End Property
Public Property CustomsWarehousingGoodsReference() As List(Of CustomsWarehousingGoodsReferenceMRType)
Get
Return Me._customsWarehousingGoodsReference
End Get
Set
Me._customsWarehousingGoodsReference = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(CustomsWarehousingMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize CustomsWarehousingMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes CustomsWarehousingMRType object
'''
''' string to deserialize
''' Output CustomsWarehousingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CustomsWarehousingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CustomsWarehousingMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CustomsWarehousingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As CustomsWarehousingMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), CustomsWarehousingMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As CustomsWarehousingMRType
Return CType(SerializerXml.Deserialize(s), CustomsWarehousingMRType)
End Function
#End Region
'''
''' Serializes current CustomsWarehousingMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an CustomsWarehousingMRType object
'''
''' File to load and deserialize
''' Output CustomsWarehousingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CustomsWarehousingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CustomsWarehousingMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CustomsWarehousingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As CustomsWarehousingMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class SummaryDeclarationGoodsReferenceMRType
#Region "Private fields"
Private _sequenceNumber As String
Private _numberOfPackages As String
Private _registrationNumber As String
Private _deprecatedFurtherRegistrationnumber As String
Private _goodsItemNumber As String
Private _identificationNumberOfCustodian As String
Private _typeOfIdentificationByKey As String
Private _referenceNumberOfIdentificationByKey As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property SequenceNumber() As String
Get
Return Me._sequenceNumber
End Get
Set
Me._sequenceNumber = Value
End Set
End Property
Public Property NumberOfPackages() As String
Get
Return Me._numberOfPackages
End Get
Set
Me._numberOfPackages = Value
End Set
End Property
Public Property RegistrationNumber() As String
Get
Return Me._registrationNumber
End Get
Set
Me._registrationNumber = Value
End Set
End Property
Public Property DeprecatedFurtherRegistrationnumber() As String
Get
Return Me._deprecatedFurtherRegistrationnumber
End Get
Set
Me._deprecatedFurtherRegistrationnumber = Value
End Set
End Property
Public Property GoodsItemNumber() As String
Get
Return Me._goodsItemNumber
End Get
Set
Me._goodsItemNumber = Value
End Set
End Property
Public Property IdentificationNumberOfCustodian() As String
Get
Return Me._identificationNumberOfCustodian
End Get
Set
Me._identificationNumberOfCustodian = Value
End Set
End Property
Public Property TypeOfIdentificationByKey() As String
Get
Return Me._typeOfIdentificationByKey
End Get
Set
Me._typeOfIdentificationByKey = Value
End Set
End Property
Public Property ReferenceNumberOfIdentificationByKey() As String
Get
Return Me._referenceNumberOfIdentificationByKey
End Get
Set
Me._referenceNumberOfIdentificationByKey = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(SummaryDeclarationGoodsReferenceMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize SummaryDeclarationGoodsReferenceMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes SummaryDeclarationGoodsReferenceMRType object
'''
''' string to deserialize
''' Output SummaryDeclarationGoodsReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As SummaryDeclarationGoodsReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, SummaryDeclarationGoodsReferenceMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As SummaryDeclarationGoodsReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As SummaryDeclarationGoodsReferenceMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), SummaryDeclarationGoodsReferenceMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As SummaryDeclarationGoodsReferenceMRType
Return CType(SerializerXml.Deserialize(s), SummaryDeclarationGoodsReferenceMRType)
End Function
#End Region
'''
''' Serializes current SummaryDeclarationGoodsReferenceMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an SummaryDeclarationGoodsReferenceMRType object
'''
''' File to load and deserialize
''' Output SummaryDeclarationGoodsReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As SummaryDeclarationGoodsReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, SummaryDeclarationGoodsReferenceMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As SummaryDeclarationGoodsReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As SummaryDeclarationGoodsReferenceMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class SummaryDeclarationMRType
#Region "Private fields"
Private _transference As String
Private _identificationType As String
Private _summaryDeclarationGoodsReference As List(Of SummaryDeclarationGoodsReferenceMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._summaryDeclarationGoodsReference = New List(Of SummaryDeclarationGoodsReferenceMRType)()
End Sub
Public Property Transference() As String
Get
Return Me._transference
End Get
Set
Me._transference = Value
End Set
End Property
Public Property IdentificationType() As String
Get
Return Me._identificationType
End Get
Set
Me._identificationType = Value
End Set
End Property
Public Property SummaryDeclarationGoodsReference() As List(Of SummaryDeclarationGoodsReferenceMRType)
Get
Return Me._summaryDeclarationGoodsReference
End Get
Set
Me._summaryDeclarationGoodsReference = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(SummaryDeclarationMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize SummaryDeclarationMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes SummaryDeclarationMRType object
'''
''' string to deserialize
''' Output SummaryDeclarationMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As SummaryDeclarationMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, SummaryDeclarationMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As SummaryDeclarationMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As SummaryDeclarationMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), SummaryDeclarationMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As SummaryDeclarationMRType
Return CType(SerializerXml.Deserialize(s), SummaryDeclarationMRType)
End Function
#End Region
'''
''' Serializes current SummaryDeclarationMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an SummaryDeclarationMRType object
'''
''' File to load and deserialize
''' Output SummaryDeclarationMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As SummaryDeclarationMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, SummaryDeclarationMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As SummaryDeclarationMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As SummaryDeclarationMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ProcedureTransferenceMRType
#Region "Private fields"
Private _summaryDeclaration As SummaryDeclarationMRType
Private _customsWarehousing As CustomsWarehousingMRType
Private _inwardProcessing As InwardProcessingMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._inwardProcessing = New InwardProcessingMRType()
Me._customsWarehousing = New CustomsWarehousingMRType()
Me._summaryDeclaration = New SummaryDeclarationMRType()
End Sub
Public Property SummaryDeclaration() As SummaryDeclarationMRType
Get
Return Me._summaryDeclaration
End Get
Set
Me._summaryDeclaration = Value
End Set
End Property
Public Property CustomsWarehousing() As CustomsWarehousingMRType
Get
Return Me._customsWarehousing
End Get
Set
Me._customsWarehousing = Value
End Set
End Property
Public Property InwardProcessing() As InwardProcessingMRType
Get
Return Me._inwardProcessing
End Get
Set
Me._inwardProcessing = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ProcedureTransferenceMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ProcedureTransferenceMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ProcedureTransferenceMRType object
'''
''' string to deserialize
''' Output ProcedureTransferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ProcedureTransferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ProcedureTransferenceMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ProcedureTransferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ProcedureTransferenceMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ProcedureTransferenceMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ProcedureTransferenceMRType
Return CType(SerializerXml.Deserialize(s), ProcedureTransferenceMRType)
End Function
#End Region
'''
''' Serializes current ProcedureTransferenceMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ProcedureTransferenceMRType object
'''
''' File to load and deserialize
''' Output ProcedureTransferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ProcedureTransferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ProcedureTransferenceMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ProcedureTransferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ProcedureTransferenceMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class PackagingMRType
#Region "Private fields"
Private _numberOfPackages As String
Private _typeOfPackages As String
Private _shippingMarks As String
Private _goodsItemNumber As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property NumberOfPackages() As String
Get
Return Me._numberOfPackages
End Get
Set
Me._numberOfPackages = Value
End Set
End Property
Public Property TypeOfPackages() As String
Get
Return Me._typeOfPackages
End Get
Set
Me._typeOfPackages = Value
End Set
End Property
Public Property ShippingMarks() As String
Get
Return Me._shippingMarks
End Get
Set
Me._shippingMarks = Value
End Set
End Property
Public Property GoodsItemNumber() As String
Get
Return Me._goodsItemNumber
End Get
Set
Me._goodsItemNumber = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(PackagingMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize PackagingMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes PackagingMRType object
'''
''' string to deserialize
''' Output PackagingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PackagingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PackagingMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PackagingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As PackagingMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), PackagingMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As PackagingMRType
Return CType(SerializerXml.Deserialize(s), PackagingMRType)
End Function
#End Region
'''
''' Serializes current PackagingMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an PackagingMRType object
'''
''' File to load and deserialize
''' Output PackagingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PackagingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PackagingMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PackagingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As PackagingMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class PreviousDocumentItemMRType
#Region "Private fields"
Private _type As String
Private _referenceNumber As String
Private _goodsItemNumber As String
Private _complementOfInformation As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Type() As String
Get
Return Me._type
End Get
Set
Me._type = Value
End Set
End Property
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Public Property GoodsItemNumber() As String
Get
Return Me._goodsItemNumber
End Get
Set
Me._goodsItemNumber = Value
End Set
End Property
Public Property ComplementOfInformation() As String
Get
Return Me._complementOfInformation
End Get
Set
Me._complementOfInformation = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(PreviousDocumentItemMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize PreviousDocumentItemMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes PreviousDocumentItemMRType object
'''
''' string to deserialize
''' Output PreviousDocumentItemMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PreviousDocumentItemMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PreviousDocumentItemMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PreviousDocumentItemMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As PreviousDocumentItemMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), PreviousDocumentItemMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As PreviousDocumentItemMRType
Return CType(SerializerXml.Deserialize(s), PreviousDocumentItemMRType)
End Function
#End Region
'''
''' Serializes current PreviousDocumentItemMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an PreviousDocumentItemMRType object
'''
''' File to load and deserialize
''' Output PreviousDocumentItemMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PreviousDocumentItemMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PreviousDocumentItemMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PreviousDocumentItemMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As PreviousDocumentItemMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ConsignmentItemMRType
#Region "Private fields"
Private _goodsItemNumber As String
Private _declarationGoodsItemNumber As String
Private _declarationType As String
Private _countryOfDispatch As String
Private _countryOfDestination As String
Private _commodityCode As String
Private _commodityCodeCombinedNomenclature As String
Private _referenceNumberUCR As String
Private _methodOfPayment As String
Private _uNNumber As List(Of String)
Private _descriptionOfGoods As String
Private _cusCode As String
Private _grossMass As Decimal
Private _netMass As Decimal
Private _consignee As AddressMRType
Private _additionalSupplyChainActor As List(Of AdditionalSupplyChainActorMRType)
Private _previousDocument As List(Of PreviousDocumentItemMRType)
Private _packaging As List(Of PackagingMRType)
Private _supportingDocument As List(Of SupportingDocumentMRType)
Private _transportDocument As List(Of TransportDocumentMRType)
Private _additionalReference As List(Of AdditionalReferenceMRType)
Private _additionalInformation As List(Of AdditionalInformationMRType)
Private _procedureTransference As ProcedureTransferenceMRType
Private _applicationInternalData As ApplicationInternalDataType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._applicationInternalData = New ApplicationInternalDataType()
Me._procedureTransference = New ProcedureTransferenceMRType()
Me._additionalInformation = New List(Of AdditionalInformationMRType)()
Me._additionalReference = New List(Of AdditionalReferenceMRType)()
Me._transportDocument = New List(Of TransportDocumentMRType)()
Me._supportingDocument = New List(Of SupportingDocumentMRType)()
Me._packaging = New List(Of PackagingMRType)()
Me._previousDocument = New List(Of PreviousDocumentItemMRType)()
Me._additionalSupplyChainActor = New List(Of AdditionalSupplyChainActorMRType)()
Me._consignee = New AddressMRType()
Me._uNNumber = New List(Of String)()
End Sub
Public Property GoodsItemNumber() As String
Get
Return Me._goodsItemNumber
End Get
Set
Me._goodsItemNumber = Value
End Set
End Property
Public Property DeclarationGoodsItemNumber() As String
Get
Return Me._declarationGoodsItemNumber
End Get
Set
Me._declarationGoodsItemNumber = Value
End Set
End Property
Public Property DeclarationType() As String
Get
Return Me._declarationType
End Get
Set
Me._declarationType = Value
End Set
End Property
Public Property CountryOfDispatch() As String
Get
Return Me._countryOfDispatch
End Get
Set
Me._countryOfDispatch = Value
End Set
End Property
Public Property CountryOfDestination() As String
Get
Return Me._countryOfDestination
End Get
Set
Me._countryOfDestination = Value
End Set
End Property
Public Property CommodityCode() As String
Get
Return Me._commodityCode
End Get
Set
Me._commodityCode = Value
End Set
End Property
Public Property CommodityCodeCombinedNomenclature() As String
Get
Return Me._commodityCodeCombinedNomenclature
End Get
Set
Me._commodityCodeCombinedNomenclature = Value
End Set
End Property
Public Property ReferenceNumberUCR() As String
Get
Return Me._referenceNumberUCR
End Get
Set
Me._referenceNumberUCR = Value
End Set
End Property
Public Property MethodOfPayment() As String
Get
Return Me._methodOfPayment
End Get
Set
Me._methodOfPayment = Value
End Set
End Property
Public Property UNNumber() As List(Of String)
Get
Return Me._uNNumber
End Get
Set
Me._uNNumber = Value
End Set
End Property
Public Property DescriptionOfGoods() As String
Get
Return Me._descriptionOfGoods
End Get
Set
Me._descriptionOfGoods = Value
End Set
End Property
Public Property CusCode() As String
Get
Return Me._cusCode
End Get
Set
Me._cusCode = Value
End Set
End Property
Public Property GrossMass() As Decimal
Get
Return Me._grossMass
End Get
Set
Me._grossMass = Value
End Set
End Property
Public Property NetMass() As Decimal
Get
Return Me._netMass
End Get
Set
Me._netMass = Value
End Set
End Property
Public Property Consignee() As AddressMRType
Get
Return Me._consignee
End Get
Set
Me._consignee = Value
End Set
End Property
Public Property AdditionalSupplyChainActor() As List(Of AdditionalSupplyChainActorMRType)
Get
Return Me._additionalSupplyChainActor
End Get
Set
Me._additionalSupplyChainActor = Value
End Set
End Property
Public Property PreviousDocument() As List(Of PreviousDocumentItemMRType)
Get
Return Me._previousDocument
End Get
Set
Me._previousDocument = Value
End Set
End Property
Public Property Packaging() As List(Of PackagingMRType)
Get
Return Me._packaging
End Get
Set
Me._packaging = Value
End Set
End Property
Public Property SupportingDocument() As List(Of SupportingDocumentMRType)
Get
Return Me._supportingDocument
End Get
Set
Me._supportingDocument = Value
End Set
End Property
Public Property TransportDocument() As List(Of TransportDocumentMRType)
Get
Return Me._transportDocument
End Get
Set
Me._transportDocument = Value
End Set
End Property
Public Property AdditionalReference() As List(Of AdditionalReferenceMRType)
Get
Return Me._additionalReference
End Get
Set
Me._additionalReference = Value
End Set
End Property
Public Property AdditionalInformation() As List(Of AdditionalInformationMRType)
Get
Return Me._additionalInformation
End Get
Set
Me._additionalInformation = Value
End Set
End Property
Public Property ProcedureTransference() As ProcedureTransferenceMRType
Get
Return Me._procedureTransference
End Get
Set
Me._procedureTransference = Value
End Set
End Property
Public Property ApplicationInternalData() As ApplicationInternalDataType
Get
Return Me._applicationInternalData
End Get
Set
Me._applicationInternalData = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ConsignmentItemMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ConsignmentItemMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ConsignmentItemMRType object
'''
''' string to deserialize
''' Output ConsignmentItemMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ConsignmentItemMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ConsignmentItemMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ConsignmentItemMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ConsignmentItemMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ConsignmentItemMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ConsignmentItemMRType
Return CType(SerializerXml.Deserialize(s), ConsignmentItemMRType)
End Function
#End Region
'''
''' Serializes current ConsignmentItemMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ConsignmentItemMRType object
'''
''' File to load and deserialize
''' Output ConsignmentItemMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ConsignmentItemMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ConsignmentItemMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ConsignmentItemMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ConsignmentItemMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class AddressMRType
#Region "Private fields"
Private _identificationNumber As String
Private _subsidiaryNumber As String
Private _name As String
Private _streetAndNumber As String
Private _city As String
Private _postcode As String
Private _country As String
Private _contactPerson As ContactPersonMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._contactPerson = New ContactPersonMRType()
End Sub
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Public Property SubsidiaryNumber() As String
Get
Return Me._subsidiaryNumber
End Get
Set
Me._subsidiaryNumber = Value
End Set
End Property
Public Property Name() As String
Get
Return Me._name
End Get
Set
Me._name = Value
End Set
End Property
Public Property StreetAndNumber() As String
Get
Return Me._streetAndNumber
End Get
Set
Me._streetAndNumber = Value
End Set
End Property
Public Property City() As String
Get
Return Me._city
End Get
Set
Me._city = Value
End Set
End Property
Public Property Postcode() As String
Get
Return Me._postcode
End Get
Set
Me._postcode = Value
End Set
End Property
Public Property Country() As String
Get
Return Me._country
End Get
Set
Me._country = Value
End Set
End Property
Public Property ContactPerson() As ContactPersonMRType
Get
Return Me._contactPerson
End Get
Set
Me._contactPerson = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(AddressMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize AddressMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes AddressMRType object
'''
''' string to deserialize
''' Output AddressMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AddressMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AddressMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AddressMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As AddressMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), AddressMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As AddressMRType
Return CType(SerializerXml.Deserialize(s), AddressMRType)
End Function
#End Region
'''
''' Serializes current AddressMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an AddressMRType object
'''
''' File to load and deserialize
''' Output AddressMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AddressMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AddressMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AddressMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As AddressMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ContactPersonMRType
#Region "Private fields"
Private _name As String
Private _phoneNumber As String
Private _eMailAddress As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Name() As String
Get
Return Me._name
End Get
Set
Me._name = Value
End Set
End Property
Public Property PhoneNumber() As String
Get
Return Me._phoneNumber
End Get
Set
Me._phoneNumber = Value
End Set
End Property
Public Property EMailAddress() As String
Get
Return Me._eMailAddress
End Get
Set
Me._eMailAddress = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ContactPersonMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ContactPersonMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ContactPersonMRType object
'''
''' string to deserialize
''' Output ContactPersonMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ContactPersonMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ContactPersonMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ContactPersonMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ContactPersonMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ContactPersonMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ContactPersonMRType
Return CType(SerializerXml.Deserialize(s), ContactPersonMRType)
End Function
#End Region
'''
''' Serializes current ContactPersonMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ContactPersonMRType object
'''
''' File to load and deserialize
''' Output ContactPersonMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ContactPersonMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ContactPersonMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ContactPersonMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ContactPersonMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class AdditionalSupplyChainActorMRType
#Region "Private fields"
Private _role As String
Private _identificationNumber As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Role() As String
Get
Return Me._role
End Get
Set
Me._role = Value
End Set
End Property
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(AdditionalSupplyChainActorMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize AdditionalSupplyChainActorMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes AdditionalSupplyChainActorMRType object
'''
''' string to deserialize
''' Output AdditionalSupplyChainActorMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AdditionalSupplyChainActorMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AdditionalSupplyChainActorMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AdditionalSupplyChainActorMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As AdditionalSupplyChainActorMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), AdditionalSupplyChainActorMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As AdditionalSupplyChainActorMRType
Return CType(SerializerXml.Deserialize(s), AdditionalSupplyChainActorMRType)
End Function
#End Region
'''
''' Serializes current AdditionalSupplyChainActorMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an AdditionalSupplyChainActorMRType object
'''
''' File to load and deserialize
''' Output AdditionalSupplyChainActorMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AdditionalSupplyChainActorMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AdditionalSupplyChainActorMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AdditionalSupplyChainActorMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As AdditionalSupplyChainActorMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class SupportingDocumentMRType
#Region "Private fields"
Private _type As String
Private _referenceNumber As String
Private _documentLineItemNumber As String
Private _complementOfInformation As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Type() As String
Get
Return Me._type
End Get
Set
Me._type = Value
End Set
End Property
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Public Property DocumentLineItemNumber() As String
Get
Return Me._documentLineItemNumber
End Get
Set
Me._documentLineItemNumber = Value
End Set
End Property
Public Property ComplementOfInformation() As String
Get
Return Me._complementOfInformation
End Get
Set
Me._complementOfInformation = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(SupportingDocumentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize SupportingDocumentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes SupportingDocumentMRType object
'''
''' string to deserialize
''' Output SupportingDocumentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As SupportingDocumentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, SupportingDocumentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As SupportingDocumentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As SupportingDocumentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), SupportingDocumentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As SupportingDocumentMRType
Return CType(SerializerXml.Deserialize(s), SupportingDocumentMRType)
End Function
#End Region
'''
''' Serializes current SupportingDocumentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an SupportingDocumentMRType object
'''
''' File to load and deserialize
''' Output SupportingDocumentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As SupportingDocumentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, SupportingDocumentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As SupportingDocumentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As SupportingDocumentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class TransportDocumentMRType
#Region "Private fields"
Private _type As String
Private _referenceNumber As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Type() As String
Get
Return Me._type
End Get
Set
Me._type = Value
End Set
End Property
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(TransportDocumentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize TransportDocumentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes TransportDocumentMRType object
'''
''' string to deserialize
''' Output TransportDocumentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As TransportDocumentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, TransportDocumentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As TransportDocumentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As TransportDocumentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), TransportDocumentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As TransportDocumentMRType
Return CType(SerializerXml.Deserialize(s), TransportDocumentMRType)
End Function
#End Region
'''
''' Serializes current TransportDocumentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an TransportDocumentMRType object
'''
''' File to load and deserialize
''' Output TransportDocumentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As TransportDocumentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, TransportDocumentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As TransportDocumentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As TransportDocumentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class AdditionalReferenceMRType
#Region "Private fields"
Private _type As String
Private _referenceNumber As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Type() As String
Get
Return Me._type
End Get
Set
Me._type = Value
End Set
End Property
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(AdditionalReferenceMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize AdditionalReferenceMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes AdditionalReferenceMRType object
'''
''' string to deserialize
''' Output AdditionalReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AdditionalReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AdditionalReferenceMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AdditionalReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As AdditionalReferenceMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), AdditionalReferenceMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As AdditionalReferenceMRType
Return CType(SerializerXml.Deserialize(s), AdditionalReferenceMRType)
End Function
#End Region
'''
''' Serializes current AdditionalReferenceMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an AdditionalReferenceMRType object
'''
''' File to load and deserialize
''' Output AdditionalReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AdditionalReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AdditionalReferenceMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AdditionalReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As AdditionalReferenceMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class AdditionalInformationMRType
#Region "Private fields"
Private _code As String
Private _text As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Code() As String
Get
Return Me._code
End Get
Set
Me._code = Value
End Set
End Property
Public Property Text() As String
Get
Return Me._text
End Get
Set
Me._text = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(AdditionalInformationMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize AdditionalInformationMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes AdditionalInformationMRType object
'''
''' string to deserialize
''' Output AdditionalInformationMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AdditionalInformationMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AdditionalInformationMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AdditionalInformationMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As AdditionalInformationMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), AdditionalInformationMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As AdditionalInformationMRType
Return CType(SerializerXml.Deserialize(s), AdditionalInformationMRType)
End Function
#End Region
'''
''' Serializes current AdditionalInformationMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an AdditionalInformationMRType object
'''
''' File to load and deserialize
''' Output AdditionalInformationMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AdditionalInformationMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AdditionalInformationMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AdditionalInformationMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As AdditionalInformationMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ApplicationInternalDataType
#Region "Private fields"
Private _additionalDetails As List(Of ApplicationInternalDataAdditionalDetailsDataType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._additionalDetails = New List(Of ApplicationInternalDataAdditionalDetailsDataType)()
End Sub
Public Property AdditionalDetails() As List(Of ApplicationInternalDataAdditionalDetailsDataType)
Get
Return Me._additionalDetails
End Get
Set
Me._additionalDetails = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ApplicationInternalDataType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ApplicationInternalDataType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ApplicationInternalDataType object
'''
''' string to deserialize
''' Output ApplicationInternalDataType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ApplicationInternalDataType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ApplicationInternalDataType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ApplicationInternalDataType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ApplicationInternalDataType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ApplicationInternalDataType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ApplicationInternalDataType
Return CType(SerializerXml.Deserialize(s), ApplicationInternalDataType)
End Function
#End Region
'''
''' Serializes current ApplicationInternalDataType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ApplicationInternalDataType object
'''
''' File to load and deserialize
''' Output ApplicationInternalDataType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ApplicationInternalDataType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ApplicationInternalDataType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ApplicationInternalDataType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ApplicationInternalDataType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ApplicationInternalDataAdditionalDetailsDataType
#Region "Private fields"
Private _key As String
Private _value As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Key() As String
Get
Return Me._key
End Get
Set
Me._key = Value
End Set
End Property
Public Property Value() As String
Get
Return Me._value
End Get
Set
Me._value = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ApplicationInternalDataAdditionalDetailsDataType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ApplicationInternalDataAdditionalDetailsDataType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ApplicationInternalDataAdditionalDetailsDataType object
'''
''' string to deserialize
''' Output ApplicationInternalDataAdditionalDetailsDataType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ApplicationInternalDataAdditionalDetailsDataType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ApplicationInternalDataAdditionalDetailsDataType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ApplicationInternalDataAdditionalDetailsDataType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ApplicationInternalDataAdditionalDetailsDataType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ApplicationInternalDataAdditionalDetailsDataType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ApplicationInternalDataAdditionalDetailsDataType
Return CType(SerializerXml.Deserialize(s), ApplicationInternalDataAdditionalDetailsDataType)
End Function
#End Region
'''
''' Serializes current ApplicationInternalDataAdditionalDetailsDataType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ApplicationInternalDataAdditionalDetailsDataType object
'''
''' File to load and deserialize
''' Output ApplicationInternalDataAdditionalDetailsDataType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ApplicationInternalDataAdditionalDetailsDataType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ApplicationInternalDataAdditionalDetailsDataType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ApplicationInternalDataAdditionalDetailsDataType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ApplicationInternalDataAdditionalDetailsDataType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class HouseConsignmentMRType
#Region "Private fields"
Private _houseConsignmentNumber As String
Private _countryOfDispatch As String
Private _countryOfDestination As String
Private _grossMass As Decimal
Private _referenceNumberUCR As String
Private _consignor As AddressMRType
Private _consignee As AddressMRType
Private _additionalSupplyChainActor As List(Of AdditionalSupplyChainActorMRType)
Private _previousDocument As List(Of PreviousDocumentMRType)
Private _supportingDocument As List(Of SupportingDocumentMRType)
Private _transportDocument As List(Of TransportDocumentMRType)
Private _additionalReference As List(Of AdditionalReferenceMRType)
Private _additionalInformation As List(Of AdditionalInformationMRType)
Private _transportCharges As String
Private _applicationInternalData As ApplicationInternalDataType
Private _consignmentItem As List(Of ConsignmentItemMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._consignmentItem = New List(Of ConsignmentItemMRType)()
Me._applicationInternalData = New ApplicationInternalDataType()
Me._additionalInformation = New List(Of AdditionalInformationMRType)()
Me._additionalReference = New List(Of AdditionalReferenceMRType)()
Me._transportDocument = New List(Of TransportDocumentMRType)()
Me._supportingDocument = New List(Of SupportingDocumentMRType)()
Me._previousDocument = New List(Of PreviousDocumentMRType)()
Me._additionalSupplyChainActor = New List(Of AdditionalSupplyChainActorMRType)()
Me._consignee = New AddressMRType()
Me._consignor = New AddressMRType()
End Sub
Public Property HouseConsignmentNumber() As String
Get
Return Me._houseConsignmentNumber
End Get
Set
Me._houseConsignmentNumber = Value
End Set
End Property
Public Property CountryOfDispatch() As String
Get
Return Me._countryOfDispatch
End Get
Set
Me._countryOfDispatch = Value
End Set
End Property
Public Property CountryOfDestination() As String
Get
Return Me._countryOfDestination
End Get
Set
Me._countryOfDestination = Value
End Set
End Property
Public Property GrossMass() As Decimal
Get
Return Me._grossMass
End Get
Set
Me._grossMass = Value
End Set
End Property
Public Property ReferenceNumberUCR() As String
Get
Return Me._referenceNumberUCR
End Get
Set
Me._referenceNumberUCR = Value
End Set
End Property
Public Property Consignor() As AddressMRType
Get
Return Me._consignor
End Get
Set
Me._consignor = Value
End Set
End Property
Public Property Consignee() As AddressMRType
Get
Return Me._consignee
End Get
Set
Me._consignee = Value
End Set
End Property
Public Property AdditionalSupplyChainActor() As List(Of AdditionalSupplyChainActorMRType)
Get
Return Me._additionalSupplyChainActor
End Get
Set
Me._additionalSupplyChainActor = Value
End Set
End Property
Public Property PreviousDocument() As List(Of PreviousDocumentMRType)
Get
Return Me._previousDocument
End Get
Set
Me._previousDocument = Value
End Set
End Property
Public Property SupportingDocument() As List(Of SupportingDocumentMRType)
Get
Return Me._supportingDocument
End Get
Set
Me._supportingDocument = Value
End Set
End Property
Public Property TransportDocument() As List(Of TransportDocumentMRType)
Get
Return Me._transportDocument
End Get
Set
Me._transportDocument = Value
End Set
End Property
Public Property AdditionalReference() As List(Of AdditionalReferenceMRType)
Get
Return Me._additionalReference
End Get
Set
Me._additionalReference = Value
End Set
End Property
Public Property AdditionalInformation() As List(Of AdditionalInformationMRType)
Get
Return Me._additionalInformation
End Get
Set
Me._additionalInformation = Value
End Set
End Property
Public Property TransportCharges() As String
Get
Return Me._transportCharges
End Get
Set
Me._transportCharges = Value
End Set
End Property
Public Property ApplicationInternalData() As ApplicationInternalDataType
Get
Return Me._applicationInternalData
End Get
Set
Me._applicationInternalData = Value
End Set
End Property
Public Property ConsignmentItem() As List(Of ConsignmentItemMRType)
Get
Return Me._consignmentItem
End Get
Set
Me._consignmentItem = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(HouseConsignmentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize HouseConsignmentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes HouseConsignmentMRType object
'''
''' string to deserialize
''' Output HouseConsignmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As HouseConsignmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, HouseConsignmentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As HouseConsignmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As HouseConsignmentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), HouseConsignmentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As HouseConsignmentMRType
Return CType(SerializerXml.Deserialize(s), HouseConsignmentMRType)
End Function
#End Region
'''
''' Serializes current HouseConsignmentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an HouseConsignmentMRType object
'''
''' File to load and deserialize
''' Output HouseConsignmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As HouseConsignmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, HouseConsignmentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As HouseConsignmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As HouseConsignmentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class PreviousDocumentMRType
#Region "Private fields"
Private _type As String
Private _referenceNumber As String
Private _complementOfInformation As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Type() As String
Get
Return Me._type
End Get
Set
Me._type = Value
End Set
End Property
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Public Property ComplementOfInformation() As String
Get
Return Me._complementOfInformation
End Get
Set
Me._complementOfInformation = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(PreviousDocumentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize PreviousDocumentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes PreviousDocumentMRType object
'''
''' string to deserialize
''' Output PreviousDocumentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PreviousDocumentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PreviousDocumentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PreviousDocumentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As PreviousDocumentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), PreviousDocumentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As PreviousDocumentMRType
Return CType(SerializerXml.Deserialize(s), PreviousDocumentMRType)
End Function
#End Region
'''
''' Serializes current PreviousDocumentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an PreviousDocumentMRType object
'''
''' File to load and deserialize
''' Output PreviousDocumentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PreviousDocumentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PreviousDocumentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PreviousDocumentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As PreviousDocumentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class LocationOfGoodsMRType
#Region "Private fields"
Private _typeOfLocation As String
Private _qualifierOfIdentification As String
Private _additionalIdentifier As String
Private _contactPerson As ContactPersonMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._contactPerson = New ContactPersonMRType()
End Sub
Public Property TypeOfLocation() As String
Get
Return Me._typeOfLocation
End Get
Set
Me._typeOfLocation = Value
End Set
End Property
Public Property QualifierOfIdentification() As String
Get
Return Me._qualifierOfIdentification
End Get
Set
Me._qualifierOfIdentification = Value
End Set
End Property
Public Property AdditionalIdentifier() As String
Get
Return Me._additionalIdentifier
End Get
Set
Me._additionalIdentifier = Value
End Set
End Property
Public Property ContactPerson() As ContactPersonMRType
Get
Return Me._contactPerson
End Get
Set
Me._contactPerson = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(LocationOfGoodsMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize LocationOfGoodsMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes LocationOfGoodsMRType object
'''
''' string to deserialize
''' Output LocationOfGoodsMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As LocationOfGoodsMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, LocationOfGoodsMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As LocationOfGoodsMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As LocationOfGoodsMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), LocationOfGoodsMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As LocationOfGoodsMRType
Return CType(SerializerXml.Deserialize(s), LocationOfGoodsMRType)
End Function
#End Region
'''
''' Serializes current LocationOfGoodsMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an LocationOfGoodsMRType object
'''
''' File to load and deserialize
''' Output LocationOfGoodsMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As LocationOfGoodsMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, LocationOfGoodsMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As LocationOfGoodsMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As LocationOfGoodsMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class AuthorisationMRType
#Region "Private fields"
Private _referenceNumber As String
Private _type As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Public Property Type() As String
Get
Return Me._type
End Get
Set
Me._type = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(AuthorisationMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize AuthorisationMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes AuthorisationMRType object
'''
''' string to deserialize
''' Output AuthorisationMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AuthorisationMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AuthorisationMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As AuthorisationMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As AuthorisationMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), AuthorisationMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As AuthorisationMRType
Return CType(SerializerXml.Deserialize(s), AuthorisationMRType)
End Function
#End Region
'''
''' Serializes current AuthorisationMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an AuthorisationMRType object
'''
''' File to load and deserialize
''' Output AuthorisationMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AuthorisationMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, AuthorisationMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As AuthorisationMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As AuthorisationMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class TransportEquipmentMRType
#Region "Private fields"
Private _numberOfSeals As String
Private _seal As List(Of String)
Private _containerIdentificationNumber As String
Private _goodsReference As List(Of String)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._goodsReference = New List(Of String)()
Me._seal = New List(Of String)()
End Sub
Public Property NumberOfSeals() As String
Get
Return Me._numberOfSeals
End Get
Set
Me._numberOfSeals = Value
End Set
End Property
Public Property Seal() As List(Of String)
Get
Return Me._seal
End Get
Set
Me._seal = Value
End Set
End Property
Public Property ContainerIdentificationNumber() As String
Get
Return Me._containerIdentificationNumber
End Get
Set
Me._containerIdentificationNumber = Value
End Set
End Property
Public Property GoodsReference() As List(Of String)
Get
Return Me._goodsReference
End Get
Set
Me._goodsReference = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(TransportEquipmentMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize TransportEquipmentMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes TransportEquipmentMRType object
'''
''' string to deserialize
''' Output TransportEquipmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As TransportEquipmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, TransportEquipmentMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As TransportEquipmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As TransportEquipmentMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), TransportEquipmentMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As TransportEquipmentMRType
Return CType(SerializerXml.Deserialize(s), TransportEquipmentMRType)
End Function
#End Region
'''
''' Serializes current TransportEquipmentMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an TransportEquipmentMRType object
'''
''' File to load and deserialize
''' Output TransportEquipmentMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As TransportEquipmentMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, TransportEquipmentMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As TransportEquipmentMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As TransportEquipmentMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class CarrierMRType
#Region "Private fields"
Private _identificationNumber As String
Private _subsidiaryNumber As String
Private _contactPerson As ContactPersonMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._contactPerson = New ContactPersonMRType()
End Sub
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Public Property SubsidiaryNumber() As String
Get
Return Me._subsidiaryNumber
End Get
Set
Me._subsidiaryNumber = Value
End Set
End Property
Public Property ContactPerson() As ContactPersonMRType
Get
Return Me._contactPerson
End Get
Set
Me._contactPerson = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(CarrierMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize CarrierMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes CarrierMRType object
'''
''' string to deserialize
''' Output CarrierMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CarrierMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CarrierMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CarrierMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As CarrierMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), CarrierMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As CarrierMRType
Return CType(SerializerXml.Deserialize(s), CarrierMRType)
End Function
#End Region
'''
''' Serializes current CarrierMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an CarrierMRType object
'''
''' File to load and deserialize
''' Output CarrierMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CarrierMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CarrierMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CarrierMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As CarrierMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class RepresentativeMRType
#Region "Private fields"
Private _identificationNumber As String
Private _name As String
Private _streetAndNumber As String
Private _city As String
Private _postcode As String
Private _country As String
Private _contactPerson As ContactPersonMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._contactPerson = New ContactPersonMRType()
End Sub
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Public Property Name() As String
Get
Return Me._name
End Get
Set
Me._name = Value
End Set
End Property
Public Property StreetAndNumber() As String
Get
Return Me._streetAndNumber
End Get
Set
Me._streetAndNumber = Value
End Set
End Property
Public Property City() As String
Get
Return Me._city
End Get
Set
Me._city = Value
End Set
End Property
Public Property Postcode() As String
Get
Return Me._postcode
End Get
Set
Me._postcode = Value
End Set
End Property
Public Property Country() As String
Get
Return Me._country
End Get
Set
Me._country = Value
End Set
End Property
Public Property ContactPerson() As ContactPersonMRType
Get
Return Me._contactPerson
End Get
Set
Me._contactPerson = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(RepresentativeMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize RepresentativeMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes RepresentativeMRType object
'''
''' string to deserialize
''' Output RepresentativeMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As RepresentativeMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, RepresentativeMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As RepresentativeMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As RepresentativeMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), RepresentativeMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As RepresentativeMRType
Return CType(SerializerXml.Deserialize(s), RepresentativeMRType)
End Function
#End Region
'''
''' Serializes current RepresentativeMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an RepresentativeMRType object
'''
''' File to load and deserialize
''' Output RepresentativeMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As RepresentativeMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, RepresentativeMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As RepresentativeMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As RepresentativeMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class HolderOfTheTransitProcedureMRType
#Region "Private fields"
Private _identificationNumber As String
Private _tIRHolderIdentificationNumber As String
Private _name As String
Private _streetAndNumber As String
Private _city As String
Private _postcode As String
Private _country As String
Private _contactPerson As ContactPersonMRType
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._contactPerson = New ContactPersonMRType()
End Sub
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Public Property TIRHolderIdentificationNumber() As String
Get
Return Me._tIRHolderIdentificationNumber
End Get
Set
Me._tIRHolderIdentificationNumber = Value
End Set
End Property
Public Property Name() As String
Get
Return Me._name
End Get
Set
Me._name = Value
End Set
End Property
Public Property StreetAndNumber() As String
Get
Return Me._streetAndNumber
End Get
Set
Me._streetAndNumber = Value
End Set
End Property
Public Property City() As String
Get
Return Me._city
End Get
Set
Me._city = Value
End Set
End Property
Public Property Postcode() As String
Get
Return Me._postcode
End Get
Set
Me._postcode = Value
End Set
End Property
Public Property Country() As String
Get
Return Me._country
End Get
Set
Me._country = Value
End Set
End Property
Public Property ContactPerson() As ContactPersonMRType
Get
Return Me._contactPerson
End Get
Set
Me._contactPerson = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(HolderOfTheTransitProcedureMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize HolderOfTheTransitProcedureMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes HolderOfTheTransitProcedureMRType object
'''
''' string to deserialize
''' Output HolderOfTheTransitProcedureMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As HolderOfTheTransitProcedureMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, HolderOfTheTransitProcedureMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As HolderOfTheTransitProcedureMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As HolderOfTheTransitProcedureMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), HolderOfTheTransitProcedureMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As HolderOfTheTransitProcedureMRType
Return CType(SerializerXml.Deserialize(s), HolderOfTheTransitProcedureMRType)
End Function
#End Region
'''
''' Serializes current HolderOfTheTransitProcedureMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an HolderOfTheTransitProcedureMRType object
'''
''' File to load and deserialize
''' Output HolderOfTheTransitProcedureMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As HolderOfTheTransitProcedureMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, HolderOfTheTransitProcedureMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As HolderOfTheTransitProcedureMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As HolderOfTheTransitProcedureMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class CustomsOfficeOfTransitDeclaredMRType
#Region "Private fields"
Private _referenceNumber As String
Private _arrivalDateAndTimeEstimated As Date
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property ReferenceNumber() As String
Get
Return Me._referenceNumber
End Get
Set
Me._referenceNumber = Value
End Set
End Property
Public Property ArrivalDateAndTimeEstimated() As Date
Get
Return Me._arrivalDateAndTimeEstimated
End Get
Set
Me._arrivalDateAndTimeEstimated = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(CustomsOfficeOfTransitDeclaredMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize CustomsOfficeOfTransitDeclaredMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes CustomsOfficeOfTransitDeclaredMRType object
'''
''' string to deserialize
''' Output CustomsOfficeOfTransitDeclaredMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CustomsOfficeOfTransitDeclaredMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CustomsOfficeOfTransitDeclaredMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CustomsOfficeOfTransitDeclaredMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As CustomsOfficeOfTransitDeclaredMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), CustomsOfficeOfTransitDeclaredMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As CustomsOfficeOfTransitDeclaredMRType
Return CType(SerializerXml.Deserialize(s), CustomsOfficeOfTransitDeclaredMRType)
End Function
#End Region
'''
''' Serializes current CustomsOfficeOfTransitDeclaredMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an CustomsOfficeOfTransitDeclaredMRType object
'''
''' File to load and deserialize
''' Output CustomsOfficeOfTransitDeclaredMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CustomsOfficeOfTransitDeclaredMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, CustomsOfficeOfTransitDeclaredMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CustomsOfficeOfTransitDeclaredMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As CustomsOfficeOfTransitDeclaredMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class DepartureTransportMeansMRType
#Region "Private fields"
Private _nationality As String
Private _typeOfIdentification As String
Private _identificationNumber As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Nationality() As String
Get
Return Me._nationality
End Get
Set
Me._nationality = Value
End Set
End Property
Public Property TypeOfIdentification() As String
Get
Return Me._typeOfIdentification
End Get
Set
Me._typeOfIdentification = Value
End Set
End Property
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(DepartureTransportMeansMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize DepartureTransportMeansMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes DepartureTransportMeansMRType object
'''
''' string to deserialize
''' Output DepartureTransportMeansMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As DepartureTransportMeansMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, DepartureTransportMeansMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As DepartureTransportMeansMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As DepartureTransportMeansMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), DepartureTransportMeansMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As DepartureTransportMeansMRType
Return CType(SerializerXml.Deserialize(s), DepartureTransportMeansMRType)
End Function
#End Region
'''
''' Serializes current DepartureTransportMeansMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an DepartureTransportMeansMRType object
'''
''' File to load and deserialize
''' Output DepartureTransportMeansMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As DepartureTransportMeansMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, DepartureTransportMeansMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As DepartureTransportMeansMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As DepartureTransportMeansMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class PlaceOfLoadingMRType
#Region "Private fields"
Private _location As String
Private _country As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Location() As String
Get
Return Me._location
End Get
Set
Me._location = Value
End Set
End Property
Public Property Country() As String
Get
Return Me._country
End Get
Set
Me._country = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(PlaceOfLoadingMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize PlaceOfLoadingMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes PlaceOfLoadingMRType object
'''
''' string to deserialize
''' Output PlaceOfLoadingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PlaceOfLoadingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PlaceOfLoadingMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PlaceOfLoadingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As PlaceOfLoadingMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), PlaceOfLoadingMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As PlaceOfLoadingMRType
Return CType(SerializerXml.Deserialize(s), PlaceOfLoadingMRType)
End Function
#End Region
'''
''' Serializes current PlaceOfLoadingMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an PlaceOfLoadingMRType object
'''
''' File to load and deserialize
''' Output PlaceOfLoadingMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PlaceOfLoadingMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, PlaceOfLoadingMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PlaceOfLoadingMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As PlaceOfLoadingMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class ActiveBorderTransportMeansMRType
#Region "Private fields"
Private _nationality As String
Private _typeOfIdentification As String
Private _identificationNumber As String
Private _conveyanceReferenceNumber As String
Private _customsOfficeAtBorderDeclared As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property Nationality() As String
Get
Return Me._nationality
End Get
Set
Me._nationality = Value
End Set
End Property
Public Property TypeOfIdentification() As String
Get
Return Me._typeOfIdentification
End Get
Set
Me._typeOfIdentification = Value
End Set
End Property
Public Property IdentificationNumber() As String
Get
Return Me._identificationNumber
End Get
Set
Me._identificationNumber = Value
End Set
End Property
Public Property ConveyanceReferenceNumber() As String
Get
Return Me._conveyanceReferenceNumber
End Get
Set
Me._conveyanceReferenceNumber = Value
End Set
End Property
Public Property CustomsOfficeAtBorderDeclared() As String
Get
Return Me._customsOfficeAtBorderDeclared
End Get
Set
Me._customsOfficeAtBorderDeclared = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(ActiveBorderTransportMeansMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize ActiveBorderTransportMeansMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes ActiveBorderTransportMeansMRType object
'''
''' string to deserialize
''' Output ActiveBorderTransportMeansMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ActiveBorderTransportMeansMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ActiveBorderTransportMeansMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As ActiveBorderTransportMeansMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As ActiveBorderTransportMeansMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), ActiveBorderTransportMeansMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As ActiveBorderTransportMeansMRType
Return CType(SerializerXml.Deserialize(s), ActiveBorderTransportMeansMRType)
End Function
#End Region
'''
''' Serializes current ActiveBorderTransportMeansMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an ActiveBorderTransportMeansMRType object
'''
''' File to load and deserialize
''' Output ActiveBorderTransportMeansMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ActiveBorderTransportMeansMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, ActiveBorderTransportMeansMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As ActiveBorderTransportMeansMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As ActiveBorderTransportMeansMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class GuaranteeReferenceMRType
#Region "Private fields"
Private _gRN As String
Private _amountToBeCovered As Decimal
Private _currency As String
Private Shared _serializerXml As XmlSerializer
#End Region
Public Property GRN() As String
Get
Return Me._gRN
End Get
Set
Me._gRN = Value
End Set
End Property
Public Property AmountToBeCovered() As Decimal
Get
Return Me._amountToBeCovered
End Get
Set
Me._amountToBeCovered = Value
End Set
End Property
Public Property Currency() As String
Get
Return Me._currency
End Get
Set
Me._currency = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(GuaranteeReferenceMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize GuaranteeReferenceMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes GuaranteeReferenceMRType object
'''
''' string to deserialize
''' Output GuaranteeReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GuaranteeReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GuaranteeReferenceMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GuaranteeReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As GuaranteeReferenceMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), GuaranteeReferenceMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As GuaranteeReferenceMRType
Return CType(SerializerXml.Deserialize(s), GuaranteeReferenceMRType)
End Function
#End Region
'''
''' Serializes current GuaranteeReferenceMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an GuaranteeReferenceMRType object
'''
''' File to load and deserialize
''' Output GuaranteeReferenceMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GuaranteeReferenceMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GuaranteeReferenceMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GuaranteeReferenceMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As GuaranteeReferenceMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class GuaranteeMRType
#Region "Private fields"
Private _guaranteeType As String
Private _otherGuaranteeReference As String
Private _guaranteeReference As List(Of GuaranteeReferenceMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._guaranteeReference = New List(Of GuaranteeReferenceMRType)()
End Sub
Public Property GuaranteeType() As String
Get
Return Me._guaranteeType
End Get
Set
Me._guaranteeType = Value
End Set
End Property
Public Property OtherGuaranteeReference() As String
Get
Return Me._otherGuaranteeReference
End Get
Set
Me._otherGuaranteeReference = Value
End Set
End Property
Public Property GuaranteeReference() As List(Of GuaranteeReferenceMRType)
Get
Return Me._guaranteeReference
End Get
Set
Me._guaranteeReference = Value
End Set
End Property
Private Shared ReadOnly Property SerializerXml() As XmlSerializer
Get
If (_serializerXml Is Nothing) Then
_serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(GuaranteeMRType))
End If
Return _serializerXml
End Get
End Property
#Region "Serialize/Deserialize"
'''
''' Serialize GuaranteeMRType object
'''
''' XML value
Public Overridable Function Serialize() As String
Dim streamReader As StreamReader = Nothing
Dim memoryStream As MemoryStream = Nothing
Try
memoryStream = New MemoryStream()
Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
SerializerXml.Serialize(xmlWriter, Me)
memoryStream.Seek(0, SeekOrigin.Begin)
streamReader = New StreamReader(memoryStream)
Return streamReader.ReadToEnd
Finally
If (Not (streamReader) Is Nothing) Then
streamReader.Dispose()
End If
If (Not (memoryStream) Is Nothing) Then
memoryStream.Dispose()
End If
End Try
End Function
'''
''' Deserializes GuaranteeMRType object
'''
''' string to deserialize
''' Output GuaranteeMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GuaranteeMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GuaranteeMRType)
Try
obj = Deserialize(input)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As GuaranteeMRType) As Boolean
Dim exception As System.Exception = Nothing
Return Deserialize(input, obj, exception)
End Function
Public Overloads Shared Function Deserialize(ByVal input As String) As GuaranteeMRType
Dim stringReader As StringReader = Nothing
Try
stringReader = New StringReader(input)
Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), GuaranteeMRType)
Finally
If (Not (stringReader) Is Nothing) Then
stringReader.Dispose()
End If
End Try
End Function
Public Overloads Shared Function Deserialize(ByVal s As Stream) As GuaranteeMRType
Return CType(SerializerXml.Deserialize(s), GuaranteeMRType)
End Function
#End Region
'''
''' Serializes current GuaranteeMRType object into file
'''
''' full path of outupt xml file
''' output Exception value if failed
''' true if can serialize and save into file; otherwise, false
Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
exception = Nothing
Try
SaveToFile(fileName)
Return True
Catch e As System.Exception
exception = e
Return False
End Try
End Function
Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
Dim streamWriter As StreamWriter = Nothing
Try
Dim dataString As String = Serialize()
Dim outputFile As FileInfo = New FileInfo(fileName)
streamWriter = outputFile.CreateText
streamWriter.WriteLine(dataString)
streamWriter.Close()
Finally
If (Not (streamWriter) Is Nothing) Then
streamWriter.Dispose()
End If
End Try
End Sub
'''
''' Deserializes xml markup from file into an GuaranteeMRType object
'''
''' File to load and deserialize
''' Output GuaranteeMRType object
''' output Exception value if deserialize failed
''' true if this Serializer can deserialize the object; otherwise, false
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GuaranteeMRType, ByRef exception As System.Exception) As Boolean
exception = Nothing
obj = CType(Nothing, GuaranteeMRType)
Try
obj = LoadFromFile(fileName)
Return True
Catch ex As System.Exception
exception = ex
Return False
End Try
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As GuaranteeMRType) As Boolean
Dim exception As System.Exception = Nothing
Return LoadFromFile(fileName, obj, exception)
End Function
Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As GuaranteeMRType
Dim file As FileStream = Nothing
Dim sr As StreamReader = Nothing
Try
file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
sr = New StreamReader(file)
Dim dataString As String = sr.ReadToEnd
sr.Close()
file.Close()
Return Deserialize(dataString)
Finally
If (Not (file) Is Nothing) Then
file.Dispose()
End If
If (Not (sr) Is Nothing) Then
sr.Dispose()
End If
End Try
End Function
End Class
Partial Public Class TransitOperationMRType
#Region "Private fields"
Private _mRN As String
Private _customsOfficeOfDeparture As String
Private _declarationAcceptanceDateAndTime As Date
Private _releaseDateAndTime As Date
Private _limitDate As Date
Private _guarantee As List(Of GuaranteeMRType)
Private _customsOfficeOfDestinationDeclared As String
Private _nameOfAccompanyingDocument As String
Private _security As String
Private _referenceNumberUCR As String
Private _activeBorderTransportMeans As List(Of ActiveBorderTransportMeansMRType)
Private _specificCircumstanceIndicator As String
Private _placeOfLoading As PlaceOfLoadingMRType
Private _placeOfUnloading As PlaceOfLoadingMRType
Private _transportCharges As String
Private _declarationType As String
Private _transitDeclarationType As String
Private _tIRCarnetNumber As String
Private _reducedDatasetIndicator As String
Private _bindingItinerary As String
Private _countryOfDispatch As String
Private _countryOfDestination As String
Private _grossMass As Decimal
Private _containerIndicator As String
Private _inlandModeOfTransport As String
Private _modeOfTransportAtTheBorder As String
Private _departureTransportMeans As List(Of DepartureTransportMeansMRType)
Private _customsOfficeOfTransitDeclared As List(Of CustomsOfficeOfTransitDeclaredMRType)
Private _customsOfficeOfExitForTransitDeclared As List(Of String)
Private _countryOfRoutingOfConsignment As List(Of String)
Private _consignor As AddressMRType
Private _consignee As AddressMRType
Private _holderOfTheTransitProcedure As HolderOfTheTransitProcedureMRType
Private _representative As RepresentativeMRType
Private _carrier As CarrierMRType
Private _additionalSupplyChainActor As List(Of AdditionalSupplyChainActorMRType)
Private _transportEquipment As List(Of TransportEquipmentMRType)
Private _authorisation As List(Of AuthorisationMRType)
Private _locationOfGoods As LocationOfGoodsMRType
Private _previousDocument As List(Of PreviousDocumentMRType)
Private _supportingDocument As List(Of SupportingDocumentMRType)
Private _transportDocument As List(Of TransportDocumentMRType)
Private _additionalReference As List(Of AdditionalReferenceMRType)
Private _additionalInformation As List(Of AdditionalInformationMRType)
Private _applicationInternalData As ApplicationInternalDataType
Private _houseConsignment As List(Of HouseConsignmentMRType)
Private Shared _serializerXml As XmlSerializer
#End Region
Public Sub New()
MyBase.New
Me._houseConsignment = New List(Of HouseConsignmentMRType)()
Me._applicationInternalData = New ApplicationInternalDataType()
Me._additionalInformation = New List(Of AdditionalInformationMRType)()
Me._additionalReference = New List(Of AdditionalReferenceMRType)()
Me._transportDocument = New List(Of TransportDocumentMRType)()
Me._supportingDocument = New List(Of SupportingDocumentMRType)()
Me._previousDocument = New List(Of PreviousDocumentMRType)()
Me._locationOfGoods = New LocationOfGoodsMRType()
Me._authorisation = New List(Of AuthorisationMRType)()
Me._transportEquipment = New List(Of TransportEquipmentMRType)()
Me._additionalSupplyChainActor = New List(Of AdditionalSupplyChainActorMRType)()
Me._carrier = New CarrierMRType()
Me._representative = New RepresentativeMRType()
Me._holderOfTheTransitProcedure = New HolderOfTheTransitProcedureMRType()
Me._consignee = New AddressMRType()
Me._consignor = New AddressMRType()
Me._countryOfRoutingOfConsignment = New List(Of String)()
Me._customsOfficeOfExitForTransitDeclared = New List(Of String)()
Me._customsOfficeOfTransitDeclared = New List(Of CustomsOfficeOfTransitDeclaredMRType)()
Me._departureTransportMeans = New List(Of DepartureTransportMeansMRType)()
Me._placeOfUnloading = New PlaceOfLoadingMRType()
Me._placeOfLoading = New PlaceOfLoadingMRType()
Me._activeBorderTransportMeans = New List(Of ActiveBorderTransportMeansMRType)()
Me._guarantee = New List(Of GuaranteeMRType)()
End Sub
Public Property MRN() As String
Get
Return Me._mRN
End Get
Set
Me._mRN = Value
End Set
End Property
Public Property CustomsOfficeOfDeparture() As String
Get
Return Me._customsOfficeOfDeparture
End Get
Set
Me._customsOfficeOfDeparture = Value
End Set
End Property
Public Property DeclarationAcceptanceDateAndTime() As Date
Get
Return Me._declarationAcceptanceDateAndTime
End Get
Set
Me._declarationAcceptanceDateAndTime = Value
End Set
End Property
Public Property ReleaseDateAndTime() As Date
Get
Return Me._releaseDateAndTime
End Get
Set
Me._releaseDateAndTime = Value
End Set
End Property
Public Property LimitDate() As Date
Get
Return Me._limitDate
End Get
Set
Me._limitDate = Value
End Set
End Property
Public Property Guarantee() As List(Of GuaranteeMRType)
Get
Return Me._guarantee
End Get
Set
Me._guarantee = Value
End Set
End Property
Public Property CustomsOfficeOfDestinationDeclared() As String
Get
Return Me._customsOfficeOfDestinationDeclared
End Get
Set
Me._customsOfficeOfDestinationDeclared = Value
End Set
End Property
Public Property NameOfAccompanyingDocument() As String
Get
Return Me._nameOfAccompanyingDocument
End Get
Set
Me._nameOfAccompanyingDocument = Value
End Set
End Property
Public Property Security() As String
Get
Return Me._security
End Get
Set
Me._security = Value
End Set
End Property
Public Property ReferenceNumberUCR() As String
Get
Return Me._referenceNumberUCR
End Get
Set
Me._referenceNumberUCR = Value
End Set
End Property
Public Property ActiveBorderTransportMeans() As List(Of ActiveBorderTransportMeansMRType)
Get
Return Me._activeBorderTransportMeans
End Get
Set
Me._activeBorderTransportMeans = Value
End Set
End Property
Public Property SpecificCircumstanceIndicator() As String
Get
Return Me._specificCircumstanceIndicator
End Get
Set
Me._specificCircumstanceIndicator = Value
End Set
End Property
Public Property PlaceOfLoading() As PlaceOfLoadingMRType
Get
Return Me._placeOfLoading
End Get
Set
Me._placeOfLoading = Value
End Set
End Property
Public Property PlaceOfUnloading() As PlaceOfLoadingMRType
Get
Return Me._placeOfUnloading
End Get
Set
Me._placeOfUnloading = Value
End Set
End Property
Public Property TransportCharges() As String
Get
Return Me._transportCharges
End Get
Set
Me._transportCharges = Value
End Set
End Property
Public Property DeclarationType() As String
Get
Return Me._declarationType
End Get
Set
Me._declarationType = Value
End Set
End Property
Public Property TransitDeclarationType() As String
Get
Return Me._transitDeclarationType
End Get
Set
Me._transitDeclarationType = Value
End Set
End Property
Public Property TIRCarnetNumber() As String
Get
Return Me._tIRCarnetNumber
End Get
Set
Me._tIRCarnetNumber = Value
End Set
End Property
Public Property ReducedDatasetIndicator() As String
Get
Return Me._reducedDatasetIndicator
End Get
Set
Me._reducedDatasetIndicator = Value
End Set
End Property
Public Property BindingItinerary() As String
Get
Return Me._bindingItinerary
End Get
Set
Me._bindingItinerary = Value
End Set
End Property
Public Property CountryOfDispatch() As String
Get
Return Me._countryOfDispatch
End Get
Set
Me._countryOfDispatch = Value
End Set
End Property
Public Property CountryOfDestination() As String
Get
Return Me._countryOfDestination
End Get
Set
Me._countryOfDestination = Value
End Set
End Property
Public Property GrossMass() As Decimal
Get
Return Me._grossMass
End Get
Set
Me._grossMass = Value
End Set
End Property
Public Property ContainerIndicator() As String
Get
Return Me._containerIndicator
End Get
Set
Me._containerIndicator = Value
End Set
End Property
Public Property InlandModeOfTransport() As String
Get
Return Me._inlandModeOfTransport
End Get
Set
Me._inlandModeOfTransport = Value
End Set
End Property
Public Property ModeOfTransportAtTheBorder() As String
Get
Return Me._modeOfTransportAtTheBorder
End Get
Set
Me._modeOfTransportAtTheBorder = Value
End Set
End Property
Public Property DepartureTransportMeans() As List(Of DepartureTransportMeansMRType)
Get
Return Me._departureTransportMeans
End Get
Set
Me._departureTransportMeans = Value
End Set
End Property
Public Property CustomsOfficeOfTransitDeclared() As List(Of CustomsOfficeOfTransitDeclaredMRType)
Get
Return Me._customsOfficeOfTransitDeclared
End Get
Set
Me._customsOfficeOfTransitDeclared = Value
End Set
End Property