Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / clr / src / BCL / Microsoft / Win32 / SafeHandles / SafeFileMappingHandle.cs / 1305376 / SafeFileMappingHandle.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Class: SafeFileMappingHandle ** ** ** A wrapper for file handles ** ** ===========================================================*/ using System; using System.Security; using System.Security.Permissions; using System.Runtime.InteropServices; using System.Runtime.CompilerServices; using System.Runtime.ConstrainedExecution; using System.Runtime.Versioning; namespace Microsoft.Win32.SafeHandles { [System.Security.SecurityCritical] // auto-generated internal sealed class SafeFileMappingHandle : SafeHandleZeroOrMinusOneIsInvalid { [System.Security.SecurityCritical] // auto-generated_required internal SafeFileMappingHandle() : base(true) {} // 0 is an Invalid Handle [System.Security.SecurityCritical] // auto-generated_required internal SafeFileMappingHandle(IntPtr handle, bool ownsHandle) : base (ownsHandle) { SetHandle(handle); } [System.Security.SecurityCritical] [ResourceExposure(ResourceScope.Machine)] [ResourceConsumption(ResourceScope.Machine)] override protected bool ReleaseHandle() { return Win32Native.CloseHandle(handle); } } } // 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
- VerificationException.cs
- AssociationType.cs
- TextDecorationCollection.cs
- FormattedTextSymbols.cs
- SqlCharStream.cs
- CleanUpVirtualizedItemEventArgs.cs
- DbDataAdapter.cs
- GroupBox.cs
- FixedSOMPageConstructor.cs
- ColumnHeader.cs
- XPathAncestorIterator.cs
- UIPermission.cs
- TemplateGroupCollection.cs
- OperationResponse.cs
- DesignerCategoryAttribute.cs
- CommonDialog.cs
- ProgramPublisher.cs
- SpnegoTokenAuthenticator.cs
- ExecutionEngineException.cs
- XmlAtomicValue.cs
- SqlProviderManifest.cs
- FrameworkElementFactoryMarkupObject.cs
- ConfigurationLockCollection.cs
- HttpApplication.cs
- ResXBuildProvider.cs
- RsaKeyIdentifierClause.cs
- Style.cs
- AdornerLayer.cs
- MessageQueueAccessControlEntry.cs
- SplitterCancelEvent.cs
- TempFiles.cs
- ChtmlTextBoxAdapter.cs
- Context.cs
- Timeline.cs
- StrongNameHelpers.cs
- FilterableData.cs
- ListViewCommandEventArgs.cs
- WindowsStatic.cs
- PopupEventArgs.cs
- _LoggingObject.cs
- AppSettingsReader.cs
- StringPropertyBuilder.cs
- ImageKeyConverter.cs
- PropertyItemInternal.cs
- AutomationPatternInfo.cs
- PlaceHolder.cs
- RuntimeWrappedException.cs
- IERequestCache.cs
- ControlUtil.cs
- HttpServerVarsCollection.cs
- XmlNamespaceMapping.cs
- TypeListConverter.cs
- AnimationStorage.cs
- ScriptHandlerFactory.cs
- QEncodedStream.cs
- XamlSerializerUtil.cs
- OrderByExpression.cs
- CompilerGeneratedAttribute.cs
- AnimationClock.cs
- GridView.cs
- EntityReference.cs
- DesignOnlyAttribute.cs
- ConfigurationManagerHelper.cs
- FileInfo.cs
- WindowsImpersonationContext.cs
- RemotingSurrogateSelector.cs
- Helper.cs
- SerializationAttributes.cs
- HMAC.cs
- PtsContext.cs
- XmlParserContext.cs
- GridLengthConverter.cs
- AutoCompleteStringCollection.cs
- DataGridViewRow.cs
- EntityCollection.cs
- SHA512CryptoServiceProvider.cs
- ReflectionPermission.cs
- JumpItem.cs
- AsyncContentLoadedEventArgs.cs
- ImageDrawing.cs
- SerializerDescriptor.cs
- ItemPager.cs
- GZipStream.cs
- ActiveXSite.cs
- DataGridViewCellEventArgs.cs
- GPStream.cs
- TextElementEnumerator.cs
- LoginNameDesigner.cs
- RuntimeHandles.cs
- EntityCommand.cs
- EncryptedPackage.cs
- FontNamesConverter.cs
- DecimalAnimation.cs
- DrawingVisual.cs
- DataGridItem.cs
- ModifiableIteratorCollection.cs
- DrawingGroup.cs
- CodeDomSerializer.cs
- TiffBitmapEncoder.cs
- ControlBuilder.cs