class_docstr: Base class of function operation that will execute StatelessFunction or StatefulFunction for
  each input element.
class_docstr_tok: ["Base","class","of","function","operation","that","will","execute","StatelessFunction","or","StatefulFunction","for","each","input","element","."]
code: def __init__(
      self,
      name,
      spec,
      counter_factory,
      sampler,
      consumers,
      operation_cls,
      operator_state_backend,
  ):
      super(FunctionOperation, self).__init__(
          name, spec, counter_factory, sampler
      )
      self._output_processors = self._create_output_processors(
          consumers
      )  # type: Dict[str, List[OutputProcessor]]
      self.operation_cls = operation_cls
      self.operator_state_backend = operator_state_backend
      self.operation = self.generate_operation()
      self.process_element = self.operation.process_element
      self.operation.open()
      if spec.serialized_fn.profile_enabled:
          self._profiler = Profiler()
      else:
          self._profiler = None
  
      if isinstance(spec.serialized_fn, UserDefinedDataStreamFunction):
          self._has_side_output = spec.serialized_fn.has_side_output
      else:
          # it doesn't support side output in Table API & SQL
          self._has_side_output = False
      if not self._has_side_output:
          self._main_output_processor = self._output_processors[
              DEFAULT_OUTPUT_TAG
          ][0]
  
imports: import abc
  from abc import abstractmethod
  from typing import Iterable, Any, Dict, List
  from apache_beam.runners.worker.bundle_processor import TimerInfo, DataOutputOperation
  from apache_beam.runners.worker.operations import Operation
  from apache_beam.utils import windowed_value
  from apache_beam.utils.windowed_value import WindowedValue
  from pyflink.common.constants import DEFAULT_OUTPUT_TAG
  from pyflink.fn_execution.flink_fn_execution_pb2 import UserDefinedDataStreamFunction
  from pyflink.fn_execution.table.operations import BundleOperation
  from pyflink.fn_execution.profiler import Profiler
label_desc: Use image node_id 1 to create a new FunctionOperation object from inherited base classes: Operation with example: obj = FunctionOperation(name, spec, counter_factory, sampler, consumers, operation_cls, operator_state_backend)