开发者

Google's zxing (Zebra Crossing) barcode library's BitMatrix not where it's supposed to be

开发者 https://www.devze.com 2023-02-28 20:10 出处:网络
The javadoc lists the BitMatrix class as being in com.google.zxing.common. com.google.zxing.common Class BitMatrix

The javadoc lists the BitMatrix class as being in com.google.zxing.common.

com.google.zxing.common 
Class BitMatrix

java.lang.Object
  com.google.zxing.common.BitMatrix

But after I compile the core jar, it is in com.google.zxing.qrcode.encoder.

$ jar tvf core.jar | grep ByteMatrix
  1851 Thu Ap开发者_C百科r 21 18:01:14 PDT 2011 com/google/zxing/qrcode/encoder/ByteMatrix.class

So I am getting compile errors.

[javac] Compiling 1 source file to /home/dacracot/Code/QRtest/tmp/classes
[javac] /home/dacracot/Code/QRtest/src/QRtest.java:14: cannot find symbol
[javac] symbol  : class ByteMatrix
[javac] location: package com.google.zxing.common
[javac] import com.google.zxing.common.ByteMatrix;
[javac]                               ^

What gives? Using version 1.6.


You are looking for BitMatrix, but then you grep for ByteMatrix. These are different classes. ByteMatrix is indeed only a support class for that encoder. Both are in the same respective places in the source and jar, and both are where they are intended to be.

0

精彩评论

暂无评论...
验证码 换一张
取 消