Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

Class PaddingTransformer  view PaddingTransformer download

  extended bygnu.javax.crypto.assembly.Transformer
      extended bygnu.javax.crypto.assembly.PaddingTransformer

class PaddingTransformer
extends Transformer

An Adapter to use any gnu.javax.crypto.pad.IPad as a Transformer in an Assembly.

When using such a Transformer, in an Assembly, there must be at least one element behind this instance in the constructed chain; otherwise, a TransformerException is thrown at initialisation time.

Field Summary
private  gnu.javax.crypto.pad.IPad delegate
private  int outputBlockSize
Fields inherited from class gnu.javax.crypto.assembly.Transformer
DIRECTION, inBuffer, mode, outBuffer, tail, wired
Constructor Summary
(package private) PaddingTransformer(gnu.javax.crypto.pad.IPad padding)
Method Summary
(package private)  int delegateBlockSize()
(package private)  void initDelegate(java.util.Map attributes)
(package private)  byte[] lastUpdateDelegate()
(package private)  void resetDelegate()
(package private)  byte[] updateDelegate(byte[] in, int offset, int length)
Methods inherited from class gnu.javax.crypto.assembly.Transformer
currentBlockSize, getCascadeTransformer, getDeflateTransformer, getPaddingTransformer, init, isPostProcessing, isPreProcessing, lastUpdate, lastUpdate, lastUpdate, lastUpdate, reset, setMode, update, update, update
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail


private gnu.javax.crypto.pad.IPad delegate


private int outputBlockSize
Constructor Detail


PaddingTransformer(gnu.javax.crypto.pad.IPad padding)
Method Detail


void initDelegate(java.util.Map attributes)
            throws TransformerException
Specified by:
initDelegate in class Transformer


int delegateBlockSize()
Specified by:
delegateBlockSize in class Transformer


void resetDelegate()
Specified by:
resetDelegate in class Transformer


byte[] updateDelegate(byte[] in,
                      int offset,
                      int length)
                throws TransformerException
Specified by:
updateDelegate in class Transformer


byte[] lastUpdateDelegate()
                    throws TransformerException
Specified by:
lastUpdateDelegate in class Transformer