code: private function indexWidgetById($widget)
      {
          $id = $widget->getAttribute('id');
          if (! $id) {
              return;
          }
          if (! isset($this->widgets_by_id[$id])) {
              $this->widgets_by_id[$id] = array();
          }
          $this->widgets_by_id[$id][] = $widget;
      }
docs: Fills the widget cache to speed up searching.
  
  @param SimpleTag $widget    Parsed widget to cache.