重构v2.0
This commit is contained in:
35
lib/src/main/java/com/king/zxing/analyze/QRCodeAnalyzer.java
Normal file
35
lib/src/main/java/com/king/zxing/analyze/QRCodeAnalyzer.java
Normal file
@@ -0,0 +1,35 @@
|
||||
package com.king.zxing.analyze;
|
||||
|
||||
import com.google.zxing.DecodeHintType;
|
||||
import com.google.zxing.Reader;
|
||||
import com.google.zxing.qrcode.QRCodeReader;
|
||||
import com.king.zxing.DecodeConfig;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
|
||||
/**
|
||||
* @author <a href="mailto:jenly1314@gmail.com">Jenly</a>
|
||||
*/
|
||||
public class QRCodeAnalyzer extends BarcodeFormatAnalyzer {
|
||||
|
||||
public QRCodeAnalyzer() {
|
||||
this((DecodeConfig)null);
|
||||
}
|
||||
|
||||
public QRCodeAnalyzer(@Nullable Map<DecodeHintType,Object> hints){
|
||||
this(new DecodeConfig().setHints(hints));
|
||||
}
|
||||
|
||||
public QRCodeAnalyzer(@Nullable DecodeConfig config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Reader createReader() {
|
||||
return new QRCodeReader();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user