@@ -345,7 +345,7 @@ def _save_or_verify_genesis(self) -> None:
345345 assert tx == tx2
346346 except TransactionDoesNotExist :
347347 self .save_transaction (tx )
348- self .add_to_non_critical_indexes (tx )
348+ self .indexes . add_to_non_critical_indexes (tx )
349349 tx2 = tx
350350 self ._genesis_cache [tx2 .hash ] = tx2
351351
@@ -482,9 +482,9 @@ def remove_transaction(self, tx: BaseTransaction) -> None:
482482
483483 :param tx: Transaction to be removed
484484 """
485- self .del_from_critical_indexes (tx )
485+ self .indexes . del_from_critical_indexes (tx )
486486 with non_critical_code (self .log ):
487- self .del_from_non_critical_indexes (tx , remove_all = True )
487+ self .indexes . del_from_non_critical_indexes (tx , remove_all = True )
488488
489489 @abstractmethod
490490 def transaction_exists (self , hash_bytes : bytes ) -> bool :
@@ -782,18 +782,6 @@ def _topological_sort_metadata(self) -> Iterator[BaseTransaction]:
782782 """
783783 raise NotImplementedError
784784
785- @abstractmethod
786- def add_to_non_critical_indexes (self , tx : BaseTransaction ) -> None :
787- raise NotImplementedError
788-
789- @abstractmethod
790- def del_from_critical_indexes (self , tx : BaseTransaction ) -> None :
791- raise NotImplementedError
792-
793- @abstractmethod
794- def del_from_non_critical_indexes (self , tx : BaseTransaction , * , remove_all : bool = False ) -> None :
795- raise NotImplementedError
796-
797785 @abstractmethod
798786 def get_block_count (self ) -> int :
799787 raise NotImplementedError
@@ -1290,15 +1278,6 @@ def _run_topological_sort_dfs(self, root: BaseTransaction, visited: dict[bytes,
12901278 else :
12911279 stack .append (txinput )
12921280
1293- def add_to_non_critical_indexes (self , tx : BaseTransaction ) -> None :
1294- self .indexes .add_tx_to_non_critical_indexes (tx )
1295-
1296- def del_from_critical_indexes (self , tx : BaseTransaction ) -> None :
1297- self .indexes .del_tx_from_critical_indexes (tx )
1298-
1299- def del_from_non_critical_indexes (self , tx : BaseTransaction , * , remove_all : bool = False ) -> None :
1300- self .indexes .del_tx_from_non_critical_indexes (tx , remove_all = remove_all )
1301-
13021281 def get_block_count (self ) -> int :
13031282 return self .indexes .info .get_block_count ()
13041283
0 commit comments