steg
Class WDHC

java.lang.Object
  extended by steg.WDHC
All Implemented Interfaces:
CorrectionCode

public class WDHC
extends java.lang.Object
implements CorrectionCode

The Class encode/decodes a byte array with the WDH-Code

Author:
Dominik Heider

Constructor Summary
WDHC(int constant)
           
 
Method Summary
 byte[] decode(byte[] seq)
          Decodes a byte array
 byte[] encode(byte[] seq)
          Encodes a byte array
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WDHC

public WDHC(int constant)
Method Detail

encode

public byte[] encode(byte[] seq)
Encodes a byte array

Specified by:
encode in interface CorrectionCode
Parameters:
seq - the byte array to encode
Returns:
the encoded byte array

decode

public byte[] decode(byte[] seq)
Decodes a byte array

Specified by:
decode in interface CorrectionCode
Parameters:
seq - the byte array to decode
Returns:
the decoded byte array