Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Services / Web / System / Web / Services / Description / Soap12ProtocolImporter.cs / 1305376 / Soap12ProtocolImporter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All Rights Reserved. // Information Contained Herein is Proprietary and Confidential. // //----------------------------------------------------------------------------- namespace System.Web.Services.Description { using System.Web.Services; using System.Web.Services.Protocols; using System.Xml; using System.Xml.Serialization; using System.Xml.Schema; using System.Collections; using System; using System.Reflection; using System.CodeDom; using System.Web.Services.Configuration; using System.Diagnostics; using System.ComponentModel; using System.Security.Permissions; using System.Globalization; ///[PermissionSet(SecurityAction.LinkDemand, Name="FullTrust")] internal class Soap12ProtocolImporter : SoapProtocolImporter { public override string ProtocolName { get { return "Soap12"; } } protected override bool IsBindingSupported() { Soap12Binding soapBinding = (Soap12Binding)Binding.Extensions.Find(typeof(Soap12Binding)); if (soapBinding == null) return false; if (GetTransport(soapBinding.Transport) == null) { UnsupportedBindingWarning(Res.GetString(Res.ThereIsNoSoapTransportImporterThatUnderstands1, soapBinding.Transport)); return false; } return true; } protected override bool IsSoapEncodingPresent(string uriList) { int iStart = 0; do { iStart = uriList.IndexOf(Soap12.Encoding, iStart, StringComparison.Ordinal); if (iStart < 0) break; int iEnd = iStart + Soap12.Encoding.Length; if (iStart == 0 || uriList[iStart-1] == ' ') if (iEnd == uriList.Length || uriList[iEnd] == ' ') return true; iStart = iEnd; } while (iStart < uriList.Length); // not soap 1.2 encoding. let's detect the soap 1.1 encoding and give a better error message. // otherwise just default to the normal "encoding style not supported" error. if (base.IsSoapEncodingPresent(uriList)) UnsupportedOperationBindingWarning(Res.GetString(Res.WebSoap11EncodingStyleNotSupported1, Soap12.Encoding)); return false; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ // // Copyright (c) Microsoft Corporation. All Rights Reserved. // Information Contained Herein is Proprietary and Confidential. // //----------------------------------------------------------------------------- namespace System.Web.Services.Description { using System.Web.Services; using System.Web.Services.Protocols; using System.Xml; using System.Xml.Serialization; using System.Xml.Schema; using System.Collections; using System; using System.Reflection; using System.CodeDom; using System.Web.Services.Configuration; using System.Diagnostics; using System.ComponentModel; using System.Security.Permissions; using System.Globalization; ///[PermissionSet(SecurityAction.LinkDemand, Name="FullTrust")] internal class Soap12ProtocolImporter : SoapProtocolImporter { public override string ProtocolName { get { return "Soap12"; } } protected override bool IsBindingSupported() { Soap12Binding soapBinding = (Soap12Binding)Binding.Extensions.Find(typeof(Soap12Binding)); if (soapBinding == null) return false; if (GetTransport(soapBinding.Transport) == null) { UnsupportedBindingWarning(Res.GetString(Res.ThereIsNoSoapTransportImporterThatUnderstands1, soapBinding.Transport)); return false; } return true; } protected override bool IsSoapEncodingPresent(string uriList) { int iStart = 0; do { iStart = uriList.IndexOf(Soap12.Encoding, iStart, StringComparison.Ordinal); if (iStart < 0) break; int iEnd = iStart + Soap12.Encoding.Length; if (iStart == 0 || uriList[iStart-1] == ' ') if (iEnd == uriList.Length || uriList[iEnd] == ' ') return true; iStart = iEnd; } while (iStart < uriList.Length); // not soap 1.2 encoding. let's detect the soap 1.1 encoding and give a better error message. // otherwise just default to the normal "encoding style not supported" error. if (base.IsSoapEncodingPresent(uriList)) UnsupportedOperationBindingWarning(Res.GetString(Res.WebSoap11EncodingStyleNotSupported1, Soap12.Encoding)); return false; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- BuildProviderUtils.cs
- WindowsScrollBarBits.cs
- IndependentlyAnimatedPropertyMetadata.cs
- WorkflowRuntimeServiceElementCollection.cs
- NamespaceMapping.cs
- Serializer.cs
- SourceElementsCollection.cs
- RegexCapture.cs
- ByteRangeDownloader.cs
- MD5HashHelper.cs
- Stylesheet.cs
- TableCellCollection.cs
- SpeechDetectedEventArgs.cs
- TypeName.cs
- PropertyCondition.cs
- WebBrowser.cs
- MatrixAnimationUsingKeyFrames.cs
- DesignerOptionService.cs
- FormViewAutoFormat.cs
- UseLicense.cs
- DataContractSerializerMessageContractImporter.cs
- XmlRawWriter.cs
- WindowHideOrCloseTracker.cs
- ActivationArguments.cs
- EncryptedPackage.cs
- XmlQueryType.cs
- OrderedDictionary.cs
- serverconfig.cs
- AppSecurityManager.cs
- ArraySortHelper.cs
- DataGridViewCellCollection.cs
- StringResourceManager.cs
- WizardPanel.cs
- PointCollectionConverter.cs
- KeyValueInternalCollection.cs
- TableLayoutSettings.cs
- StrongNamePublicKeyBlob.cs
- assertwrapper.cs
- HTTPNotFoundHandler.cs
- ObjectDataProvider.cs
- GotoExpression.cs
- Rectangle.cs
- EntityStoreSchemaGenerator.cs
- HoistedLocals.cs
- FontStyle.cs
- ComNativeDescriptor.cs
- Light.cs
- xdrvalidator.cs
- DocumentGridPage.cs
- CodeActivity.cs
- SrgsNameValueTag.cs
- counter.cs
- PackageRelationship.cs
- BitmapEffectGeneralTransform.cs
- AccessibilityHelperForXpWin2k3.cs
- CellCreator.cs
- DoubleAnimationBase.cs
- OleDbEnumerator.cs
- Component.cs
- PolyBezierSegmentFigureLogic.cs
- SystemUdpStatistics.cs
- TemplateBindingExtension.cs
- Input.cs
- GregorianCalendarHelper.cs
- ItemMap.cs
- OutputCacheProfile.cs
- XamlTreeBuilderBamlRecordWriter.cs
- BuildProviderAppliesToAttribute.cs
- RequestResizeEvent.cs
- httpserverutility.cs
- indexingfiltermarshaler.cs
- QualificationDataItem.cs
- StackBuilderSink.cs
- LinearKeyFrames.cs
- DBConcurrencyException.cs
- NetStream.cs
- CompositeControl.cs
- Trustee.cs
- AttributeData.cs
- TransactionManager.cs
- LoginView.cs
- RadioButtonPopupAdapter.cs
- ClientTarget.cs
- DBDataPermissionAttribute.cs
- FrameworkElementFactoryMarkupObject.cs
- CharacterBuffer.cs
- XmlDeclaration.cs
- itemelement.cs
- HwndTarget.cs
- ProviderUtil.cs
- CatalogZone.cs
- TabControlCancelEvent.cs
- MetadataItem.cs
- StructuredTypeEmitter.cs
- XmlSchemas.cs
- WindowsTokenRoleProvider.cs
- MatrixKeyFrameCollection.cs
- XDeferredAxisSource.cs
- ParameterSubsegment.cs
- TextDecorationCollectionConverter.cs