github.com/ethersphere/bee/v2@v2.2.0/pkg/bmt/reference/doc.go (about)

     1  // Copyright 2020 The Swarm Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  // Package reference is a simple nonconcurrent reference implementation for hashsize segment based
     6  // Binary Merkle tree hash on arbitrary but fixed maximum chunksize n where 0 <= n <= 4096
     7  //
     8  // This implementation does not take advantage of any paralellisms and uses
     9  // far more memory than necessary, but it is easy to see that it is correct.
    10  // It can be used for generating test cases for optimized implementations.
    11  // There is extra check on reference hasher correctness in bmt_test.go
    12  // * TestRefHasher
    13  // * testBMTHasherCorrectness function
    14  package reference