class_docstr: Holds the inventory of 2D pieces and performs cutting.
  :param max_pieces_in_inventory: Size of the inventory. If full, the oldest pieces get discarded.
  :param raw_piece_size: Size of a fresh raw (= full-size) piece.
  :param inventory_events: Inventory event dispatch proxy.
class_docstr_tok: ["Holds","the","inventory","of","2D","pieces","and","performs","cutting",".",":","param","max_pieces_in_inventory",":","Size","of","the","inventory",".","If","full",",","the","oldest","pieces","get","discarded",".",":","param","raw_piece_size",":","Size","of","a","fresh","raw","(","=","full-size",")","piece",".",":","param","inventory_events",":","Inventory","event","dispatch","proxy","."]
docstr: Store the given piece.
  :param piece: Piece to store.
docstr_tok: ["Store","the","given","piece",".",":","param","piece",":","Piece","to","store","."]
code: def store_piece(self, piece: (int, int)) -> None:
      """Store the given piece.
      :param piece: Piece to store.
      """
      # If we would run out of storage space, discard the oldest piece first
      if self.is_full():
          self.pieces.pop(0)
          self.inventory_events.piece_discarded(piece=piece)
  
      self.pieces.append(piece)
  
imports: from .events import InventoryEvents
label_desc: Use image node_id 2 for calling the Inventory obj's underlying member method code with example usage: obj.store_piece(piece) without return types