Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / clr / src / BCL / System / Security / AccessControl / PrivilegeNotHeldException.cs / 1305376 / PrivilegeNotHeldException.cs
using Microsoft.Win32; using System; using System.Runtime.Serialization; using System.Text; using System.Globalization; using System.Security.Permissions; using System.Diagnostics.Contracts; namespace System.Security.AccessControl { [Serializable] public sealed class PrivilegeNotHeldException : UnauthorizedAccessException, ISerializable { private readonly string _privilegeName = null; public PrivilegeNotHeldException() : base( Environment.GetResourceString( "PrivilegeNotHeld_Default" )) { } public PrivilegeNotHeldException( string privilege ) : base( string.Format( CultureInfo.CurrentCulture, Environment.GetResourceString( "PrivilegeNotHeld_Named" ), privilege )) { _privilegeName = privilege; } public PrivilegeNotHeldException( string privilege, Exception inner ) : base( string.Format( CultureInfo.CurrentCulture, Environment.GetResourceString( "PrivilegeNotHeld_Named" ), privilege ), inner ) { _privilegeName = privilege; } internal PrivilegeNotHeldException( SerializationInfo info, StreamingContext context ) : base( info, context ) { _privilegeName = info.GetString("PrivilegeName"); } public string PrivilegeName { get { return _privilegeName; } } [System.Security.SecurityCritical] // auto-generated_required public override void GetObjectData( SerializationInfo info, StreamingContext context ) { if ( info == null ) { throw new ArgumentNullException( "info" ); } Contract.EndContractBlock(); base.GetObjectData(info, context); info.AddValue("PrivilegeName", _privilegeName, typeof( string )); } } } // 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
- ObjectResult.cs
- UnhandledExceptionEventArgs.cs
- WindowsToolbar.cs
- SoapIgnoreAttribute.cs
- ArrayList.cs
- EncoderNLS.cs
- ExternalFile.cs
- ReadOnlyTernaryTree.cs
- RegisteredDisposeScript.cs
- DataGridViewColumnConverter.cs
- SqlTypesSchemaImporter.cs
- GeometryModel3D.cs
- EditorBrowsableAttribute.cs
- SocketElement.cs
- RelatedCurrencyManager.cs
- RegisteredArrayDeclaration.cs
- ImageBrush.cs
- ExpressionBuilder.cs
- ErasingStroke.cs
- BitmapEffectrendercontext.cs
- HwndHostAutomationPeer.cs
- printdlgexmarshaler.cs
- AppearanceEditorPart.cs
- cookiecollection.cs
- ConfigsHelper.cs
- WeakRefEnumerator.cs
- messageonlyhwndwrapper.cs
- TrackingStringDictionary.cs
- DataControlFieldCell.cs
- WebServiceMethodData.cs
- WebConfigurationManager.cs
- InvalidTimeZoneException.cs
- DataKey.cs
- StreamGeometry.cs
- XmlTypeAttribute.cs
- ResourcesChangeInfo.cs
- UnmanagedMemoryStream.cs
- BaseAutoFormat.cs
- StaticResourceExtension.cs
- RootAction.cs
- XpsResource.cs
- SoapProtocolImporter.cs
- NumericUpDown.cs
- DocumentGridContextMenu.cs
- RemoteWebConfigurationHostStream.cs
- AssociatedControlConverter.cs
- CmsInterop.cs
- _ScatterGatherBuffers.cs
- WebRequestModulesSection.cs
- ListViewHitTestInfo.cs
- ReflectionUtil.cs
- Clause.cs
- TrackBarDesigner.cs
- ToolStripOverflowButton.cs
- CompilationRelaxations.cs
- ContainerAction.cs
- MetaColumn.cs
- OdbcTransaction.cs
- CharConverter.cs
- NotifyCollectionChangedEventArgs.cs
- SafeArrayRankMismatchException.cs
- Int32CollectionValueSerializer.cs
- ListControlBuilder.cs
- GACIdentityPermission.cs
- ConnectionStringsExpressionBuilder.cs
- PointAnimationUsingPath.cs
- ContentOperations.cs
- PathFigureCollection.cs
- QilParameter.cs
- Condition.cs
- HtmlMeta.cs
- DataGridViewCellEventArgs.cs
- FormsIdentity.cs
- RoleProviderPrincipal.cs
- AstTree.cs
- ImageInfo.cs
- QuaternionRotation3D.cs
- ConstraintEnumerator.cs
- DataGridViewCellMouseEventArgs.cs
- NestedContainer.cs
- GeneralTransform.cs
- WorkflowInstanceContextProvider.cs
- ipaddressinformationcollection.cs
- ImageAutomationPeer.cs
- UnsupportedPolicyOptionsException.cs
- ErasingStroke.cs
- NameNode.cs
- RepeatBehavior.cs
- SecurityContext.cs
- PipelineModuleStepContainer.cs
- LoaderAllocator.cs
- InternalDispatchObject.cs
- GrowingArray.cs
- SpecialFolderEnumConverter.cs
- UnsafeNativeMethods.cs
- EmptyStringExpandableObjectConverter.cs
- MultiSelector.cs
- Single.cs
- XmlDataContract.cs
- ObjectPropertyMapping.cs