class_docstr: Execute command in LevelDB.
  
  .. seealso::
      For more information on how to use this operator, take a look at the guide:
      :ref:`howto/operator:LevelDBOperator`
  
      :param command: command of plyvel(python wrap for leveldb) for DB object e.g.
          ``"put"``, ``"get"``, ``"delete"``, ``"write_batch"``.
      :param key: key for command(put,get,delete) execution(, e.g. ``b'key'``, ``b'another-key'``)
      :param value: value for command(put) execution(bytes, e.g. ``b'value'``, ``b'another-value'``)
      :param keys: keys for command(write_batch) execution(list[bytes], e.g. ``[b'key', b'another-key'])``
      :param values: values for command(write_batch) execution e.g. ``[b'value'``, ``b'another-value']``
      :param leveldb_conn_id:
      :param create_if_missing: whether a new database should be created if needed
      :param create_db_extra_options: extra options of creation LevelDBOperator. See more in the link below
          `Plyvel DB <https://plyvel.readthedocs.io/en/latest/api.html#DB>`__
docstr: Execute command in LevelDB.
  
  :returns: value from get(str, not bytes, to prevent error in json.dumps in serialize_value in xcom.py)
      or str | None
docstr_tok: ["Execute","command","in","LevelDB",".",":","returns",":","value","from","get","(","str",",","not","bytes",",","to","prevent","error","in","json.dumps","in","serialize_value","in","xcom.py",")","or","str","|","None"]
code: def execute(self, context: Context) -> str | None:
      """
      Execute command in LevelDB.
  
      :returns: value from get(str, not bytes, to prevent error in json.dumps in serialize_value in xcom.py)
          or str | None
      """
      leveldb_hook = LevelDBHook(leveldb_conn_id=self.leveldb_conn_id)
      leveldb_hook.get_conn(
          name=self.name,
          create_if_missing=self.create_if_missing,
          **self.create_db_extra_options,
      )
      value = leveldb_hook.run(
          command=self.command,
          key=self.key,
          value=self.value,
          keys=self.keys,
          values=self.values,
      )
      self.log.info("Done. Returned value was: %s", value)
      leveldb_hook.close_conn()
      str_value = value if value is None else value.decode()
      return str_value
  
file_path: airflow/airflow/providers/google/leveldb/operators/leveldb.py
imports: from __future__ import annotations
  from typing import TYPE_CHECKING, Any
  from airflow.models import BaseOperator
  from airflow.providers.google.leveldb.hooks.leveldb import LevelDBHook
label_desc: Use image node_id 2 for calling the LevelDBOperator obj's underlying member method code with example usage: obj.execute(context) and returns: str_value