Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WF / RunTime / EventQueueState.cs / 1305376 / EventQueueState.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- using System; using System.Collections; using System.Collections.Generic; using System.Text; using System.Diagnostics; using System.Globalization; using System.Workflow.ComponentModel; using System.Runtime.Serialization; namespace System.Workflow.Runtime { [Serializable] internal sealed class EventQueueState { Queue deliveredMessages; List> synchronousListeners; List > asynchronousListeners; bool enabled = true; bool transactional = true; [NonSerialized] internal IComparable queueName; [NonSerialized] bool dirty = false; // dirty flag set to true until a transaction completes internal EventQueueState() { this.deliveredMessages = new Queue(); this.synchronousListeners = new List >(); this.asynchronousListeners = new List >(); } internal Queue Messages { get { return this.deliveredMessages; } } internal List > AsynchronousListeners { get { return this.asynchronousListeners; } } internal List > SynchronousListeners { get { return this.synchronousListeners; } } internal bool Enabled { get { return this.enabled; } set { this.enabled = value; } } internal bool Transactional { get { return this.transactional; } set { this.transactional = value; } } internal bool Dirty { get { return this.dirty; } set { this.dirty = value; } } internal void CopyFrom(EventQueueState copyFromState) { this.deliveredMessages = new Queue(copyFromState.Messages); // don't copy Subscribers since this gets fixed // up at access time based on these tracking context ints this.asynchronousListeners.AddRange(copyFromState.AsynchronousListeners.ToArray()); this.synchronousListeners.AddRange(copyFromState.SynchronousListeners.ToArray()); this.enabled = copyFromState.Enabled; this.transactional = copyFromState.Transactional; this.dirty = false; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- using System; using System.Collections; using System.Collections.Generic; using System.Text; using System.Diagnostics; using System.Globalization; using System.Workflow.ComponentModel; using System.Runtime.Serialization; namespace System.Workflow.Runtime { [Serializable] internal sealed class EventQueueState { Queue deliveredMessages; List > synchronousListeners; List > asynchronousListeners; bool enabled = true; bool transactional = true; [NonSerialized] internal IComparable queueName; [NonSerialized] bool dirty = false; // dirty flag set to true until a transaction completes internal EventQueueState() { this.deliveredMessages = new Queue(); this.synchronousListeners = new List >(); this.asynchronousListeners = new List >(); } internal Queue Messages { get { return this.deliveredMessages; } } internal List > AsynchronousListeners { get { return this.asynchronousListeners; } } internal List > SynchronousListeners { get { return this.synchronousListeners; } } internal bool Enabled { get { return this.enabled; } set { this.enabled = value; } } internal bool Transactional { get { return this.transactional; } set { this.transactional = value; } } internal bool Dirty { get { return this.dirty; } set { this.dirty = value; } } internal void CopyFrom(EventQueueState copyFromState) { this.deliveredMessages = new Queue(copyFromState.Messages); // don't copy Subscribers since this gets fixed // up at access time based on these tracking context ints this.asynchronousListeners.AddRange(copyFromState.AsynchronousListeners.ToArray()); this.synchronousListeners.AddRange(copyFromState.SynchronousListeners.ToArray()); this.enabled = copyFromState.Enabled; this.transactional = copyFromState.Transactional; this.dirty = false; } } } // 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
- EditorZoneBase.cs
- Funcletizer.cs
- DataColumnCollection.cs
- TreeBuilder.cs
- Interop.cs
- MessageSecurityOverTcp.cs
- PropertyReferenceExtension.cs
- SetStoryboardSpeedRatio.cs
- RelationshipConverter.cs
- CaseInsensitiveHashCodeProvider.cs
- DataObject.cs
- LinkUtilities.cs
- PrePrepareMethodAttribute.cs
- CancelEventArgs.cs
- DashStyle.cs
- ProxyGenerator.cs
- GeneralTransform3DTo2D.cs
- DataColumnMappingCollection.cs
- TextRangeBase.cs
- ExpandedWrapper.cs
- TargetControlTypeAttribute.cs
- RawKeyboardInputReport.cs
- bidPrivateBase.cs
- LazyTextWriterCreator.cs
- COAUTHIDENTITY.cs
- COAUTHINFO.cs
- AdapterUtil.cs
- control.ime.cs
- NgenServicingAttributes.cs
- GridView.cs
- HtmlInputButton.cs
- ContainerUtilities.cs
- ILGenerator.cs
- XmlProcessingInstruction.cs
- StateMachineWorkflowDesigner.cs
- OleDbConnectionFactory.cs
- ListControlBuilder.cs
- RevocationPoint.cs
- TableLayout.cs
- FontStretchConverter.cs
- OleDbParameter.cs
- DataGridViewSortCompareEventArgs.cs
- StringValueSerializer.cs
- TableChangeProcessor.cs
- List.cs
- HelpEvent.cs
- FirstMatchCodeGroup.cs
- ColorAnimationUsingKeyFrames.cs
- CompositeKey.cs
- Exception.cs
- AttributeAction.cs
- WindowsSspiNegotiation.cs
- FileAuthorizationModule.cs
- GridViewActionList.cs
- HttpWriter.cs
- XmlDocument.cs
- TypedTableBaseExtensions.cs
- XPathAncestorQuery.cs
- EntityType.cs
- RuntimeHelpers.cs
- DataControlFieldCell.cs
- SqlDependencyListener.cs
- StateBag.cs
- PaginationProgressEventArgs.cs
- ObjectConverter.cs
- Geometry.cs
- ViewManager.cs
- DbProviderSpecificTypePropertyAttribute.cs
- BitmapEffectInput.cs
- VariantWrapper.cs
- GACMembershipCondition.cs
- MonikerHelper.cs
- HttpModuleActionCollection.cs
- TokenBasedSetEnumerator.cs
- WindowsBrush.cs
- APCustomTypeDescriptor.cs
- FileLogRecordStream.cs
- PropertyCollection.cs
- DefaultHttpHandler.cs
- SimpleLine.cs
- SHA384.cs
- ExpressionDumper.cs
- XmlBuffer.cs
- ImageIndexConverter.cs
- TabControlEvent.cs
- FtpWebResponse.cs
- TypedDataSourceCodeGenerator.cs
- DesignerActionList.cs
- ErrorFormatterPage.cs
- Keywords.cs
- AttributeUsageAttribute.cs
- PropertyValueChangedEvent.cs
- sqlcontext.cs
- FunctionDescription.cs
- ImageSourceConverter.cs
- DLinqTableProvider.cs
- SatelliteContractVersionAttribute.cs
- HotCommands.cs
- WebPartsSection.cs
- MimeMapping.cs