MjSip Stack
v1.6

org.zoolu.tools
Class MessageDigest

java.lang.Object
  |
  +--org.zoolu.tools.MessageDigest
Direct Known Subclasses:
MD5, SimpleDigest

public abstract class MessageDigest
extends java.lang.Object

Generic hash/message-digest algorithm.


Constructor Summary
MessageDigest()
           
 
Method Summary
 java.lang.String asHex()
          Gets the Message Digest as string of hex values.
static java.lang.String asHex(byte[] buf)
          Transforms an array of bytes into a string of hex values.
abstract  byte[] doFinal()
          MessageDigest finalization.
 byte[] getDigest()
          Gets the MessageDigest.
 MessageDigest update(byte[] buffer)
          MessageDigest block update operation.
abstract  MessageDigest update(byte[] buffer, int offset, int len)
          MessageDigest block update operation.
 MessageDigest update(java.lang.String str)
          MessageDigest block update operation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageDigest

public MessageDigest()
Method Detail

update

public abstract MessageDigest update(byte[] buffer,
                                     int offset,
                                     int len)
MessageDigest block update operation. Continues a message-digest operation, processing another message block, and updating the context.

update

public MessageDigest update(java.lang.String str)
MessageDigest block update operation. Continues a message-digest operation, processing another message block, and updating the context.

update

public MessageDigest update(byte[] buffer)
MessageDigest block update operation. Continues a message-digest operation, processing another message block, and updating the context.

doFinal

public abstract byte[] doFinal()
MessageDigest finalization. Ends a message-digest operation, writing the the message digest and zeroizing the context.

getDigest

public byte[] getDigest()
Gets the MessageDigest. The same as doFinal().

asHex

public java.lang.String asHex()
Gets the Message Digest as string of hex values.

asHex

public static java.lang.String asHex(byte[] buf)
Transforms an array of bytes into a string of hex values.

MjSip Stack
v1.6