FileEnums.cs 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. #if NETFX_CORE
  2. using System;
  3. using System.Collections.Generic;
  4. using System.Linq;
  5. using System.Text;
  6. namespace BestHTTP.PlatformSupport.IO
  7. {
  8. [Flags]
  9. public enum FileAccess
  10. {
  11. Read = 1,
  12. Write = 2,
  13. ReadWrite = Write | Read,
  14. }
  15. [Flags]
  16. public enum FileAttributes
  17. {
  18. Archive = 32,
  19. Compressed = 2048,
  20. Device = 64,
  21. Directory = 16,
  22. Encrypted = 16384,
  23. Hidden = 2,
  24. Normal = 128,
  25. NotContentIndexed = 8192,
  26. Offline = 4096,
  27. ReadOnly = 1,
  28. ReparsePoint = 1024,
  29. SparseFile = 512,
  30. System = 4,
  31. Temporary = 256,
  32. }
  33. public enum FileMode
  34. {
  35. CreateNew = 1,
  36. Create = 2,
  37. Open = 3,
  38. OpenOrCreate = 4,
  39. Truncate = 5,
  40. Append = 6,
  41. }
  42. [Flags]
  43. public enum FileOptions
  44. {
  45. None = 0,
  46. Encrypted = 16384,
  47. DeleteOnClose = 67108864,
  48. SequentialScan = 134217728,
  49. RandomAccess = 268435456,
  50. Asynchronous = 1073741824,
  51. WriteThrough = -2147483648,
  52. }
  53. [Flags]
  54. public enum FileShare
  55. {
  56. None = 0,
  57. Read = 1,
  58. Write = 2,
  59. ReadWrite = Write | Read,
  60. Delete = 4,
  61. Inheritable = 16,
  62. }
  63. }
  64. #endif