de.avetana.bluetooth.util
Class Base64
java.lang.Object
de.avetana.bluetooth.util.Base64
- public class Base64
- extends java.lang.Object
COPYRIGHT:
(c) Copyright 2004 Avetana GmbH ALL RIGHTS RESERVED.
This file is part of the Avetana bluetooth API for Linux.
The Avetana bluetooth API for Linux is free software; you can redistribute it
and/or modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2 of
the License, or (at your option) any later version.
The Avetana bluetooth API is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
The development of the Avetana bluetooth API is based on the work of
Christian Lorenz (see the Javabluetooth Stack at http://www.javabluetooth.org) for some classes,
on the work of the jbluez team (see http://jbluez.sourceforge.net/) and
on the work of the bluez team (see the BlueZ linux Stack at http://www.bluez.org) for the C code.
Classes, part of classes, C functions or part of C functions programmed by these teams and/or persons
are explicitly mentioned.
Description:
Does Base64 encoding/decoding as described in section (6.8.) of RFC 2045.
|
Field Summary |
static char[] |
translationTable
the Base64 translation table; does the same as 'encode()', but
this way decoding should be faster. |
|
Method Summary |
static char[] |
encode(byte[] text)
Encode char array to Base64 formatted char array. |
static void |
main(java.lang.String[] args)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
translationTable
public static final char[] translationTable
- the Base64 translation table; does the same as 'encode()', but
this way decoding should be faster.
Base64
public Base64()
encode
public static char[] encode(byte[] text)
- Encode char array to Base64 formatted char array.
- Parameters:
text - This argument must contain the text or binary data that shall be
encoded. This version of the 'encode()' method accepts a char array
as input and will - in contrast to the other 'encode()' method -
not try to do any conversion at all.
main
public static void main(java.lang.String[] args)