class_docstr: A helper class for building Dataproc job.
class_docstr_tok: ["A","helper","class","for","building","Dataproc","job","."]
docstr: Set Dataproc main class.
  
  :param main_jar: URI for the main file.
  :param main_class: Name of the main class.
  :raises: Exception
code: def set_main(
      self, main_jar: str | None = None, main_class: str | None = None
  ) -> None:
      """Set Dataproc main class.
  
      :param main_jar: URI for the main file.
      :param main_class: Name of the main class.
      :raises: Exception
      """
      if main_class is not None and main_jar is not None:
          raise Exception("Set either main_jar or main_class")
      if main_jar:
          self.job["job"][self.job_type]["main_jar_file_uri"] = main_jar
      else:
          self.job["job"][self.job_type]["main_class"] = main_class
  
imports: from __future__ import annotations
  import time
  import uuid
  from typing import TYPE_CHECKING, Any, Sequence
  from google.api_core.client_options import ClientOptions
  from google.api_core.exceptions import ServerError
  from google.api_core.gapic_v1.method import DEFAULT, _MethodDefault
  from google.cloud.dataproc_v1 import Batch, BatchControllerAsyncClient, BatchControllerClient, Cluster, ClusterControllerAsyncClient, ClusterControllerClient, Job, JobControllerAsyncClient, JobControllerClient, JobStatus, WorkflowTemplate, WorkflowTemplateServiceAsyncClient, WorkflowTemplateServiceClient
  from airflow.exceptions import AirflowException
  from airflow.providers.google.common.consts import CLIENT_INFO
  from airflow.providers.google.common.hooks.base_google import GoogleBaseHook
  from airflow.version import version
label_desc: Use image node_id 11 for calling the DataProcJobBuilder obj's underlying member method code with example usage: obj.set_main(main_jar, main_class) without return types