LCOV - code coverage report
Current view: top level - irohad/multi_sig_transactions/impl - hash.cpp (source / functions) Hit Total Coverage
Test: coverage_cleared.info Lines: 2 2 100.0 %
Date: 2018-12-05 17:11:35 Functions: 2 2 100.0 %

          Line data    Source code
       1             : /**
       2             :  * Copyright Soramitsu Co., Ltd. All Rights Reserved.
       3             :  * SPDX-License-Identifier: Apache-2.0
       4             :  */
       5             : 
       6             : #include "multi_sig_transactions/hash.hpp"
       7             : 
       8             : #include <functional>
       9             : #include <string>
      10             : 
      11             : #include <boost/functional/hash.hpp>
      12             : #include "cryptography/blob.hpp"
      13             : #include "cryptography/public_key.hpp"
      14             : #include "interfaces/common_objects/peer.hpp"
      15             : #include "interfaces/iroha_internal/transaction_batch.hpp"
      16             : 
      17             : namespace iroha {
      18             :   namespace model {
      19             : 
      20             :     size_t PointerBatchHasher::operator()(const DataType &batch) const {
      21         531 :       return std::hash<std::string>{}(batch->reducedHash().hex());
      22             :     }
      23             : 
      24             :     std::size_t BlobHasher::operator()(
      25             :         const shared_model::crypto::Blob &blob) const {
      26          42 :       return boost::hash_value(blob.blob());
      27             :     }
      28             : 
      29             :   }  // namespace model
      30             : }  // namespace iroha

Generated by: LCOV version 1.13