Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Dispatcher / SharedRuntimeState.cs / 1 / SharedRuntimeState.cs
//------------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------------------------
namespace System.ServiceModel.Dispatcher
{
using System;
class SharedRuntimeState
{
bool isImmutable;
bool enableFaults = true;
bool isOnServer;
bool manualAddressing;
bool validateMustUnderstand = true;
internal SharedRuntimeState(bool isOnServer)
{
this.isOnServer = isOnServer;
}
internal bool EnableFaults
{
get { return this.enableFaults; }
set { this.enableFaults = value; }
}
internal bool IsOnServer
{
get { return this.isOnServer; }
}
internal bool ManualAddressing
{
get { return this.manualAddressing; }
set { this.manualAddressing = value; }
}
internal bool ValidateMustUnderstand
{
get { return this.validateMustUnderstand; }
set { this.validateMustUnderstand = value; }
}
internal void LockDownProperties()
{
this.isImmutable = true;
}
internal void ThrowIfImmutable()
{
if (this.isImmutable)
{
if (this.IsOnServer)
{
throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidOperationException(SR.GetString(SR.SFxImmutableServiceHostBehavior0)));
}
else
{
throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidOperationException(SR.GetString(SR.SFxImmutableChannelFactoryBehavior0)));
}
}
}
}
}
// 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
- ClipboardData.cs
- ThumbAutomationPeer.cs
- StylusPlugInCollection.cs
- XmlQueryStaticData.cs
- mda.cs
- SecurityState.cs
- Group.cs
- TextFormatterImp.cs
- ObjectDisposedException.cs
- ConsumerConnectionPoint.cs
- BrowserDefinition.cs
- SqlFacetAttribute.cs
- RuleRefElement.cs
- InfoCardBinaryReader.cs
- InvalidDataException.cs
- FlowDocumentScrollViewer.cs
- ItemsControl.cs
- CommandManager.cs
- CancelEventArgs.cs
- BaseProcessor.cs
- DataGridRowHeader.cs
- XmlCharType.cs
- PassportAuthenticationModule.cs
- ListCommandEventArgs.cs
- SqlRemoveConstantOrderBy.cs
- ZipIOExtraFieldElement.cs
- SqlNodeAnnotations.cs
- ContainerControlDesigner.cs
- UMPAttributes.cs
- CompositeScriptReference.cs
- TextControlDesigner.cs
- ScaleTransform3D.cs
- FixedHighlight.cs
- NamespaceQuery.cs
- XmlTypeAttribute.cs
- ConnectionInterfaceCollection.cs
- Soap.cs
- ObjectFullSpanRewriter.cs
- ButtonDesigner.cs
- DBProviderConfigurationHandler.cs
- SafeHandles.cs
- InvalidCommandTreeException.cs
- StorageScalarPropertyMapping.cs
- XmlSchemaObject.cs
- AssociationEndMember.cs
- EventDescriptor.cs
- HostVisual.cs
- DateTimeStorage.cs
- SystemWebCachingSectionGroup.cs
- PkcsMisc.cs
- ObjectCache.cs
- MemberDescriptor.cs
- ObjectFactoryCodeDomTreeGenerator.cs
- FrameworkTemplate.cs
- MULTI_QI.cs
- FileLoadException.cs
- ITreeGenerator.cs
- PrivilegeNotHeldException.cs
- ImageMapEventArgs.cs
- Int32Rect.cs
- XmlSchemaComplexType.cs
- WebPartConnection.cs
- ControlCollection.cs
- ClusterRegistryConfigurationProvider.cs
- SecurityTokenValidationException.cs
- Positioning.cs
- ComponentEditorForm.cs
- ServiceModelEnumValidator.cs
- CodeAttributeArgument.cs
- Helpers.cs
- VBCodeProvider.cs
- Rotation3D.cs
- ClientScriptManagerWrapper.cs
- XmlQueryContext.cs
- IndexExpression.cs
- NullExtension.cs
- TypefaceMetricsCache.cs
- SoapIncludeAttribute.cs
- ToolStripSeparator.cs
- BinaryFormatterWriter.cs
- ColorConvertedBitmap.cs
- IEnumerable.cs
- PolicyUnit.cs
- InputScopeManager.cs
- SliderAutomationPeer.cs
- ProviderMetadata.cs
- CookieProtection.cs
- uribuilder.cs
- HierarchicalDataBoundControlAdapter.cs
- FrameAutomationPeer.cs
- OpenTypeCommon.cs
- MethodBuilderInstantiation.cs
- PeerInputChannelListener.cs
- SchemaNamespaceManager.cs
- HitTestFilterBehavior.cs
- ConfigXmlWhitespace.cs
- SynchronizedDispatch.cs
- AuthenticationManager.cs
- Propagator.ExtentPlaceholderCreator.cs
- HttpEncoderUtility.cs