code: public function registerMediaType($mediaType)
      {
          if ($this->check($mediaType)) {
              $this->mediaTypes[(new \ReflectionClass($mediaType))->getConstant('NAME')] = $mediaType;
  
              return $this;
          } else {
              throw new \Exception('registered MediaType must implement \MandarinMedien\MMMediaBundle\Model\MediaTypeInterface');
          }
      }
docs: register new mediaType.
  
  @param string $mediaType class name of mediatype
  
  @return $this
  
  @throws \Exception