com.trolltech.qt.core
Class QCryptographicHash

java.lang.Object
  extended by com.trolltech.qt.internal.QSignalEmitterInternal
      extended by com.trolltech.qt.QSignalEmitter
          extended by com.trolltech.qt.QtJambiObject
              extended by com.trolltech.qt.core.QCryptographicHash
All Implemented Interfaces:
QtJambiInterface

public class QCryptographicHash
extends QtJambiObject

The QCryptographicHash class provides a way to generate cryptographic hashes. QCryptographicHash can be used to generate cryptographic hashes of binary or text data.

Currently MD4, MD5, and SHA1 are supported.


Nested Class Summary
static class QCryptographicHash.Algorithm
           
 
Nested classes/interfaces inherited from class com.trolltech.qt.QSignalEmitter
QSignalEmitter.AbstractSignal, QSignalEmitter.PrivateSignal0, QSignalEmitter.PrivateSignal1, QSignalEmitter.PrivateSignal2, QSignalEmitter.PrivateSignal3, QSignalEmitter.PrivateSignal4, QSignalEmitter.PrivateSignal5, QSignalEmitter.PrivateSignal6, QSignalEmitter.PrivateSignal7, QSignalEmitter.PrivateSignal8, QSignalEmitter.PrivateSignal9, QSignalEmitter.Signal0, QSignalEmitter.Signal1, QSignalEmitter.Signal2, QSignalEmitter.Signal3, QSignalEmitter.Signal4, QSignalEmitter.Signal5, QSignalEmitter.Signal6, QSignalEmitter.Signal7, QSignalEmitter.Signal8, QSignalEmitter.Signal9
 
Nested classes/interfaces inherited from class com.trolltech.qt.internal.QSignalEmitterInternal
com.trolltech.qt.internal.QSignalEmitterInternal.AbstractSignalInternal
 
Field Summary
 
Fields inherited from class com.trolltech.qt.internal.QSignalEmitterInternal
currentSender
 
Constructor Summary
QCryptographicHash(QCryptographicHash.Algorithm method)
          Constructs an object that can be used to create a cryptographic hash from data using method.
 
Method Summary
 void addData(byte[] data)
          Adds data to the cryptographic hash.
 void addData(QByteArray data)
          /overload
static QByteArray hash(QByteArray data, QCryptographicHash.Algorithm method)
          Returns the hash of data using method.
 void reset()
          Resets the object.
 QByteArray result()
          Returns the final hash value.
 
Methods inherited from class com.trolltech.qt.QtJambiObject
dispose, disposed, equals, finalize, reassignNativeResources, tr, tr, tr
 
Methods inherited from class com.trolltech.qt.QSignalEmitter
blockSignals, disconnect, disconnect, signalsBlocked, signalSender, thread
 
Methods inherited from class com.trolltech.qt.internal.QSignalEmitterInternal
__qt_signalInitialization
 
Methods inherited from class java.lang.Object
clone, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.trolltech.qt.QtJambiInterface
disableGarbageCollection, nativeId, nativePointer, reenableGarbageCollection, setJavaOwnership
 

Constructor Detail

QCryptographicHash

public QCryptographicHash(QCryptographicHash.Algorithm method)
Constructs an object that can be used to create a cryptographic hash from data using method.

Method Detail

addData

public final void addData(QByteArray data)
/overload


reset

public final void reset()
Resets the object.


result

public final QByteArray result()
Returns the final hash value.

See also:
QByteArray::toHex().


hash

public static QByteArray hash(QByteArray data,
                              QCryptographicHash.Algorithm method)
Returns the hash of data using method.


addData

public final void addData(byte[] data)
Adds data to the cryptographic hash.