Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / CompMod / System / ComponentModel / Design / CheckoutException.cs / 1 / CheckoutException.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.ComponentModel.Design {
using Microsoft.Win32;
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
using System.Security.Permissions;
///
///
/// The exception thrown when an attempt is made to edit a file that is checked into
/// a source control program.
///
///
[HostProtection(SharedState = true)]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Security", "CA2112:SecuredTypesShouldNotExposeFields")] // ReadOnly field - already shipped.
[System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.InheritanceDemand, Name="FullTrust")]
[System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.LinkDemand, Name="FullTrust")]
[Serializable]
public class CheckoutException : ExternalException {
///
///
/// Initializes a that specifies that the checkout
/// was
/// canceled. This field is read-only.
///
///
public readonly static CheckoutException Canceled = new CheckoutException(SR.GetString(SR.CHECKOUTCanceled), NativeMethods.E_ABORT);
///
///
/// Initializes
/// a new instance of the class with no
/// associated message or
/// error code.
///
///
public CheckoutException() {
}
///
///
/// Initializes a new instance of the
/// class with the specified message.
///
///
public CheckoutException(string message)
: base(message) {
}
///
///
/// Initializes a new instance of the
/// class with the specified message and error code.
///
///
public CheckoutException(string message, int errorCode)
: base(message, errorCode) {
}
///
/// Need this constructor since Exception implements ISerializable. We don't have any fields,
/// so just forward this to base.
///
protected CheckoutException(SerializationInfo info, StreamingContext context) : base(info, context) {
}
///
/// Initializes a new instance of the Exception class with a specified error message and a
/// reference to the inner exception that is the cause of this exception.
/// FxCop CA1032: Multiple constructors are required to correctly implement a custom exception.
///
public CheckoutException( string message, Exception innerException ) : base(message, innerException) {
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.ComponentModel.Design {
using Microsoft.Win32;
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
using System.Security.Permissions;
///
///
/// The exception thrown when an attempt is made to edit a file that is checked into
/// a source control program.
///
///
[HostProtection(SharedState = true)]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Security", "CA2112:SecuredTypesShouldNotExposeFields")] // ReadOnly field - already shipped.
[System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.InheritanceDemand, Name="FullTrust")]
[System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.LinkDemand, Name="FullTrust")]
[Serializable]
public class CheckoutException : ExternalException {
///
///
/// Initializes a that specifies that the checkout
/// was
/// canceled. This field is read-only.
///
///
public readonly static CheckoutException Canceled = new CheckoutException(SR.GetString(SR.CHECKOUTCanceled), NativeMethods.E_ABORT);
///
///
/// Initializes
/// a new instance of the class with no
/// associated message or
/// error code.
///
///
public CheckoutException() {
}
///
///
/// Initializes a new instance of the
/// class with the specified message.
///
///
public CheckoutException(string message)
: base(message) {
}
///
///
/// Initializes a new instance of the
/// class with the specified message and error code.
///
///
public CheckoutException(string message, int errorCode)
: base(message, errorCode) {
}
///
/// Need this constructor since Exception implements ISerializable. We don't have any fields,
/// so just forward this to base.
///
protected CheckoutException(SerializationInfo info, StreamingContext context) : base(info, context) {
}
///
/// Initializes a new instance of the Exception class with a specified error message and a
/// reference to the inner exception that is the cause of this exception.
/// FxCop CA1032: Multiple constructors are required to correctly implement a custom exception.
///
public CheckoutException( string message, Exception innerException ) : base(message, innerException) {
}
}
}
// 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
- ProcessInfo.cs
- FileEnumerator.cs
- DataPagerCommandEventArgs.cs
- Point4DValueSerializer.cs
- ImportDesigner.xaml.cs
- WebPartConnectionsCancelEventArgs.cs
- WindowVisualStateTracker.cs
- _TransmitFileOverlappedAsyncResult.cs
- State.cs
- ServiceRouteHandler.cs
- StringToken.cs
- ZipIOExtraField.cs
- ElapsedEventArgs.cs
- UnauthorizedWebPart.cs
- ErrorHandlerModule.cs
- Keyboard.cs
- SqlDuplicator.cs
- ICollection.cs
- mediaeventargs.cs
- PartBasedPackageProperties.cs
- DrawingContext.cs
- ListGeneralPage.cs
- NativeCppClassAttribute.cs
- DataTableReader.cs
- EntityCommandCompilationException.cs
- IntPtr.cs
- EdmProviderManifest.cs
- UserNamePasswordValidator.cs
- XPathChildIterator.cs
- Point3D.cs
- Schema.cs
- TextTreeInsertUndoUnit.cs
- DetailsViewUpdatedEventArgs.cs
- CheckoutException.cs
- WeakReferenceKey.cs
- RecognizerStateChangedEventArgs.cs
- CodeDOMProvider.cs
- SQLInt32Storage.cs
- CacheSection.cs
- FrameworkContextData.cs
- ProfileInfo.cs
- ModelTreeEnumerator.cs
- Route.cs
- ClientCultureInfo.cs
- WebResourceAttribute.cs
- ConnectionsZone.cs
- FamilyTypeface.cs
- BufferedGraphicsManager.cs
- BitmapMetadataBlob.cs
- ListViewEditEventArgs.cs
- XmlObjectSerializer.cs
- UnsafeNativeMethodsPenimc.cs
- AssemblySettingAttributes.cs
- BamlLocalizableResource.cs
- Emitter.cs
- UnsupportedPolicyOptionsException.cs
- ParentUndoUnit.cs
- MergePropertyDescriptor.cs
- DataServiceKeyAttribute.cs
- PlatformCulture.cs
- ObjectViewEntityCollectionData.cs
- PropertyPathConverter.cs
- StylusButton.cs
- OperationContractAttribute.cs
- IItemContainerGenerator.cs
- ItemMap.cs
- PostBackTrigger.cs
- ArrayHelper.cs
- BinaryWriter.cs
- EditorZoneDesigner.cs
- AsyncOperation.cs
- WindowsListBox.cs
- InstalledFontCollection.cs
- wgx_sdk_version.cs
- ContextStack.cs
- FtpCachePolicyElement.cs
- assemblycache.cs
- HtmlWindowCollection.cs
- SemanticValue.cs
- RegexMatchCollection.cs
- CodeMemberEvent.cs
- _AuthenticationState.cs
- ListViewItemEventArgs.cs
- ResXResourceSet.cs
- HwndTarget.cs
- RepeatBehaviorConverter.cs
- PagesSection.cs
- ClientConfigPaths.cs
- Activator.cs
- StringBuilder.cs
- QilTargetType.cs
- StateBag.cs
- HostingEnvironmentException.cs
- GenericWebPart.cs
- PrintDocument.cs
- PartBasedPackageProperties.cs
- ConnectionPoolRegistry.cs
- DataGridViewRowPostPaintEventArgs.cs
- AddingNewEventArgs.cs
- ConfigurationManagerInternal.cs