java.lang.Object
com.simtechdata.googleauthdecoder.Decoder

public class Decoder extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
    Decoder(File imageFile)
    Main constructor that will be used to prime the library with your QR image file.
    Decoder(File imageFile, int size)
    Alternate constructor that will be used to prime the library with your QR image file as well as the size of your png image file.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    This is the method that will do all the heavy lifting by converting the QR image into a single string, then passing that string into the Python script, then extracting all the account details from each account that is in the QR image.
    Use this method to get the list of the raw strings that are generated from the Python script
    Use this method to get the list of OTPRecords that is generated from the decode() method.
    static void
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Decoder

      public Decoder(File imageFile)
      Main constructor that will be used to prime the library with your QR image file.
      Parameters:
      imageFile - - a java.nio.File object
    • Decoder

      public Decoder(File imageFile, int size)
      Alternate constructor that will be used to prime the library with your QR image file as well as the size of your png image file. If your png file is larger than 1000 x 1000 pixels, then round to the next highest 50 value and pass it into this constructor. So an image of 1310 x 1310 would get passed in using a size of 1350.
      Parameters:
      imageFile - - a java.nio.File object
      size - - an integer of the size of your png file rounded to the next 50
  • Method Details

    • decode

      public void decode()
      This is the method that will do all the heavy lifting by converting the QR image into a single string, then passing that string into the Python script, then extracting all the account details from each account that is in the QR image.
    • getRecords

      public List<OTPRecord> getRecords()
      Use this method to get the list of OTPRecords that is generated from the decode() method.
    • getRawOTP

      public List<String> getRawOTP()
      Use this method to get the list of the raw strings that are generated from the Python script
    • info

      public static void info()