public void register ( final OEncryption iEncryption ) { try { final String name = iEncryption . name ( ) ; if ( instances . containsKey ( name ) ) throw new IllegalArgumentException ( "Encryption with name '" + name + "' was already registered" ) ; if ( classes . containsKey ( name ) ) throw new IllegalArgumentException ( "Encryption with name '" + name + "' was already registered" ) ; instances . put ( name , iEncryption ) ; } catch ( Exception e ) { OLogManager . instance ( ) . error ( this , "Cannot register storage encryption algorithm '%s'" , e , iEncryption ) ; } }
Registers a stateful implementations a new instance will be created for each storage .