original_string: public function arrayToFunctionElement(array $definition)
      {
          $function = new Functions;
          if (isset($definition['docblock'])) {
              $docblock = $this->arrayToDocblockElement($definition['docblock']);
              $function->setDocbloc($docblock);
          }
          if (isset($definition['public'])) {
              $function->isPublic(true);
          }
          if (isset($definition['name'])) {
              $function->setName($definition['name']);
          }
          if (isset($definition['params'])) {
              foreach ($definition['params'] as $name => $type) {
                  $function->addParam($name, $type);
              }
          }
          if (isset($definition['content'])) {
              $function->setContent($definition['content']);
          }
          return $function;
      }
code: public function arrayToFunctionElement(array $definition)
      {
          $function = new Functions;
          if (isset($definition['docblock'])) {
              $docblock = $this->arrayToDocblockElement($definition['docblock']);
              $function->setDocbloc($docblock);
          }
          if (isset($definition['public'])) {
              $function->isPublic(true);
          }
          if (isset($definition['name'])) {
              $function->setName($definition['name']);
          }
          if (isset($definition['params'])) {
              foreach ($definition['params'] as $name => $type) {
                  $function->addParam($name, $type);
              }
          }
          if (isset($definition['content'])) {
              $function->setContent($definition['content']);
          }
          return $function;
      }
code_tokens: public function arrayToFunctionElement ( array $ definition ) { $ function = new Functions ; if ( isset ( $ definition [ 'docblock' ] ) ) { $ docblock = $ this -> arrayToDocblockElement ( $ definition [ 'docblock' ] ) ; $ function -> setDocbloc ( $ docblock ) ; } if ( isset ( $ definition [ 'public' ] ) ) { $ function -> isPublic ( true ) ; } if ( isset ( $ definition [ 'name' ] ) ) { $ function -> setName ( $ definition [ 'name' ] ) ; } if ( isset ( $ definition [ 'params' ] ) ) { foreach ( $ definition [ 'params' ] as $ name => $ type ) { $ function -> addParam ( $ name , $ type ) ; } } if ( isset ( $ definition [ 'content' ] ) ) { $ function -> setContent ( $ definition [ 'content' ] ) ; } return $ function ; }
docstring: Returns well formated function declaration
  
  @param array $definition Functions definition
  
  @return Deflection\Element\Functions
docstring_tokens: Returns well formated function declaration