Automattic\WooCommerce\Internal\DataStores\Orders
LegacyDataHandler::init
Class initialization, invoked by the DI container.
Method of the class: LegacyDataHandler{}
No Hooks.
Returns
null. Nothing (null).
Usage
$LegacyDataHandler = new LegacyDataHandler(); $LegacyDataHandler->init( $data_store, $data_synchronizer, $posts_to_cot_migrator );
- $data_store(OrdersTableDataStore) (required)
- HPOS datastore instance to use.
- $data_synchronizer(DataSynchronizer) (required)
- DataSynchronizer instance to use.
- $posts_to_cot_migrator(PostsToOrdersMigrationController) (required)
- Posts to HPOS migration controller instance to use.
LegacyDataHandler::init() LegacyDataHandler::init code WC 10.4.3
final public function init( OrdersTableDataStore $data_store, DataSynchronizer $data_synchronizer, PostsToOrdersMigrationController $posts_to_cot_migrator ) {
$this->data_store = $data_store;
$this->data_synchronizer = $data_synchronizer;
$this->posts_to_cot_migrator = $posts_to_cot_migrator;
}