RemoteFileInfo.cs 847 B

1234567891011121314151617181920212223242526272829
  1. using System;
  2. using System.Globalization;
  3. using System.Runtime.InteropServices;
  4. namespace WinSCP
  5. {
  6. [Guid("17FF9C92-B8B6-4506-A7BA-8482D9B0AB07")]
  7. [ClassInterface(Constants.ClassInterface)]
  8. [ComVisible(true)]
  9. public sealed class RemoteFileInfo
  10. {
  11. public string Name { get; internal set; }
  12. public char FileType { get; internal set; }
  13. public long Length { get; internal set; }
  14. public DateTime LastWriteTime { get; internal set; }
  15. public FilePermissions FilePermissions { get; internal set; }
  16. public bool IsDirectory { get { return (Char.ToUpper(FileType, CultureInfo.InvariantCulture) == 'D'); } }
  17. internal RemoteFileInfo()
  18. {
  19. }
  20. public override string ToString()
  21. {
  22. return Name;
  23. }
  24. }
  25. }