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
- BasicExpressionVisitor.cs
- CodeParameterDeclarationExpression.cs
- DynamicFilterExpression.cs
- LinqDataSourceUpdateEventArgs.cs
- IISMapPath.cs
- ZipIOCentralDirectoryFileHeader.cs
- TargetParameterCountException.cs
- DataKey.cs
- MessageDecoder.cs
- querybuilder.cs
- ProcessInputEventArgs.cs
- OdbcStatementHandle.cs
- OSFeature.cs
- ApplicationActivator.cs
- MimeBasePart.cs
- HtmlShimManager.cs
- DataGridViewAutoSizeColumnModeEventArgs.cs
- PropertyGridCommands.cs
- PackageDigitalSignature.cs
- WebPartDisplayModeCollection.cs
- ResourceReader.cs
- SessionEndingEventArgs.cs
- formatter.cs
- HttpResponseHeader.cs
- ApplicationId.cs
- FloatUtil.cs
- BoundPropertyEntry.cs
- ExtensionMethods.cs
- TrackingAnnotationCollection.cs
- ComboBox.cs
- StylusPlugin.cs
- ManagedCodeMarkers.cs
- TextEndOfLine.cs
- ListBoxItem.cs
- RequestQueue.cs
- _SslStream.cs
- WindowsToolbarAsMenu.cs
- ValueQuery.cs
- SimpleLine.cs
- MDIWindowDialog.cs
- BasicBrowserDialog.cs
- ClassGenerator.cs
- TreePrinter.cs
- Size3D.cs
- DisplayNameAttribute.cs
- HtmlPanelAdapter.cs
- SchemaElementLookUpTableEnumerator.cs
- WindowsIdentity.cs
- AnnotationResourceChangedEventArgs.cs
- ObjectListCommandEventArgs.cs
- DiscardableAttribute.cs
- TagNameToTypeMapper.cs
- EncryptedPackageFilter.cs
- PropertyIDSet.cs
- OleDbCommand.cs
- WorkflowMessageEventHandler.cs
- QueryAccessibilityHelpEvent.cs
- ReturnValue.cs
- DataRecord.cs
- WindowsListView.cs
- ClockGroup.cs
- FormatterServices.cs
- AddDataControlFieldDialog.cs
- SkipStoryboardToFill.cs
- RegexCompiler.cs
- TdsEnums.cs
- SqlDataSourceCache.cs
- TrustManagerPromptUI.cs
- SafeNativeMethods.cs
- WebPartEditorApplyVerb.cs
- CodeCompiler.cs
- HatchBrush.cs
- AddInToken.cs
- X509CertificateRecipientClientCredential.cs
- PerfCounterSection.cs
- X509Chain.cs
- StatusBar.cs
- SqlInternalConnectionSmi.cs
- CssStyleCollection.cs
- CodeFieldReferenceExpression.cs
- ToolStripManager.cs
- FilterFactory.cs
- Logging.cs
- Overlapped.cs
- ObjectComplexPropertyMapping.cs
- UIElementPropertyUndoUnit.cs
- Helper.cs
- StandardCommands.cs
- NativeBuffer.cs
- CharEnumerator.cs
- AttachmentCollection.cs
- DataProtection.cs
- WindowsGraphics.cs
- ThreadExceptionDialog.cs
- IPHostEntry.cs
- TextDecorationLocationValidation.cs
- ToolStripDropDownButton.cs
- DesignerActionVerbList.cs
- CodeIterationStatement.cs
- UnmanagedMemoryStream.cs