|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
@StableMinor(version="6.1", sinceVersion="5.5") public interface ICipher
Defines the methods a cipher must implement. The cipher implementation must be thread-safe.
Method Summary | |
---|---|
byte[] |
decrypt(byte[] value)
Decrypts an array of bytes. |
java.lang.String |
decrypt(java.lang.String value)
Decrypts a string. |
byte[] |
encrypt(byte[] value)
Encrypts an array of bytes. |
java.lang.String |
encrypt(java.lang.String value)
Encrypts a string. |
Method Detail |
---|
java.lang.String encrypt(java.lang.String value)
value
- the original string.
java.lang.IllegalArgumentException
- if value
is null
.java.lang.String decrypt(java.lang.String value) throws InvalidEncryptedValueException
value
- the encrypted string.
java.lang.IllegalArgumentException
- if value
is null
.
InvalidEncryptedValueException
- if value
is
incompatible with this cipher (probably was not encrypted by it or
is corrupted).
java.lang.UnsupportedOperationException
- if this is a one-way cipher and
does not support decryption.byte[] encrypt(byte[] value)
value
- the original value.
java.lang.IllegalArgumentException
- if value
is null
.byte[] decrypt(byte[] value) throws InvalidEncryptedValueException
value
- the encrypted value.
java.lang.UnsupportedOperationException
- if this is a one-way cipher and
does not support decryption.
java.lang.IllegalArgumentException
- if value
is null
.
InvalidEncryptedValueException
- if value
is
incompatible with this cipher (probably was not encrypted by it or
is corrupted).
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |