text: # library imports
  
  # project imports
  
  
  class Employee:
      """
      A single employee that a business has
      """
  
      def __init__(self,
                   business_index: int,
                   index: int,
                   price: float,
                   output: float):
          self._business_index = business_index
          self._index = index
          self._price = price
          self._output = output
  
      def to_json(self):
          return {"_business_index": self._business_index,
                  "_index": self._index,
                  "_price": self._price,
                  "_output": self._output}
  
      @staticmethod
      def from_json(data):
          return Employee(business_index=data["_business_index"],
                          index=data["_index"],
                          price=data["_price"],
                          output=data["_output"])
  
      # Setters #
  
      def update_price(self,
                       new_price: float):
          self._price = new_price
  
      def update_output(self,
                        new_output: float):
          self._output = new_output
  
      # End - Setters #
  
      # Getters #
  
      def get_output(self):
          return self._output
  
      def get_price(self):
          return self._price
  
      def get_index(self):
          return self._index
  
      def get_business_index(self):
          return self._business_index
  
      def get_key(self):
          return "{}_{}".format(self.get_business_index(), self.get_index())
  
      # End - Getters #
  
      @staticmethod
      def to_search_dict(employees: list):
          return {employee.get_key(): employee.get_price() for employee in employees}
  
      def __repr__(self):
          return self.__str__()
  
      def __str__(self):
          return "<Employee | business_index: {}, index: {}, price: {:.3f}, output: {:.3f}>" \
              .format(self._business_index,
                      self._index,
                      self._output,
                      self._price)
  