code: public function setSegmentSize($size) {
          if (null !== $this->memory) {
              throw new Exception\RuntimeException(
              'You can not change the segment size because memory is already allocated.'
              . ' Use realloc() function to create new memory segment.'
              );
          }
          $this->segmentSize = (integer) $size;
          return $this;
      }
docs: Set segment size
  @param int