Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Configuration / ClientSection.cs / 1 / ClientSection.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.ServiceModel.Configuration { using System.Configuration; using System.ServiceModel.Channels; using System.Globalization; using System.Reflection; using System.Security; public sealed partial class ClientSection : ConfigurationSection, IConfigurationContextProviderInternal { public ClientSection() { } [ConfigurationProperty(ConfigurationStrings.DefaultCollectionName, Options = ConfigurationPropertyOptions.IsDefaultCollection)] public ChannelEndpointElementCollection Endpoints { get {return (ChannelEndpointElementCollection) this[ConfigurationStrings.DefaultCollectionName]; } } [ConfigurationProperty(ConfigurationStrings.Metadata)] public MetadataElement Metadata { get {return (MetadataElement) this[ConfigurationStrings.Metadata]; } } internal static ClientSection GetSection() { return (ClientSection)ConfigurationHelpers.GetSection(ConfigurationStrings.ClientSectionPath); } ////// Critical - calls Critical method UnsafeGetSection which elevates in order to fetch config /// caller must guard access to resultant config section /// [SecurityCritical] internal static ClientSection UnsafeGetSection() { return (ClientSection)ConfigurationHelpers.UnsafeGetSection(ConfigurationStrings.ClientSectionPath); } protected override void InitializeDefault() { this.Metadata.SetDefaults(); } protected override void PostDeserialize() { this.ValidateSection(); base.PostDeserialize(); } void ValidateSection() { ContextInformation context = ConfigurationHelpers.GetEvaluationContext(this); if (context != null) { foreach (ChannelEndpointElement endpoint in this.Endpoints) { BehaviorsSection.ValidateEndpointBehaviorReference(endpoint.BehaviorConfiguration, context, endpoint); BindingsSection.ValidateBindingReference(endpoint.Binding, endpoint.BindingConfiguration, context, endpoint); } } } ContextInformation IConfigurationContextProviderInternal.GetEvaluationContext() { return this.EvaluationContext; } ////// RequiresReview - the return value will be used for a security decision -- see comment in interface definition /// ContextInformation IConfigurationContextProviderInternal.GetOriginalEvaluationContext() { DiagnosticUtility.DebugAssert("Not implemented: IConfigurationContextProviderInternal.GetOriginalEvaluationContext"); return null; } } } // 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
- OrCondition.cs
- DynamicQueryableWrapper.cs
- XmlIncludeAttribute.cs
- BitmapEffectInput.cs
- SqlDependency.cs
- ToolStripLabel.cs
- MaskPropertyEditor.cs
- DynamicPropertyHolder.cs
- WindowsListViewScroll.cs
- FunctionUpdateCommand.cs
- RelatedCurrencyManager.cs
- BinaryObjectInfo.cs
- BitmapMetadata.cs
- SystemDropShadowChrome.cs
- StylusButtonCollection.cs
- AutoGeneratedFieldProperties.cs
- CollectionBuilder.cs
- SystemSounds.cs
- Compiler.cs
- hebrewshape.cs
- DataColumnMappingCollection.cs
- ObjectToken.cs
- _UncName.cs
- TabControl.cs
- SoundPlayerAction.cs
- FixedNode.cs
- PageStatePersister.cs
- SafeBitVector32.cs
- LinkArea.cs
- MetadataItemEmitter.cs
- StdValidatorsAndConverters.cs
- DesigntimeLicenseContext.cs
- DataTableReader.cs
- TypeSchema.cs
- WebConfigurationHost.cs
- TrailingSpaceComparer.cs
- LayoutSettings.cs
- DataSourceControl.cs
- TextAutomationPeer.cs
- SQLInt64.cs
- XmlLinkedNode.cs
- BinaryReader.cs
- DataGridViewTextBoxCell.cs
- ActiveDesignSurfaceEvent.cs
- MenuCommand.cs
- DataGridViewCheckBoxCell.cs
- StorageAssociationTypeMapping.cs
- PtsPage.cs
- UriTemplateMatchException.cs
- ObjectConverter.cs
- SignedXml.cs
- BitConverter.cs
- RewritingPass.cs
- TextTreeObjectNode.cs
- ZoneLinkButton.cs
- ProtectedConfiguration.cs
- ObjectViewEntityCollectionData.cs
- UseAttributeSetsAction.cs
- PreservationFileWriter.cs
- XmlSchemaInclude.cs
- InvalidComObjectException.cs
- DocumentPageHost.cs
- PagedDataSource.cs
- SqlException.cs
- WindowsGraphicsWrapper.cs
- ConsoleKeyInfo.cs
- ObjectListItem.cs
- AsyncSerializedWorker.cs
- StreamReader.cs
- QueryCacheEntry.cs
- KeyValuePair.cs
- EntityModelSchemaGenerator.cs
- HebrewNumber.cs
- Vertex.cs
- ProbeDuplex11AsyncResult.cs
- DataSourceProvider.cs
- ClientFormsAuthenticationMembershipProvider.cs
- TreeWalker.cs
- BaseUriHelper.cs
- DeleteMemberBinder.cs
- Errors.cs
- NavigationProgressEventArgs.cs
- EditorZoneBase.cs
- Inline.cs
- GiveFeedbackEventArgs.cs
- ResourceReader.cs
- XmlEncoding.cs
- DateTimeParse.cs
- WasAdminWrapper.cs
- SessionStateSection.cs
- DrawingContextWalker.cs
- SocketException.cs
- DateTimeConverter2.cs
- ProfileManager.cs
- DetectRunnableInstancesTask.cs
- XmlnsDefinitionAttribute.cs
- COM2PropertyDescriptor.cs
- EventBuilder.cs
- XmlSerializerVersionAttribute.cs
- WebPartVerbsEventArgs.cs