@Override
  public long addLogListener(
      final List<Address> addresses,
      final List<List<Bytes32>> topics,
      final LogListener logListener) {
    final List<List<LogTopic>> besuTopics =
        topics.stream()
            .map(subList -> subList.stream().map(LogTopic::wrap).collect(toUnmodifiableList()))
            .collect(toUnmodifiableList());

    final LogsQuery logsQuery = new LogsQuery(addresses, besuTopics);

    return blockchain.observeLogs(
        logWithMetadata -> {
          if (logsQuery.matches(LogWithMetadata.fromPlugin(logWithMetadata))) {
            logListener.onLogEmitted(logWithMetadata);
          }
        });
  }
Constructor for BesuEventsImpl

@param blockchain An instance of Blockchain
@param blockBroadcaster An instance of BlockBroadcaster
@param transactionPool An instance of TransactionPool
@param syncState An instance of SyncState
@param badBlockManager A cache of bad blocks encountered on the network
app/src/main/java/org/hyperledger/besu/services/BesuEventsImpl.java