content: import 'package:bb_mobile/core/blockchain/domain/usecases/broadcast_bitcoin_transaction_usecase.dart';
  import 'package:bb_mobile/core/blockchain/domain/usecases/broadcast_liquid_transaction_usecase.dart';
  import 'package:bb_mobile/core/exchange/domain/repositories/exchange_order_repository.dart';
  import 'package:bb_mobile/core/exchange/domain/usecases/convert_sats_to_currency_amount_usecase.dart';
  import 'package:bb_mobile/core/exchange/domain/usecases/get_exchange_user_summary_usecase.dart';
  import 'package:bb_mobile/core/exchange/domain/usecases/get_order_usercase.dart';
  import 'package:bb_mobile/core/fees/domain/get_network_fees_usecase.dart';
  import 'package:bb_mobile/core/settings/data/settings_repository.dart';
  import 'package:bb_mobile/core/settings/domain/get_settings_usecase.dart';
  import 'package:bb_mobile/core/wallet/domain/usecases/get_address_at_index_usecase.dart';
  import 'package:bb_mobile/core/wallet/domain/usecases/get_wallet_utxos_usecase.dart';
  import 'package:bb_mobile/features/sell/domain/create_sell_order_usecase.dart';
  import 'package:bb_mobile/features/sell/domain/refresh_sell_order_usecase.dart';
  import 'package:bb_mobile/features/sell/presentation/bloc/sell_bloc.dart';
  import 'package:bb_mobile/features/send/domain/usecases/calculate_bitcoin_absolute_fees_usecase.dart';
  import 'package:bb_mobile/features/send/domain/usecases/calculate_liquid_absolute_fees_usecase.dart';
  import 'package:bb_mobile/features/send/domain/usecases/prepare_bitcoin_send_usecase.dart';
  import 'package:bb_mobile/features/send/domain/usecases/prepare_liquid_send_usecase.dart';
  import 'package:bb_mobile/features/send/domain/usecases/sign_bitcoin_tx_usecase.dart';
  import 'package:bb_mobile/features/send/domain/usecases/sign_liquid_tx_usecase.dart';
  import 'package:bb_mobile/locator.dart';
  
  class SellLocator {
    static void setup() {
      registerUsecases();
      registerBlocs();
    }
  
    static void registerUsecases() {
      locator.registerFactory<CreateSellOrderUsecase>(
        () => CreateSellOrderUsecase(
          mainnetExchangeOrderRepository: locator<ExchangeOrderRepository>(
            instanceName: 'mainnetExchangeOrderRepository',
          ),
          testnetExchangeOrderRepository: locator<ExchangeOrderRepository>(
            instanceName: 'testnetExchangeOrderRepository',
          ),
          settingsRepository: locator<SettingsRepository>(),
        ),
      );
  
      locator.registerFactory<RefreshSellOrderUsecase>(
        () => RefreshSellOrderUsecase(
          mainnetExchangeOrderRepository: locator<ExchangeOrderRepository>(
            instanceName: 'mainnetExchangeOrderRepository',
          ),
          testnetExchangeOrderRepository: locator<ExchangeOrderRepository>(
            instanceName: 'testnetExchangeOrderRepository',
          ),
          settingsRepository: locator<SettingsRepository>(),
        ),
      );
  
      locator.registerFactory<GetAddressAtIndexUsecase>(
        () => GetAddressAtIndexUsecase(walletAddressRepository: locator()),
      );
    }
  
    static void registerBlocs() {
      locator.registerFactory<SellBloc>(
        () => SellBloc(
          getExchangeUserSummaryUsecase: locator<GetExchangeUserSummaryUsecase>(),
          getSettingsUsecase: locator<GetSettingsUsecase>(),
          createSellOrderUsecase: locator<CreateSellOrderUsecase>(),
          refreshSellOrderUsecase: locator<RefreshSellOrderUsecase>(),
          prepareBitcoinSendUsecase: locator<PrepareBitcoinSendUsecase>(),
          prepareLiquidSendUsecase: locator<PrepareLiquidSendUsecase>(),
          signBitcoinTxUsecase: locator<SignBitcoinTxUsecase>(),
          signLiquidTxUsecase: locator<SignLiquidTxUsecase>(),
          broadcastBitcoinTransactionUsecase:
              locator<BroadcastBitcoinTransactionUsecase>(),
          broadcastLiquidTransactionUsecase:
              locator<BroadcastLiquidTransactionUsecase>(),
          getNetworkFeesUsecase: locator<GetNetworkFeesUsecase>(),
          calculateLiquidAbsoluteFeesUsecase:
              locator<CalculateLiquidAbsoluteFeesUsecase>(),
          calculateBitcoinAbsoluteFeesUsecase:
              locator<CalculateBitcoinAbsoluteFeesUsecase>(),
          convertSatsToCurrencyAmountUsecase:
              locator<ConvertSatsToCurrencyAmountUsecase>(),
          getAddressAtIndexUsecase: locator<GetAddressAtIndexUsecase>(),
          getWalletUtxosUsecase: locator<GetWalletUtxosUsecase>(),
          getOrderUsecase: locator<GetOrderUsecase>(),
        ),
      );
    }
  }
  