com.google.zxing.qrcode.decoder
Class Decoder

java.lang.Object
  extended by com.google.zxing.qrcode.decoder.Decoder

public final class Decoder
extends Object

The main class which implements QR Code decoding -- as opposed to locating and extracting the QR Code from an image.

Since:
BlackBerry API 6.0.0

Constructor Summary
Decoder()
           
 
Method Summary
 DecoderResult decode(boolean[][] image)
           
 DecoderResult decode(boolean[][] image, Hashtable hints)
          Convenience method that can decode a QR Code represented as a 2D array of booleans.
 DecoderResult decode(BitMatrix bits)
           
 DecoderResult decode(BitMatrix bits, Hashtable hints)
          Decodes a QR Code represented as a BitMatrix.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 



Constructor Detail

Decoder

public Decoder()
Since:
BlackBerry API 6.0.0


Method Detail

decode

public DecoderResult decode(boolean[][] image)
                     throws ChecksumException,
                            FormatException,
                            NotFoundException
Throws:
ChecksumException
FormatException
NotFoundException
Since:
BlackBerry API 6.0.0

decode

public DecoderResult decode(boolean[][] image,
                            Hashtable hints)
                     throws ChecksumException,
                            FormatException

Convenience method that can decode a QR Code represented as a 2D array of booleans. "true" is taken to mean a black module.

Parameters:
image - booleans representing white/black QR Code modules
Returns:
text and bytes encoded within the QR Code
Throws:
FormatException - if the QR Code cannot be decoded
ChecksumException - if error correction fails
Since:
BlackBerry API 7.0.0

decode

public DecoderResult decode(BitMatrix bits)
                     throws ChecksumException,
                            FormatException
Throws:
ChecksumException
FormatException
Since:
BlackBerry API 6.0.0

decode

public DecoderResult decode(BitMatrix bits,
                            Hashtable hints)
                     throws FormatException,
                            ChecksumException

Decodes a QR Code represented as a BitMatrix. A 1 or "true" is taken to mean a black module.

Parameters:
bits - booleans representing white/black QR Code modules
Returns:
text and bytes encoded within the QR Code
Throws:
FormatException - if the QR Code cannot be decoded
ChecksumException - if error correction fails
Since:
BlackBerry API 7.0.0





Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal