class BlockchainServiceImpl implements BlockchainService {

    @Override
    public synchronized <H extends Object, B extends Serializable> List<B> getAll(List<H> hashes, Blockchain blockchain, BlockchainUnitType type) throws IOException, ClassNotFoundException {
        logger.traceEntry("params: {} {} {}", hashes, blockchain, type);

        Util.check(hashes != null, "hashes!=null");
        Util.check(blockchain != null, "blockchain!=null");

        List<B> list = new ArrayList<>();

        for (H hash : hashes) {

            B val = getLocal(hash, blockchain, type);
            if (val != null) {
                list.add(val);
            }
        }

        return logger.traceExit(list);
    }

}