private function getMaxFileSize(): int
    {
        $validatorConfiguration = $this->assetMapper
            ->getAssetFieldDefinition()
            ->getValidatorConfiguration();

        $maxFileSize = $validatorConfiguration['FileSizeValidator']['maxFileSize'];
        if ($maxFileSize > 0) {
            return min($maxFileSize * 1024 * 1024, $this->maxUploadSize->get());
        }

        return $this->maxUploadSize->get();
    }
private function getMaxFileSize(): int
    {
        $validatorConfiguration = $this->assetMapper
            ->getAssetFieldDefinition()
            ->getValidatorConfiguration();

        $maxFileSize = $validatorConfiguration['FileSizeValidator']['maxFileSize'];
        if ($maxFileSize > 0) {
            return min($maxFileSize * 1024 * 1024, $this->maxUploadSize->get());
        }

        return $this->maxUploadSize->get();
    }
private function getMaxFileSize ( ) : int { $ validatorConfiguration = $ this -> assetMapper -> getAssetFieldDefinition ( ) -> getValidatorConfiguration ( ) ; $ maxFileSize = $ validatorConfiguration [ 'FileSizeValidator' ] [ 'maxFileSize' ] ; if ( $ maxFileSize > 0 ) { return min ( $ maxFileSize * 1024 * 1024 , $ this -> maxUploadSize -> get ( ) ) ; } return $ this -> maxUploadSize -> get ( ) ; }
Returns max size of uploaded file in bytes.

@return int
Returns max size of uploaded file in bytes .