Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Configuration / WindowsStreamSecurityElement.cs / 1 / WindowsStreamSecurityElement.cs
//------------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------------------------
namespace System.ServiceModel.Configuration
{
using System.ComponentModel;
using System.Configuration;
using System.Globalization;
using System.Net.Security;
using System.Text;
using System.ServiceModel.Channels;
public sealed partial class WindowsStreamSecurityElement : BindingElementExtensionElement
{
public WindowsStreamSecurityElement()
{
}
[ConfigurationProperty(ConfigurationStrings.ProtectionLevel, DefaultValue = ConnectionOrientedTransportDefaults.ProtectionLevel)]
[StandardRuntimeEnumValidator(typeof(ProtectionLevel))]
public ProtectionLevel ProtectionLevel
{
get { return (ProtectionLevel)base[ConfigurationStrings.ProtectionLevel]; }
set { base[ConfigurationStrings.ProtectionLevel] = value; }
}
public override void ApplyConfiguration(BindingElement bindingElement)
{
base.ApplyConfiguration(bindingElement);
WindowsStreamSecurityBindingElement windowsBindingElement =
(WindowsStreamSecurityBindingElement)bindingElement;
windowsBindingElement.ProtectionLevel = this.ProtectionLevel;
}
protected internal override BindingElement CreateBindingElement()
{
WindowsStreamSecurityBindingElement windowsBindingElement
= new WindowsStreamSecurityBindingElement();
this.ApplyConfiguration(windowsBindingElement);
return windowsBindingElement;
}
public override Type BindingElementType
{
get { return typeof(WindowsStreamSecurityBindingElement); }
}
public override void CopyFrom(ServiceModelExtensionElement from)
{
base.CopyFrom(from);
WindowsStreamSecurityElement source = (WindowsStreamSecurityElement)from;
#pragma warning suppress 56506 // [....], base.CopyFrom() validates the argument
this.ProtectionLevel = source.ProtectionLevel;
}
protected internal override void InitializeFrom(BindingElement bindingElement)
{
base.InitializeFrom(bindingElement);
WindowsStreamSecurityBindingElement windowsBindingElement
= (WindowsStreamSecurityBindingElement)bindingElement;
this.ProtectionLevel = windowsBindingElement.ProtectionLevel;
}
}
}
// 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
- FreezableCollection.cs
- MessageTraceRecord.cs
- ScriptMethodAttribute.cs
- InfoCardUIAgent.cs
- DisposableCollectionWrapper.cs
- SystemIPInterfaceProperties.cs
- CodeLinePragma.cs
- WebScriptServiceHost.cs
- CompoundFileStorageReference.cs
- CultureSpecificCharacterBufferRange.cs
- RadioButtonPopupAdapter.cs
- CacheOutputQuery.cs
- FocusTracker.cs
- PkcsMisc.cs
- WorkflowOperationBehavior.cs
- SQLDateTime.cs
- DataGridViewCellParsingEventArgs.cs
- PageThemeParser.cs
- RegexWorker.cs
- TextTreeText.cs
- MessageBox.cs
- Overlapped.cs
- SqlNamer.cs
- CollectionViewGroup.cs
- ReadWriteSpinLock.cs
- SqlDataSourceSelectingEventArgs.cs
- MultipartIdentifier.cs
- CollectionBase.cs
- GridViewEditEventArgs.cs
- ShapingEngine.cs
- MultiSelector.cs
- Automation.cs
- RightsManagementEncryptionTransform.cs
- WebPartConnectionsCloseVerb.cs
- AngleUtil.cs
- IxmlLineInfo.cs
- XmlBinaryReader.cs
- EncoderReplacementFallback.cs
- FormParameter.cs
- Rule.cs
- _NTAuthentication.cs
- XsdDuration.cs
- CannotUnloadAppDomainException.cs
- ExpandableObjectConverter.cs
- CriticalHandle.cs
- ServiceMetadataContractBehavior.cs
- GridItemPattern.cs
- TextRangeEditTables.cs
- TableLayoutCellPaintEventArgs.cs
- storepermission.cs
- XamlTemplateSerializer.cs
- DataGridViewRowPrePaintEventArgs.cs
- AttachmentService.cs
- EventManager.cs
- PolicyManager.cs
- ListSortDescription.cs
- ItemMap.cs
- FieldAccessException.cs
- TraceProvider.cs
- XamlFxTrace.cs
- GroupStyle.cs
- XmlCustomFormatter.cs
- TemplateBuilder.cs
- FormViewPagerRow.cs
- RSAProtectedConfigurationProvider.cs
- RequiredAttributeAttribute.cs
- _UncName.cs
- ResourceManager.cs
- DigitShape.cs
- PropertyHelper.cs
- OleDbMetaDataFactory.cs
- ItemsPresenter.cs
- _SafeNetHandles.cs
- Compiler.cs
- ResourceIDHelper.cs
- TextClipboardData.cs
- InfoCardRSAOAEPKeyExchangeFormatter.cs
- Activator.cs
- CopyCodeAction.cs
- SchemaNotation.cs
- ProjectionQueryOptionExpression.cs
- EnvironmentPermission.cs
- ConfigXmlWhitespace.cs
- UInt64Converter.cs
- ParenthesizePropertyNameAttribute.cs
- ConfigurationStrings.cs
- safelinkcollection.cs
- Module.cs
- DateTimeFormat.cs
- DBCSCodePageEncoding.cs
- DataGridViewTopRowAccessibleObject.cs
- DataObjectSettingDataEventArgs.cs
- Int16.cs
- MimeXmlReflector.cs
- UserValidatedEventArgs.cs
- MailSettingsSection.cs
- DataGridViewDataConnection.cs
- Helper.cs
- Substitution.cs
- ThemeableAttribute.cs