original_string: private function findAdderAndRemover(\ReflectionClass $reflClass, array $singulars)
      {
          foreach ($singulars as $singular) {
              $addMethod = 'add'.$singular;
              $removeMethod = 'remove'.$singular;
  
              $addMethodFound = $this->isMethodAccessible($reflClass, $addMethod, 1);
              $removeMethodFound = $this->isMethodAccessible($reflClass, $removeMethod, 1);
  
              if ($addMethodFound && $removeMethodFound) {
                  return array($addMethod, $removeMethod);
              }
          }
  
          return null;
      }
code: private function findAdderAndRemover(\ReflectionClass $reflClass, array $singulars)
      {
          foreach ($singulars as $singular) {
              $addMethod = 'add'.$singular;
              $removeMethod = 'remove'.$singular;
  
              $addMethodFound = $this->isMethodAccessible($reflClass, $addMethod, 1);
              $removeMethodFound = $this->isMethodAccessible($reflClass, $removeMethod, 1);
  
              if ($addMethodFound && $removeMethodFound) {
                  return array($addMethod, $removeMethod);
              }
          }
  
          return null;
      }
code_tokens: private function findAdderAndRemover ( \ ReflectionClass $ reflClass , array $ singulars ) { foreach ( $ singulars as $ singular ) { $ addMethod = 'add' . $ singular ; $ removeMethod = 'remove' . $ singular ; $ addMethodFound = $ this -> isMethodAccessible ( $ reflClass , $ addMethod , 1 ) ; $ removeMethodFound = $ this -> isMethodAccessible ( $ reflClass , $ removeMethod , 1 ) ; if ( $ addMethodFound && $ removeMethodFound ) { return array ( $ addMethod , $ removeMethod ) ; } } return null ; }
docstring: Searches for add and remove methods.
  
  Part of the Symfony package. Symfony license applies.
  
  @param \ReflectionClass $reflClass The reflection class for the given object
  @param array            $singulars The singular form of the property name or null
  
  @return array|null An array containing the adder and remover when found, null otherwise
docstring_tokens: Searches for add and remove methods .