01: package org.bouncycastle.util.encoders;
02:
03: /**
04: * general interface for an translator.
05: */
06: public interface Translator {
07: /**
08: * size of the output block on encoding produced by getDecodedBlockSize()
09: * bytes.
10: */
11: public int getEncodedBlockSize();
12:
13: public int encode(byte[] in, int inOff, int length, byte[] out,
14: int outOff);
15:
16: /**
17: * size of the output block on decoding produced by getEncodedBlockSize()
18: * bytes.
19: */
20: public int getDecodedBlockSize();
21:
22: public int decode(byte[] in, int inOff, int length, byte[] out,
23: int outOff);
24: }
|