src/Stream/Stream.php
private final function setReadableWritable(string $mode)
   {
      if (self::MODE_R === $mode) {
          $this->meta["readable"] = true;
          $this->meta["writable"] = false;
      } else if (self::MODE_W === $mode
              || self::MODE_A === $mode
              || self::MODE_C === $mode
              || self::MODE_X === $mode) {
          $this->meta["readable"] = false;
          $this->meta["writable"] = true;
      } else if (self::MODE_R_MORE === $mode
              || self::MODE_W_MORE === $mode    
              || self::MODE_A_MORE === $mode
              || self::MODE_C_MORE === $mode
              || self::MODE_X_MORE === $mode) {
          $this->meta["readable"] = true;
          $this->meta["writable"] = true;
       }
   }
private final function setReadableWritable(string $mode)
   {
      if (self::MODE_R === $mode) {
          $this->meta["readable"] = true;
          $this->meta["writable"] = false;
      } else if (self::MODE_W === $mode
              || self::MODE_A === $mode
              || self::MODE_C === $mode
              || self::MODE_X === $mode) {
          $this->meta["readable"] = false;
          $this->meta["writable"] = true;
      } else if (self::MODE_R_MORE === $mode
              || self::MODE_W_MORE === $mode    
              || self::MODE_A_MORE === $mode
              || self::MODE_C_MORE === $mode
              || self::MODE_X_MORE === $mode) {
          $this->meta["readable"] = true;
          $this->meta["writable"] = true;
       }
   }
private final function setReadableWritable ( string $ mode ) { if ( self :: MODE_R === $ mode ) { $ this -> meta [ "readable" ] = true ; $ this -> meta [ "writable" ] = false ; } else if ( self :: MODE_W === $ mode || self :: MODE_A === $ mode || self :: MODE_C === $ mode || self :: MODE_X === $ mode ) { $ this -> meta [ "readable" ] = false ; $ this -> meta [ "writable" ] = true ; } else if ( self :: MODE_R_MORE === $ mode || self :: MODE_W_MORE === $ mode || self :: MODE_A_MORE === $ mode || self :: MODE_C_MORE === $ mode || self :: MODE_X_MORE === $ mode ) { $ this -> meta [ "readable" ] = true ; $ this -> meta [ "writable" ] = true ; } }
Set stream readable and writable status

@param string $mode ressource mode
@return null
Set stream readable and writable status