code: public function offsetSet($slot, $connection)
      {
          if (!static::isValid($slot)) {
              throw new \OutOfBoundsException("Invalid slot $slot for `$connection`");
          }
  
          $this->slots[(int) $slot] = (string) $connection;
      }
docs: Assigns the specified slot to a node.
  
  @param int                            $slot       Slot index.
  @param NodeConnectionInterface|string $connection ID or connection instance.
  
  @return string