diff --git a/source/zxing/zxing/qrcode/ErrorCorrectionLevel.h b/source/zxing/zxing/qrcode/ErrorCorrectionLevel.h index b688b90..5ad9718 100644 --- a/source/zxing/zxing/qrcode/ErrorCorrectionLevel.h +++ b/source/zxing/zxing/qrcode/ErrorCorrectionLevel.h @@ -21,11 +21,12 @@ */ #include +#include namespace zxing { namespace qrcode { -class ErrorCorrectionLevel { +class ErrorCorrectionLevel : public Counted { private: int ordinal_; int bits_; diff --git a/source/zxing/zxing/qrcode/decoder/Mode.h b/source/zxing/zxing/qrcode/decoder/Mode.h index 4d1b365..65c99a4 100644 --- a/source/zxing/zxing/qrcode/decoder/Mode.h +++ b/source/zxing/zxing/qrcode/decoder/Mode.h @@ -23,11 +23,13 @@ #include #include +#include namespace zxing { namespace qrcode { -class Mode { +class Mode : public Counted +{ private: int characterCountBitsForVersions0To9_; int characterCountBitsForVersions10To26_; @@ -53,9 +55,11 @@ public: static Mode& forBits(int bits); int getCharacterCountBits(Version *version); - int getBits() { return bits_; } + int getBits() const { return bits_; } bool operator==(const Mode& other); + + std::string getName() const { return name_; } }; } } diff --git a/source/zxing/zxing/qrcode/encoder/ByteMatrix.h b/source/zxing/zxing/qrcode/encoder/ByteMatrix.h index b9e1319..6833af5 100644 --- a/source/zxing/zxing/qrcode/encoder/ByteMatrix.h +++ b/source/zxing/zxing/qrcode/encoder/ByteMatrix.h @@ -3,11 +3,12 @@ #include #include +#include namespace zxing { namespace qrcode { -class ByteMatrix +class ByteMatrix : public Counted { private: std::vector< std::vector > bytes_; diff --git a/source/zxing/zxing/qrcode/encoder/QRCode.cpp b/source/zxing/zxing/qrcode/encoder/QRCode.cpp index 77e7b43..f45aaea 100644 --- a/source/zxing/zxing/qrcode/encoder/QRCode.cpp +++ b/source/zxing/zxing/qrcode/encoder/QRCode.cpp @@ -42,7 +42,7 @@ Ref QRCode::getVersion() const return version_ptr_; } -const int QRCode::getMaskPattern() const +int QRCode::getMaskPattern() const { return maskPattern_; } diff --git a/source/zxing/zxing/qrcode/encoder/QRCode.h b/source/zxing/zxing/qrcode/encoder/QRCode.h index 7f44f54..af67cd0 100644 --- a/source/zxing/zxing/qrcode/encoder/QRCode.h +++ b/source/zxing/zxing/qrcode/encoder/QRCode.h @@ -5,15 +5,15 @@ #include #include #include "ByteMatrix.h" +#include #include namespace zxing { namespace qrcode { -class QRCode +class QRCode : public Counted { private: - static const int NUM_MASK_PATTERNS = 8; Ref mode_ptr_; Ref ecLevel_ptr_; @@ -22,13 +22,14 @@ private: Ref matrix_ptr_; public: + static const int NUM_MASK_PATTERNS = 8; QRCode(); ~QRCode(); Ref getMode() const; Ref getECLevel() const; Ref getVersion() const; - const int getMaskPattern() const; + int getMaskPattern() const; Ref getMatrix() const; const std::string toString(); void setMode(Ref value);