public function getContentTypeName($contentType)
    {
        if (!$contentType instanceof ContentType) {
            try {
                $contentType = $this->contentTypeService->loadContentType($contentType);
            } catch (NotFoundException $e) {
                return '';
            }
        }

        return $contentType->getName();
    }
public function getContentTypeName($contentType)
    {
        if (!$contentType instanceof ContentType) {
            try {
                $contentType = $this->contentTypeService->loadContentType($contentType);
            } catch (NotFoundException $e) {
                return '';
            }
        }

        return $contentType->getName();
    }
public function getContentTypeName ( $ contentType ) { if ( ! $ contentType instanceof ContentType ) { try { $ contentType = $ this -> contentTypeService -> loadContentType ( $ contentType ) ; } catch ( NotFoundException $ e ) { return '' ; } } return $ contentType -> getName ( ) ; }
Returns content type name for provided content type ID or content type object.

@param mixed|\eZ\Publish\API\Repository\Values\ContentType\ContentType $contentType

@return string
Returns content type name for provided content type ID or content type object .