Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
BC_ReedSolomonGF256Poly.h
Go to the documentation of this file.
1// Copyright 2014 The PDFium Authors
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6
7#ifndef FXBARCODE_COMMON_REEDSOLOMON_BC_REEDSOLOMONGF256POLY_H_
8#define FXBARCODE_COMMON_REEDSOLOMON_BC_REEDSOLOMONGF256POLY_H_
9
10#include <memory>
11#include <vector>
12
13#include "core/fxcrt/unowned_ptr.h"
14
16
17class CBC_ReedSolomonGF256Poly final {
18 public:
20 const std::vector<int32_t>& coefficients);
22
23 int32_t GetCoefficients(int32_t degree) const;
24 const std::vector<int32_t>& GetCoefficients() const;
25 int32_t GetDegree() const;
26 bool IsZero() const;
28 const CBC_ReedSolomonGF256Poly* other);
30 const CBC_ReedSolomonGF256Poly* other);
32 int32_t degree,
33 int32_t coefficient) const;
35 const CBC_ReedSolomonGF256Poly* other);
37
38 private:
39 UnownedPtr<CBC_ReedSolomonGF256> const m_field;
40 std::vector<int32_t> m_coefficients;
41};
42
43#endif // FXBARCODE_COMMON_REEDSOLOMON_BC_REEDSOLOMONGF256POLY_H_
bool Encode(std::vector< int32_t > *toEncode, size_t ecBytes)
CBC_ReedSolomonEncoder(CBC_ReedSolomonGF256 *field)
std::unique_ptr< CBC_ReedSolomonGF256Poly > Clone() const
std::unique_ptr< CBC_ReedSolomonGF256Poly > MultiplyByMonomial(int32_t degree, int32_t coefficient) const
std::unique_ptr< CBC_ReedSolomonGF256Poly > Multiply(const CBC_ReedSolomonGF256Poly *other)
int32_t GetCoefficients(int32_t degree) const
const std::vector< int32_t > & GetCoefficients() const
CBC_ReedSolomonGF256Poly(CBC_ReedSolomonGF256 *field, const std::vector< int32_t > &coefficients)
std::unique_ptr< CBC_ReedSolomonGF256Poly > Divide(const CBC_ReedSolomonGF256Poly *other)
std::unique_ptr< CBC_ReedSolomonGF256Poly > AddOrSubtract(const CBC_ReedSolomonGF256Poly *other)
CBC_ReedSolomonGF256Poly * GetZero() const
int32_t Multiply(int32_t a, int32_t b)
absl::optional< int32_t > Inverse(int32_t a)
CBC_ReedSolomonGF256Poly * GetOne() const
std::unique_ptr< CBC_ReedSolomonGF256Poly > BuildMonomial(int32_t degree, int32_t coefficient)
CBC_ReedSolomonGF256(int32_t primitive)
static int32_t AddOrSubtract(int32_t a, int32_t b)