本文整理汇总了VB.NET中System.Web.Services.Description.MimeMultipartRelatedBinding类的典型用法代码示例。如果您正苦于以下问题:VB.NET MimeMultipartRelatedBinding类的具体用法?VB.NET MimeMultipartRelatedBinding怎么用?VB.NET MimeMultipartRelatedBinding使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了MimeMultipartRelatedBinding类的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的VB.NET代码示例。
示例1: Main
' 导入命名空间
Imports System.Web.Services.Description
Namespace MimeContentBinding_work
Class MyMimeContentClass
Shared Sub Main()
Dim myServicDescription As ServiceDescription = _
ServiceDescription.Read("MimeMultiPartRelatedSample_vb.wsdl")
' Get the binding collection.
Dim myBindingCollection As BindingCollection = _
myServicDescription.Bindings
Dim index As Integer = 0
Dim i As Integer
For i = 0 To myBindingCollection.Count - 1
' Get the collection for MimeServiceHttpPost.
If myBindingCollection(i).Name = "MimeServiceHttpPost" Then
Dim myOperationBindingCollection As _
OperationBindingCollection = myBindingCollection(i).Operations
Dim myOutputBinding As OutputBinding = _
myOperationBindingCollection(0).Output
Dim myServiceDescriptionFormatExtensionCollection As _
ServiceDescriptionFormatExtensionCollection = _
myOutputBinding.Extensions
Dim myMimeMultipartRelatedBinding As _
MimeMultipartRelatedBinding = _
CType(myServiceDescriptionFormatExtensionCollection.Find( _
GetType(MimeMultipartRelatedBinding)), _
MimeMultipartRelatedBinding)
Dim myMimePartCollection As MimePartCollection = _
myMimeMultipartRelatedBinding.Parts
Dim myMimePart As MimePart
For Each myMimePart In myMimePartCollection
Console.WriteLine("Extension Types added to MimePart: " & _
index.ToString())
Console.WriteLine("----------------------------")
index = index + 1
Dim myExtension As Object
For Each myExtension In myMimePart.Extensions
Console.WriteLine(myExtension.GetType())
Next myExtension
Console.WriteLine()
Next myMimePart
Exit For
End If
Next i
End Sub
End Class
End Namespace 'MimeContentBinding_work