Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / tx / System / Transactions / TransactionOptions.cs / 1305376 / TransactionOptions.cs
using System; using System.Security.Permissions; using System.Runtime.InteropServices; using System.Runtime.CompilerServices; namespace System.Transactions { public struct TransactionOptions { private TimeSpan timeout; private System.Transactions.IsolationLevel isolationLevel; public TimeSpan Timeout { get { return this.timeout; } set { this.timeout = value; } } public System.Transactions.IsolationLevel IsolationLevel { get { return this.isolationLevel; } set { this.isolationLevel = value; } } public override int GetHashCode() { return base.GetHashCode(); // Don't have anything better to do. } public override bool Equals( object obj ) { if( !(obj is TransactionOptions) ) { // Can't use 'as' for a value type return false; } TransactionOptions opts = (TransactionOptions)obj; return (opts.timeout == this.timeout) && (opts.isolationLevel == this.isolationLevel); } // Changing paramater names would be a breaking change for little benefit. [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly")] public static bool operator==( TransactionOptions x, TransactionOptions y ) { return x.Equals( y ); } // Changing paramater names would be a breaking change for little benefit. [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly")] public static bool operator!=( TransactionOptions x, TransactionOptions y ) { return !x.Equals( y ); } } } // 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
- BindingExpression.cs
- MouseBinding.cs
- WebControl.cs
- FixedSOMPageElement.cs
- XPathNodePointer.cs
- HttpHandlersSection.cs
- SkewTransform.cs
- StrokeCollectionDefaultValueFactory.cs
- XamlStream.cs
- Membership.cs
- FileUtil.cs
- PenThreadPool.cs
- DataObjectCopyingEventArgs.cs
- BuildTopDownAttribute.cs
- WebControl.cs
- OleDbStruct.cs
- QilNode.cs
- ExpressionEditorAttribute.cs
- TypedDataSetSchemaImporterExtension.cs
- Setter.cs
- TransformCryptoHandle.cs
- PasswordBox.cs
- WebPartVerbsEventArgs.cs
- NominalTypeEliminator.cs
- XmlSerializerVersionAttribute.cs
- UnsafeNativeMethods.cs
- Stacktrace.cs
- RemoteTokenFactory.cs
- Paragraph.cs
- DataGridViewColumnEventArgs.cs
- HttpResponseHeader.cs
- PlatformCulture.cs
- ManagementBaseObject.cs
- CodeIdentifiers.cs
- BitmapEffectCollection.cs
- SafeNativeMethods.cs
- WebReferenceOptions.cs
- SessionStateItemCollection.cs
- SectionXmlInfo.cs
- LinkButton.cs
- IDQuery.cs
- QilTypeChecker.cs
- FrameworkElement.cs
- SqlBuilder.cs
- OlePropertyStructs.cs
- FactoryId.cs
- IRCollection.cs
- SingleAnimationBase.cs
- SimpleMailWebEventProvider.cs
- ScaleTransform3D.cs
- LayoutUtils.cs
- NetTcpSection.cs
- DispatcherSynchronizationContext.cs
- CategoryNameCollection.cs
- PropertyGridView.cs
- FormatterConverter.cs
- OutputCacheModule.cs
- BoolLiteral.cs
- ObjectDisposedException.cs
- GeneralTransform3DTo2D.cs
- XsltConvert.cs
- GlobalEventManager.cs
- SimpleHandlerFactory.cs
- String.cs
- _ConnectOverlappedAsyncResult.cs
- TagElement.cs
- WebPartConnectionsDisconnectVerb.cs
- Binding.cs
- ProcessInfo.cs
- XmlValidatingReaderImpl.cs
- FormsAuthenticationTicket.cs
- GridViewRowEventArgs.cs
- CodeGroup.cs
- PageVisual.cs
- EncoderParameters.cs
- NotifyIcon.cs
- SmtpTransport.cs
- GetPageCompletedEventArgs.cs
- OpCodes.cs
- GeneralTransformCollection.cs
- ChineseLunisolarCalendar.cs
- DesignerVerb.cs
- ScopelessEnumAttribute.cs
- InvalidPropValue.cs
- PageThemeBuildProvider.cs
- XmlSchemaSimpleContent.cs
- Action.cs
- TargetFrameworkAttribute.cs
- LocatorBase.cs
- OleAutBinder.cs
- WindowsComboBox.cs
- TypeBuilderInstantiation.cs
- WmlPanelAdapter.cs
- DesignerActionTextItem.cs
- ChangeConflicts.cs
- GridViewDeletedEventArgs.cs
- ProfileModule.cs
- UnsafeNativeMethodsCLR.cs
- SafeProcessHandle.cs
- SystemGatewayIPAddressInformation.cs