Uploaded image for project: 'Commons Codec'
  1. Commons Codec
  2. CODEC-181

Make possible to provide padding byte to BaseNCodec in constructor

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.9, 1.10
    • 1.10
    • None

    Description

      Hi,

      I'm developing an application that generates QRCodes, so the user does not need to type a HMAC value. QRCodes [1] supports different encoding formats, in particular the alpha numeric format is almost compatible with the Base32 (the only problematic character is the '=' character).

      I created an almost exact copy of Base32 class in order to change the padding byte, however the BaseNCodec#PAD byte is final and not settable in the class constructor.

      I already tested this approach and I can provide a patch to support this new feature.

      [1] http://en.wikipedia.org/wiki/QR_code

      Attachments

        1. BaseNCodec_new_constructor.patch
          2 kB
          Ivan Martinez-Ortiz
        2. patch_with_test_case.diff
          15 kB
          Ivan Martinez-Ortiz

        Activity

          People

            ggregory Gary D. Gregory
            imartinez Ivan Martinez-Ortiz
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: