Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Configuration / TcpTransportElement.cs / 1 / TcpTransportElement.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.ServiceModel.Configuration { using System.Configuration; using System.Net.Sockets; using System.ServiceModel.Channels; public sealed partial class TcpTransportElement : ConnectionOrientedTransportElement { public TcpTransportElement() : base() { } public override void ApplyConfiguration(BindingElement bindingElement) { base.ApplyConfiguration(bindingElement); #pragma warning suppress 56506 // [....], base.ApplyConfiguration() validates the argument TcpTransportBindingElement binding = (TcpTransportBindingElement)bindingElement; binding.ListenBacklog = this.ListenBacklog; binding.PortSharingEnabled = this.PortSharingEnabled; binding.TeredoEnabled = this.TeredoEnabled; #pragma warning suppress 56506 // [....], base.ApplyConfiguration() validates the argument this.ConnectionPoolSettings.ApplyConfiguration(binding.ConnectionPoolSettings); } public override Type BindingElementType { get { return typeof(TcpTransportBindingElement); } } public override void CopyFrom(ServiceModelExtensionElement from) { base.CopyFrom(from); TcpTransportElement source = (TcpTransportElement)from; #pragma warning suppress 56506 // [....], base.CopyFrom() validates the argument this.ListenBacklog = source.ListenBacklog; this.PortSharingEnabled = source.PortSharingEnabled; this.TeredoEnabled = source.TeredoEnabled; this.ConnectionPoolSettings.CopyFrom(source.ConnectionPoolSettings); } protected override TransportBindingElement CreateDefaultBindingElement() { return new TcpTransportBindingElement(); } protected internal override void InitializeFrom(BindingElement bindingElement) { base.InitializeFrom(bindingElement); #pragma warning suppress 56506 // [....], base.CopyFrom() validates the argument TcpTransportBindingElement binding = (TcpTransportBindingElement)bindingElement; this.ListenBacklog = binding.ListenBacklog; this.PortSharingEnabled = binding.PortSharingEnabled; this.TeredoEnabled = binding.TeredoEnabled; this.ConnectionPoolSettings.InitializeFrom(binding.ConnectionPoolSettings); } [ConfigurationProperty(ConfigurationStrings.ListenBacklog, DefaultValue = TcpTransportDefaults.ListenBacklog)] [IntegerValidator(MinValue = 1)] public int ListenBacklog { get { return (int)base[ConfigurationStrings.ListenBacklog]; } set { base[ConfigurationStrings.ListenBacklog] = value; } } [ConfigurationProperty(ConfigurationStrings.PortSharingEnabled, DefaultValue = TcpTransportDefaults.PortSharingEnabled)] public bool PortSharingEnabled { get { return (bool)base[ConfigurationStrings.PortSharingEnabled]; } set { base[ConfigurationStrings.PortSharingEnabled] = value; } } [ConfigurationProperty(ConfigurationStrings.TeredoEnabled, DefaultValue = TcpTransportDefaults.TeredoEnabled)] public bool TeredoEnabled { get { return (bool)base[ConfigurationStrings.TeredoEnabled]; } set { base[ConfigurationStrings.TeredoEnabled] = value; } } [ConfigurationProperty(ConfigurationStrings.ConnectionPoolSettings)] public TcpConnectionPoolSettingsElement ConnectionPoolSettings { get { return (TcpConnectionPoolSettingsElement)base[ConfigurationStrings.ConnectionPoolSettings]; } set { base[ConfigurationStrings.ConnectionPoolSettings] = value; } } } } // 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
- PropertyGridEditorPart.cs
- TextShapeableCharacters.cs
- ComplexTypeEmitter.cs
- XamlPathDataSerializer.cs
- BindingSourceDesigner.cs
- ExpressionServices.cs
- ArrangedElement.cs
- CaseInsensitiveOrdinalStringComparer.cs
- FieldToken.cs
- RectIndependentAnimationStorage.cs
- TabItem.cs
- StateItem.cs
- PresentationAppDomainManager.cs
- TCEAdapterGenerator.cs
- PenLineJoinValidation.cs
- SigningCredentials.cs
- DataGridViewCellStyleEditor.cs
- CompatibleComparer.cs
- UIAgentAsyncEndRequest.cs
- SmiMetaDataProperty.cs
- WhitespaceSignificantCollectionAttribute.cs
- ChangeDirector.cs
- COM2Properties.cs
- EventWaitHandleSecurity.cs
- HttpRequestCacheValidator.cs
- Stack.cs
- FixedNode.cs
- TraceInternal.cs
- CapabilitiesSection.cs
- AssemblyBuilder.cs
- HttpConfigurationSystem.cs
- StackOverflowException.cs
- OptimisticConcurrencyException.cs
- HitTestParameters3D.cs
- RecordsAffectedEventArgs.cs
- DependencyPropertyAttribute.cs
- PropertyOverridesDialog.cs
- ReaderWriterLock.cs
- WebContext.cs
- EventWaitHandle.cs
- wmiprovider.cs
- DelegateHelpers.cs
- RC2CryptoServiceProvider.cs
- DrawingBrush.cs
- ReturnEventArgs.cs
- LinkDescriptor.cs
- IndicShape.cs
- MinimizableAttributeTypeConverter.cs
- UserControlFileEditor.cs
- EastAsianLunisolarCalendar.cs
- UriGenerator.cs
- RectAnimationUsingKeyFrames.cs
- WebPartAddingEventArgs.cs
- _ConnectOverlappedAsyncResult.cs
- XmlUtf8RawTextWriter.cs
- Console.cs
- XmlParserContext.cs
- ReflectTypeDescriptionProvider.cs
- XmlCharacterData.cs
- _AutoWebProxyScriptWrapper.cs
- _SslState.cs
- CodeRegionDirective.cs
- TypeDescriptorContext.cs
- CultureInfoConverter.cs
- CommonXSendMessage.cs
- InputScopeManager.cs
- ClientBuildManagerCallback.cs
- ExtensionFile.cs
- CustomValidator.cs
- PrintEvent.cs
- SafeFileMappingHandle.cs
- ValueTypeFixupInfo.cs
- QilValidationVisitor.cs
- Base64Encoder.cs
- CodeMemberField.cs
- WaitHandleCannotBeOpenedException.cs
- _UriSyntax.cs
- AVElementHelper.cs
- BinaryFormatter.cs
- ChangePasswordAutoFormat.cs
- GreaterThanOrEqual.cs
- DocumentViewer.cs
- PixelFormatConverter.cs
- VisualStyleInformation.cs
- TabControlCancelEvent.cs
- DataGridViewCellStyleEditor.cs
- SoapAttributeOverrides.cs
- DataGridTablesFactory.cs
- ClockGroup.cs
- InstallHelper.cs
- DrawingCollection.cs
- SqlCharStream.cs
- COM2Enum.cs
- DataBinder.cs
- XmlReflectionImporter.cs
- EntitySetBaseCollection.cs
- QuotedStringWriteStateInfo.cs
- HtmlInputHidden.cs
- TypeDescriptionProviderAttribute.cs
- DataServiceConfiguration.cs