original_string: protected function getWsdlElementAttributes($comment)
      {
          $nillable = $minOccurs = $maxOccurs = null;
          if (preg_match('/{(.+)}/', $comment, $attr)) {
              if (preg_match_all('/((\w+)\s*=\s*(\w+))/mi', $attr[1], $attr)) {
                  foreach ($attr[2] as $id => $prop) {
                      $prop = strtolower($prop);
                      $val = strtolower($attr[3][$id]);
                      if ($prop == 'nillable') {
                          if ($val == 'false' || $val == 'true') {
                              $nillable = $val;
                          } else {
                              $nillable = $val ? 'true' : 'false';
                          }
                      } elseif ($prop == 'minoccurs') {
                          $minOccurs = intval($val);
                      } elseif ($prop == 'maxoccurs') {
                          $maxOccurs = ($val == 'unbounded') ? 'unbounded' : intval($val);
                      }
                  }
              }
          }
          return [
              'nillable' => $nillable,
              'minOccurs' => $minOccurs,
              'maxOccurs' => $maxOccurs
          ];
      }
code: protected function getWsdlElementAttributes($comment)
      {
          $nillable = $minOccurs = $maxOccurs = null;
          if (preg_match('/{(.+)}/', $comment, $attr)) {
              if (preg_match_all('/((\w+)\s*=\s*(\w+))/mi', $attr[1], $attr)) {
                  foreach ($attr[2] as $id => $prop) {
                      $prop = strtolower($prop);
                      $val = strtolower($attr[3][$id]);
                      if ($prop == 'nillable') {
                          if ($val == 'false' || $val == 'true') {
                              $nillable = $val;
                          } else {
                              $nillable = $val ? 'true' : 'false';
                          }
                      } elseif ($prop == 'minoccurs') {
                          $minOccurs = intval($val);
                      } elseif ($prop == 'maxoccurs') {
                          $maxOccurs = ($val == 'unbounded') ? 'unbounded' : intval($val);
                      }
                  }
              }
          }
          return [
              'nillable' => $nillable,
              'minOccurs' => $minOccurs,
              'maxOccurs' => $maxOccurs
          ];
      }
code_tokens: protected function getWsdlElementAttributes ( $ comment ) { $ nillable = $ minOccurs = $ maxOccurs = null ; if ( preg_match ( '/{(.+)}/' , $ comment , $ attr ) ) { if ( preg_match_all ( '/((\w+)\s*=\s*(\w+))/mi' , $ attr [ 1 ] , $ attr ) ) { foreach ( $ attr [ 2 ] as $ id => $ prop ) { $ prop = strtolower ( $ prop ) ; $ val = strtolower ( $ attr [ 3 ] [ $ id ] ) ; if ( $ prop == 'nillable' ) { if ( $ val == 'false' || $ val == 'true' ) { $ nillable = $ val ; } else { $ nillable = $ val ? 'true' : 'false' ; } } elseif ( $ prop == 'minoccurs' ) { $ minOccurs = intval ( $ val ) ; } elseif ( $ prop == 'maxoccurs' ) { $ maxOccurs = ( $ val == 'unbounded' ) ? 'unbounded' : intval ( $ val ) ; } } } } return [ 'nillable' => $ nillable , 'minOccurs' => $ minOccurs , 'maxOccurs' => $ maxOccurs ] ; }
docstring: Parse attributes nillable, minOccurs, maxOccurs
  @param string $comment Extracted PHPDoc comment
  @return array
docstring_tokens: Parse attributes nillable minOccurs maxOccurs