original_string: public function getFileUrl($entity, $field, $fileName = null)
      {
          if (func_num_args() < 3) {
              if ($entity) {
                  $fileName = PropertyHelper::getValue($entity, $field);
              }
          }
  
          if ($fileName instanceof File) {
              $fileName = $fileName->getBasename();
          }
  
          if ($fileName) {
              return ltrim($this->httpRoot . '/' . $this->getRelativePath($entity, $field) . '/' . $fileName, '/');
          }
  
          return null;
      }
code: public function getFileUrl($entity, $field, $fileName = null)
      {
          if (func_num_args() < 3) {
              if ($entity) {
                  $fileName = PropertyHelper::getValue($entity, $field);
              }
          }
  
          if ($fileName instanceof File) {
              $fileName = $fileName->getBasename();
          }
  
          if ($fileName) {
              return ltrim($this->httpRoot . '/' . $this->getRelativePath($entity, $field) . '/' . $fileName, '/');
          }
  
          return null;
      }
code_tokens: public function getFileUrl ( $ entity , $ field , $ fileName = null ) { if ( func_num_args ( ) < 3 ) { if ( $ entity ) { $ fileName = PropertyHelper :: getValue ( $ entity , $ field ) ; } } if ( $ fileName instanceof File ) { $ fileName = $ fileName -> getBasename ( ) ; } if ( $ fileName ) { return ltrim ( $ this -> httpRoot . '/' . $ this -> getRelativePath ( $ entity , $ field ) . '/' . $ fileName , '/' ) ; } return null ; }
docstring: Return the url to the file.
  
  @param mixed $entity
  @param string $field
  @param mixed $fileName
  @return null|string
docstring_tokens: Return the url to the file .