Hoa central
Transport.php
Go to the documentation of this file.
1 <?php
2 
37 namespace Hoa\Socket;
38 
47 class Transport
48 {
54  public static function get()
55  {
56  static $_ = null;
57 
58  if (null === $_) {
59  $_ = stream_get_transports();
60  }
61 
62  return $_;
63  }
64 
71  public static function exists($transport)
72  {
73  return in_array(strtolower($transport), self::get());
74  }
75 }
static exists($transport)
Definition: Transport.php:71