class_docstr: ``TagReq`` that combines several children.
class_docstr_tok: ["``","TagReq","``","that","combines","several","children","."]
code: def __init__(
      self,
      name: str,
      reducer: Callable[[Iterable[bool]], bool],
      children: Collection[TagReq[T]],
  ) -> None:
      self.name = name
      self.reducer = reducer
      self.children: List[TagReq[T]] = []
      for child in children:
          if (
              isinstance(child, ReducingTagReq)
              and self.reducer == child.reducer
          ):
              self.children.extend(child.children)
          else:
              self.children.append(child)
  
imports: from abc import ABC, abstractmethod
  from typing import Any, Callable, Collection, Generic, Iterable, List, TypeVar
label_desc: Use image node_id 1 to create a new ReducingTagReq object from inherited base classes: TagReq, Generic with example: obj = ReducingTagReq(name, reducer, children)