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
- TextBlockAutomationPeer.cs
- PositiveTimeSpanValidatorAttribute.cs
- Rect3D.cs
- Preprocessor.cs
- DefaultValueAttribute.cs
- WindowInteractionStateTracker.cs
- Point3DAnimationBase.cs
- DesignerActionList.cs
- DataGridViewHitTestInfo.cs
- LinkUtilities.cs
- TiffBitmapDecoder.cs
- Type.cs
- Inflater.cs
- Pair.cs
- TraceData.cs
- CaseInsensitiveOrdinalStringComparer.cs
- AgileSafeNativeMemoryHandle.cs
- safemediahandle.cs
- MemberRelationshipService.cs
- WaitHandle.cs
- TranslateTransform.cs
- DllHostInitializer.cs
- EntitySqlQueryBuilder.cs
- ListViewInsertionMark.cs
- ChannelManager.cs
- DurableOperationAttribute.cs
- PrintSchema.cs
- XamlToRtfParser.cs
- CompositeScriptReference.cs
- ProjectionRewriter.cs
- WindowsTab.cs
- DetailsViewPageEventArgs.cs
- TabletCollection.cs
- RichTextBoxAutomationPeer.cs
- CompilerParameters.cs
- AlternationConverter.cs
- ConfigurationManagerHelperFactory.cs
- ArglessEventHandlerProxy.cs
- Quaternion.cs
- localization.cs
- Freezable.cs
- ObjectDataSourceFilteringEventArgs.cs
- UserPersonalizationStateInfo.cs
- DataQuery.cs
- StyleSheetComponentEditor.cs
- ToolboxItem.cs
- HwndSubclass.cs
- ActiveDesignSurfaceEvent.cs
- ProcessProtocolHandler.cs
- WsatServiceCertificate.cs
- NameValueCollection.cs
- ModelItem.cs
- TransformProviderWrapper.cs
- DataColumnPropertyDescriptor.cs
- ClonableStack.cs
- TouchesCapturedWithinProperty.cs
- CodeArgumentReferenceExpression.cs
- XmlDataSource.cs
- SystemResources.cs
- WebControlAdapter.cs
- ReadingWritingEntityEventArgs.cs
- InputQueue.cs
- SqlFileStream.cs
- SynchronizedChannelCollection.cs
- HttpListenerException.cs
- AtlasWeb.Designer.cs
- MsmqIntegrationProcessProtocolHandler.cs
- Event.cs
- GenericTypeParameterBuilder.cs
- SecurityException.cs
- StoreItemCollection.cs
- SemaphoreFullException.cs
- StringUtil.cs
- CacheManager.cs
- QueryOutputWriter.cs
- PartitionedStreamMerger.cs
- DataTableClearEvent.cs
- DbProviderConfigurationHandler.cs
- ToolBar.cs
- ObjectConverter.cs
- StorageRoot.cs
- WebExceptionStatus.cs
- Tile.cs
- PhoneCall.cs
- KeyValueInternalCollection.cs
- FormattedTextSymbols.cs
- RepeaterItem.cs
- odbcmetadatacollectionnames.cs
- ExpressionServices.cs
- Switch.cs
- UpDownEvent.cs
- PageTrueTypeFont.cs
- HttpResponseInternalWrapper.cs
- HuffCodec.cs
- SamlAudienceRestrictionCondition.cs
- FileDialogCustomPlacesCollection.cs
- IndexingContentUnit.cs
- StatusBarPanelClickEvent.cs
- Attributes.cs
- HttpCookie.cs