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
- HttpDebugHandler.cs
- HandlerBase.cs
- GAC.cs
- XmlAnyElementAttributes.cs
- DragEvent.cs
- NativeMethods.cs
- CompressedStack.cs
- SplashScreen.cs
- ProjectionPlanCompiler.cs
- BinaryWriter.cs
- Hyperlink.cs
- Array.cs
- ManifestBasedResourceGroveler.cs
- StrokeCollectionDefaultValueFactory.cs
- ContentElement.cs
- DesignOnlyAttribute.cs
- WebProxyScriptElement.cs
- DbConvert.cs
- wmiprovider.cs
- Base64Stream.cs
- XmlObjectSerializerReadContextComplexJson.cs
- pingexception.cs
- WindowShowOrOpenTracker.cs
- EntryPointNotFoundException.cs
- HebrewNumber.cs
- SharedStatics.cs
- ADMembershipProvider.cs
- DataGridBoundColumn.cs
- URLAttribute.cs
- SchemaImporterExtensionElement.cs
- PrinterSettings.cs
- ExpressionPrinter.cs
- TargetPerspective.cs
- DbException.cs
- UnescapedXmlDiagnosticData.cs
- CodeMemberEvent.cs
- XmlChildEnumerator.cs
- RadioButtonAutomationPeer.cs
- OperationCanceledException.cs
- Double.cs
- ComboBox.cs
- OrderedParallelQuery.cs
- BinaryObjectInfo.cs
- GeometryDrawing.cs
- DataConnectionHelper.cs
- MachineKeyConverter.cs
- IntPtr.cs
- SecurityAlgorithmSuiteConverter.cs
- ConfigXmlWhitespace.cs
- ConversionHelper.cs
- ConstraintConverter.cs
- followingsibling.cs
- RoleManagerModule.cs
- WebResourceAttribute.cs
- ColorConvertedBitmap.cs
- XXXOnTypeBuilderInstantiation.cs
- ClientApiGenerator.cs
- EditableTreeList.cs
- EditorZoneDesigner.cs
- AsyncDataRequest.cs
- DataGridViewCellStyle.cs
- CodeAttributeArgument.cs
- LinkDescriptor.cs
- RadioButtonBaseAdapter.cs
- TemplateControl.cs
- XPathNodePointer.cs
- CommittableTransaction.cs
- UnknownBitmapDecoder.cs
- ControlParameter.cs
- OutputCacheSection.cs
- Tablet.cs
- XmlFormatWriterGenerator.cs
- ListViewEditEventArgs.cs
- DelayedRegex.cs
- DesignerToolboxInfo.cs
- SystemGatewayIPAddressInformation.cs
- SafeEventLogWriteHandle.cs
- BitmapEffectInput.cs
- DateTimeSerializationSection.cs
- CodeDOMProvider.cs
- DataRowChangeEvent.cs
- DataGridViewIntLinkedList.cs
- Model3DGroup.cs
- SecurityPolicySection.cs
- TextureBrush.cs
- ToRequest.cs
- ServerIdentity.cs
- PathGeometry.cs
- SqlTypeConverter.cs
- ParamArrayAttribute.cs
- ToolbarAUtomationPeer.cs
- NameTable.cs
- SrgsDocumentParser.cs
- TypeLoader.cs
- MemberNameValidator.cs
- XmlNode.cs
- XmlNamespaceDeclarationsAttribute.cs
- columnmapkeybuilder.cs
- ValidatedMobileControlConverter.cs
- RSAOAEPKeyExchangeDeformatter.cs