Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / System.Runtime.DurableInstancing / System / Runtime / DurableInstancing / InstanceHandleReference.cs / 1305376 / InstanceHandleReference.cs
//---------------------------------------------------------------- // Copyright (c) Microsoft Corporation. All rights reserved. //--------------------------------------------------------------- namespace System.Runtime.DurableInstancing { // This class serves as a reference back to an InstanceHandle from the perspective of an InstanceOwner for tracking lock binds in progress. // It works in two modes, one as a pure cancelable handle reference (where cancelling means nulling out the reference) and the // other as a queue position marker for determining when all of the in-progress requests at one point in time are all done. In the // marker mode (InstanceOwner.LockResolutionMarker), it carries some additional context for maintaining the state of the // InstancePersistenceContext.ResolveExistingLock operation. class InstanceHandleReference { internal InstanceHandleReference(InstanceHandle instanceHandle) { Fx.Assert(instanceHandle != null, "Null instanceHandle provided to InstanceHandleReference."); InstanceHandle = instanceHandle; } // This is set to null when the InstanceHandleReference is detached from the InstanceHandle - i.e. it is // no longer in use, and exists just to make it possible to lazily drain out of the various queues. internal InstanceHandle InstanceHandle { get; private set; } internal void Cancel() { Fx.Assert(InstanceHandle != null, "InstanceHandleReference already cancelled."); InstanceHandle = null; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TextTreeFixupNode.cs
- MediaContextNotificationWindow.cs
- BaseCAMarshaler.cs
- MsmqBindingBase.cs
- HttpCapabilitiesEvaluator.cs
- ToolStripItemRenderEventArgs.cs
- Operator.cs
- ProviderUtil.cs
- ObservableCollection.cs
- Instrumentation.cs
- PrintPageEvent.cs
- KeyTime.cs
- HelpInfo.cs
- HitTestFilterBehavior.cs
- ISSmlParser.cs
- XmlSchemaImport.cs
- COM2ColorConverter.cs
- ConfigurationSchemaErrors.cs
- XmlAttributeCollection.cs
- QuinticEase.cs
- NextPreviousPagerField.cs
- Focus.cs
- SafeHandles.cs
- StringReader.cs
- BehaviorEditorPart.cs
- HtmlTableRowCollection.cs
- DependsOnAttribute.cs
- ImageCodecInfo.cs
- tooltip.cs
- DbProviderSpecificTypePropertyAttribute.cs
- Grid.cs
- BinaryObjectInfo.cs
- TextStore.cs
- ContainerSelectorGlyph.cs
- DataSourceExpressionCollection.cs
- Properties.cs
- UnsafeNativeMethods.cs
- ComponentChangedEvent.cs
- CellParagraph.cs
- ViewStateModeByIdAttribute.cs
- DataTableCollection.cs
- wmiutil.cs
- ECDiffieHellmanCngPublicKey.cs
- DbExpressionVisitor.cs
- HierarchicalDataSourceConverter.cs
- CustomLineCap.cs
- OdbcInfoMessageEvent.cs
- ReferenceSchema.cs
- WebRequestModuleElement.cs
- ZoneIdentityPermission.cs
- RequestReplyCorrelator.cs
- GlobalizationAssembly.cs
- TrackingMemoryStream.cs
- WindowsTokenRoleProvider.cs
- XmlSchemaSimpleTypeRestriction.cs
- Configuration.cs
- ElapsedEventArgs.cs
- ThrowHelper.cs
- EmptyReadOnlyDictionaryInternal.cs
- FormViewUpdatedEventArgs.cs
- DataControlLinkButton.cs
- SignerInfo.cs
- ConfigurationElementProperty.cs
- ResourceDictionaryCollection.cs
- CurrencyWrapper.cs
- Speller.cs
- TextSelection.cs
- DependencyPropertyKind.cs
- FromRequest.cs
- RadioButtonFlatAdapter.cs
- DataErrorValidationRule.cs
- ToolStripOverflow.cs
- ToolboxItemWrapper.cs
- ServiceCredentialsElement.cs
- SQLDecimal.cs
- ADMembershipUser.cs
- PerformanceCounterPermissionEntry.cs
- MailAddressCollection.cs
- UnsafeMethods.cs
- ICspAsymmetricAlgorithm.cs
- EdmToObjectNamespaceMap.cs
- InternalRelationshipCollection.cs
- StringKeyFrameCollection.cs
- TreeNodeBinding.cs
- PaintValueEventArgs.cs
- ListBoxChrome.cs
- ActivityExecutionFilter.cs
- DispatcherFrame.cs
- AutomationIdentifier.cs
- NonClientArea.cs
- HijriCalendar.cs
- PriorityChain.cs
- WCFModelStrings.Designer.cs
- PrimitiveType.cs
- WindowsNonControl.cs
- FederatedMessageSecurityOverHttpElement.cs
- VariableQuery.cs
- RemotingClientProxy.cs
- CaseStatementSlot.cs
- X509CertificateValidator.cs