original_string: protected function generateCheckboxByGroup($id, $label, $name, $checked, array $options)
      {
          $identifier = \sprintf('%s_%s', $name, $id);
          $key = \sprintf('%s[]', $name);
          $active = \in_array($id, (array) $checked);
  
          $options['id'] = $identifier;
  
          $control = $this->checkbox($key, $id, $active, $options);
  
          $label = $this->label($identifier, $label);
  
          return \implode(' ', [$control, $label]);
      }
code: protected function generateCheckboxByGroup($id, $label, $name, $checked, array $options)
      {
          $identifier = \sprintf('%s_%s', $name, $id);
          $key = \sprintf('%s[]', $name);
          $active = \in_array($id, (array) $checked);
  
          $options['id'] = $identifier;
  
          $control = $this->checkbox($key, $id, $active, $options);
  
          $label = $this->label($identifier, $label);
  
          return \implode(' ', [$control, $label]);
      }
code_tokens: protected function generateCheckboxByGroup ( $ id , $ label , $ name , $ checked , array $ options ) { $ identifier = \ sprintf ( '%s_%s' , $ name , $ id ) ; $ key = \ sprintf ( '%s[]' , $ name ) ; $ active = \ in_array ( $ id , ( array ) $ checked ) ; $ options [ 'id' ] = $ identifier ; $ control = $ this -> checkbox ( $ key , $ id , $ active , $ options ) ; $ label = $ this -> label ( $ identifier , $ label ) ; return \ implode ( ' ' , [ $ control , $ label ] ) ; }
docstring: Generate checkbox by group.
  
  @param  string  $id
  @param  string  $label
  @param  string  $name
  @param  bool|array  $checked
  @param  array  $options
  
  @return array
docstring_tokens: Generate checkbox by group .