Blame view

vendor/nelexa/zip/src/Constants/ZipPlatform.php 1.14 KB
2db47680   hexiaodong   chore: 初始提交 php 遗...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
  <?php
  
  namespace PhpZip\Constants;
  
  /**
   * Class ZipPlatform.
   */
  final class ZipPlatform
  {
      /** @var int MS-DOS OS */
      const OS_DOS = 0;
  
      /** @var int Unix OS */
      const OS_UNIX = 3;
  
      /** MacOS platform */
      const OS_MAC_OSX = 19;
  
      /** @var array Zip Platforms */
      private static $platforms = [
          self::OS_DOS => 'MS-DOS',
          1 => 'Amiga',
          2 => 'OpenVMS',
          self::OS_UNIX => 'Unix',
          4 => 'VM/CMS',
          5 => 'Atari ST',
          6 => 'HPFS (OS/2, NT 3.x)',
          7 => 'Macintosh',
          8 => 'Z-System',
          9 => 'CP/M',
          10 => 'Windows NTFS or TOPS-20',
          11 => 'MVS or NTFS',
          12 => 'VSE or SMS/QDOS',
          13 => 'Acorn RISC OS',
          14 => 'VFAT',
          15 => 'alternate MVS',
          16 => 'BeOS',
          17 => 'Tandem',
          18 => 'OS/400',
          self::OS_MAC_OSX => 'OS/X (Darwin)',
          30 => 'AtheOS/Syllable',
      ];
  
      /**
       * @param int $platform
       *
       * @return string
       */
      public static function getPlatformName($platform)
      {
          return isset(self::$platforms[$platform]) ? self::$platforms[$platform] : 'Unknown';
      }
  }