Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / Services / IO / System / IO / RenamedEventArgs.cs / 1 / RenamedEventArgs.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.IO { using System.Diagnostics; using System.Security.Permissions; using System; ////// public class RenamedEventArgs : FileSystemEventArgs { private string oldName; private string oldFullPath; ///Provides data for the ///event. /// public RenamedEventArgs(WatcherChangeTypes changeType, string directory, string name, string oldName) : base(changeType, directory, name) { // Ensure that the directory name ends with a "\" if (!directory.EndsWith("\\", StringComparison.Ordinal)) { directory = directory + "\\"; } this.oldName = oldName; this.oldFullPath = directory + oldName; } ////// Initializes a new instance of the ////// class. /// /// public string OldFullPath { get { new FileIOPermission(FileIOPermissionAccess.Read, Path.GetPathRoot(oldFullPath)).Demand(); return oldFullPath; } } ////// Gets /// the previous fully qualified path of the affected file or directory. /// ////// public string OldName { get { return oldName; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ ///// Gets /// the old name of the affected file or directory. /// ///// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.IO { using System.Diagnostics; using System.Security.Permissions; using System; ////// public class RenamedEventArgs : FileSystemEventArgs { private string oldName; private string oldFullPath; ///Provides data for the ///event. /// public RenamedEventArgs(WatcherChangeTypes changeType, string directory, string name, string oldName) : base(changeType, directory, name) { // Ensure that the directory name ends with a "\" if (!directory.EndsWith("\\", StringComparison.Ordinal)) { directory = directory + "\\"; } this.oldName = oldName; this.oldFullPath = directory + oldName; } ////// Initializes a new instance of the ////// class. /// /// public string OldFullPath { get { new FileIOPermission(FileIOPermissionAccess.Read, Path.GetPathRoot(oldFullPath)).Demand(); return oldFullPath; } } ////// Gets /// the previous fully qualified path of the affected file or directory. /// ////// public string OldName { get { return oldName; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007./// Gets /// the old name of the affected file or directory. /// ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DesignerCatalogPartChrome.cs
- PtsCache.cs
- CompositeDataBoundControl.cs
- MD5.cs
- Triplet.cs
- SmtpTransport.cs
- InstanceNormalEvent.cs
- IndexedGlyphRun.cs
- OutgoingWebRequestContext.cs
- unsafenativemethodstextservices.cs
- SafeMemoryMappedFileHandle.cs
- WebResourceAttribute.cs
- KnownBoxes.cs
- JsonDeserializer.cs
- errorpatternmatcher.cs
- CipherData.cs
- Type.cs
- _DisconnectOverlappedAsyncResult.cs
- DragEvent.cs
- HtmlLiteralTextAdapter.cs
- DataBindingList.cs
- PreProcessor.cs
- ImageSourceConverter.cs
- RefreshPropertiesAttribute.cs
- XDRSchema.cs
- COAUTHINFO.cs
- Assembly.cs
- CodePageEncoding.cs
- Label.cs
- BinaryNegotiation.cs
- DotAtomReader.cs
- QueryResults.cs
- SQLInt32Storage.cs
- CompositionAdorner.cs
- GlyphRunDrawing.cs
- XamlSerializerUtil.cs
- FocusTracker.cs
- UpDownBase.cs
- _SslState.cs
- GridViewSortEventArgs.cs
- CookieParameter.cs
- TrackingServices.cs
- SapiRecognizer.cs
- _SSPIWrapper.cs
- ReflectTypeDescriptionProvider.cs
- SecurityTokenSerializer.cs
- WebPartZone.cs
- filewebresponse.cs
- WebCodeGenerator.cs
- FileLevelControlBuilderAttribute.cs
- RequestCache.cs
- DockPanel.cs
- Block.cs
- RecommendedAsConfigurableAttribute.cs
- ScalarConstant.cs
- GlyphRun.cs
- LostFocusEventManager.cs
- ToolStripPanelRenderEventArgs.cs
- DetailsViewRowCollection.cs
- DesignerActionKeyboardBehavior.cs
- Viewport3DVisual.cs
- KeyManager.cs
- ReadWriteObjectLock.cs
- TreeNodeMouseHoverEvent.cs
- SQLResource.cs
- AffineTransform3D.cs
- SqlDataSourceParameterParser.cs
- RelationshipFixer.cs
- MultiDataTrigger.cs
- unsafenativemethodsother.cs
- Schedule.cs
- CommonDialog.cs
- HttpListenerResponse.cs
- DbExpressionBuilder.cs
- DocumentCollection.cs
- ResourcePart.cs
- WindowsAltTab.cs
- SendMessageChannelCache.cs
- WebPartTracker.cs
- WorkflowTransactionOptions.cs
- FileDetails.cs
- ZipPackage.cs
- SortDescription.cs
- ListViewInsertEventArgs.cs
- ThreadPool.cs
- WebPartActionVerb.cs
- Converter.cs
- TextCharacters.cs
- DbParameterCollection.cs
- RoleGroup.cs
- DataGridCellAutomationPeer.cs
- XmlBaseReader.cs
- FormViewPageEventArgs.cs
- InfoCardSchemas.cs
- DataGridViewDesigner.cs
- HMACSHA1.cs
- RoamingStoreFileUtility.cs
- Classification.cs
- EntityCommandCompilationException.cs
- ProcessModule.cs