class ChainDataProvider {

  public SafeFuture<Optional<BeaconState>> getStateAtSlot(final UInt64 slot) {
    if (!combinedChainDataClient.isChainDataFullyAvailable()) {
      return chainUnavailable();
    }

    return combinedChainDataClient
        .getStateAtSlotExact(slot)
        .thenApply(stateInternal -> stateInternal.map(BeaconState::new));
  }

  public  ChainDataProvider(
      final RecentChainData recentChainData,
      final CombinedChainDataClient combinedChainDataClient);

}