Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

ProtocolImporter Class

Provides common functionality across communication protocols for generating classes for Web services.

System.Object
  System.Web.Services.Description.ProtocolImporter
    System.Web.Services.Description.SoapProtocolImporter

Namespace:  System.Web.Services.Description
Assembly:  System.Web.Services (in System.Web.Services.dll)
[PermissionSetAttribute(SecurityAction.InheritanceDemand, Name = "FullTrust")]
[PermissionSetAttribute(SecurityAction.LinkDemand, Name = "FullTrust")]
public abstract class ProtocolImporter

The ProtocolImporter type exposes the following members.

  NameDescription
Protected methodProtocolImporterInitializes a new instance of the ProtocolImporter class.
Top
  NameDescription
Public propertyAbstractSchemasGets the abstract XML schemas used by the associated ServiceDescriptionImporter instance.
Public propertyBindingGets the Web Services Description Language (WSDL) binding that the protocol importer is currently processing to generate a class.
Public propertyClassNameGets the name of the binding class that is currently being generated.
Public propertyClassNamesGets the CodeIdentifiers object that generates a unique name for the binding class that is currently being generated.
Public propertyCodeNamespaceGets a representation of the .NET Framework namespace of the binding classes that are being generated.
Public propertyCodeTypeDeclarationGets a representation of the binding class that is currently being generated.
Public propertyConcreteSchemasGets the concrete XML schemas used by the associated ServiceDescriptionImporter instance.
Public propertyInputMessageGets the Web Services Description Language (WSDL) input message for the abstract operation that the protocol importer is currently processing to generate a method in a binding class.
Public propertyMethodNameGets the name of the binding class method which that the protocol importer is currently generating.
Public propertyOperationGets the abstract Web Services Description Language (WSDL) operation that the protocol importer is currently processing to generate a method in a binding class.
Public propertyOperationBindingGets the Web Services Description Language (WSDL) operation binding that the protocol importer is currently processing to generate a method in a binding class.
Public propertyOutputMessageGets the Web Services Description Language (WSDL) output message for the abstract operation that the protocol importer is currently processing to generate a method in a binding class.
Public propertyPortGets a Web Services Description Language (WSDL) port that contains a reference to the binding that the protocol importer is currently processing to generate a binding class. If more than one port refers to the current binding, the current port is the one in which the binding has most recently been found.
Public propertyPortTypeGets the Web Services Description Language (WSDL) PortType that is implemented by the binding that the protocol importer is currently processing to generate a binding class.
Public propertyProtocolNameAbstract property that concrete derived classes must implement to get the name of the protocol being used.
Public propertySchemasGets all the XML schemas, both abstract and concrete, used by the associated ServiceDescriptionImporter instance.
Public propertyServiceGets the Web Services Description Language (WSDL) service that contains a reference to the binding that the protocol importer is currently processing to generate a binding class.
Public propertyServiceDescriptionsGets the ServiceDescriptionCollection objects that belong to the associated ServiceDescriptionImporter instance that are searched for bindings from which to generate binding classes.
Public propertyStyleGets an enumeration value that indicates whether a client proxy class or an abstract server class is being generated. The values are Client and Server. The value is that of the associated ServiceDescriptionImporter instance's Style property.
Public propertyWarningsGets or sets a ServiceDescriptionImportWarnings enumeration value that indicates the types of warnings, if any, issued by the protocol importer while generating binding classes.
Top
  NameDescription
Public methodAddExtensionWarningCommentsFor each unhandled extension or XML element in the input extensions collection, turns on a RequiredExtensionsIgnored or OptionalExtensionsIgnored warning for each unhandled extension or XML element in the input extensions collection.
Protected methodBeginClassWhen overridden in a derived class, initializes the generation of a binding class.
Protected methodBeginNamespaceWhen overridden in a derived class, performs namespace-wide initialization during code generation.
Protected methodEndClassWhen overridden in a derived class, processes a binding class.
Protected methodEndNamespaceWhen overridden in a derived class, performs processing for an entire namespace.
Public methodEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Protected methodGenerateMethodWhen overridden in a derived class, generates method code for binding classes.
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodIsBindingSupportedWhen overridden in a derived class, determines whether a class can be generated for the current binding.
Protected methodIsOperationFlowSupportedWhen overridden in a derived class, determines whether the current operation's operation flow is supported.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodOperationBindingSyntaxExceptionProduces an Exception indicating that the current OperationBinding instance for which a binding class is being generated is invalid within the target namespace.
Public methodOperationSyntaxExceptionProduces an Exception indicating that the current Operation instance for which a binding class is being generated is invalid within the target namespace.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Public methodUnsupportedBindingWarningTurns on an UnsupportedBindingsIgnored warning in the ServiceDescriptionImportWarnings enumeration obtained through the Warnings property. This method also adds a warning message to the comments for the class that is being generated.
Public methodUnsupportedOperationBindingWarningTurns on an UnsupportedOperationsIgnored warning in the ServiceDescriptionImportWarnings enumeration obtained through the Warnings property. This method also adds a warning message to the comments for the class that is being generated.
Public methodUnsupportedOperationWarningTurns on an UnsupportedOperationsIgnored warning in the ServiceDescriptionImportWarnings enumeration obtained through the Warnings property. This method also adds a warning message to the comments for the class that is being generated.
Top

The abstract ProtocolImporter class and its concrete derived classes generate client proxy code or abstract server code according to a specified communication protocol. ProtocolImporter provides common functionality regardless of the protocol. Within a given protocol, a concrete derived class generates a class for each supported binding defined in a Web Services Description Language (WSDL) document. Typically, instead of directly invoking classes derived from ProtocolImporter, a developer uses these classes indirectly through the ServiceDescriptionImporter class.

.NET Framework

Supported in: 4.5.1, 4.5, 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 3.5 SP1

Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.