org.mule.tck.security
Class MockEncryptionStrategy

java.lang.Object
  extended by org.mule.tck.security.Named
      extended by org.mule.tck.security.MockEncryptionStrategy
All Implemented Interfaces:
EncryptionStrategy, Initialisable

public class MockEncryptionStrategy
extends Named
implements EncryptionStrategy

Empty mock for tests


Field Summary
 
Fields inherited from interface org.mule.api.lifecycle.Initialisable
PHASE_NAME
 
Constructor Summary
MockEncryptionStrategy()
           
 
Method Summary
 byte[] decrypt(byte[] data, Object info)
           
 byte[] encrypt(byte[] data, Object info)
           
 void initialise()
          Method used to perform any initialisation work.
 
Methods inherited from class org.mule.tck.security.Named
getName, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mule.api.EncryptionStrategy
getName
 

Constructor Detail

MockEncryptionStrategy

public MockEncryptionStrategy()
Method Detail

encrypt

public byte[] encrypt(byte[] data,
                      Object info)
               throws CryptoFailureException
Specified by:
encrypt in interface EncryptionStrategy
Throws:
CryptoFailureException

decrypt

public byte[] decrypt(byte[] data,
                      Object info)
               throws CryptoFailureException
Specified by:
decrypt in interface EncryptionStrategy
Throws:
CryptoFailureException

initialise

public void initialise()
                throws InitialisationException
Description copied from interface: Initialisable
Method used to perform any initialisation work. If a fatal error occurs during initialisation an InitialisationException should be thrown, causing the Mule instance to shutdown. If the error is recoverable, say by retrying to connect, a RecoverableException should be thrown. There is no guarantee that by throwing a Recoverable exception that the Mule instance will not shut down.

Specified by:
initialise in interface Initialisable
Throws:
InitialisationException - if a fatal error occurs causing the Mule instance to shutdown
RecoverableException - if an error occurs that can be recovered from


Copyright © 2003-2009 MuleSource, Inc.. All Rights Reserved.