* Convert a byte[] to a List of LuceneWork (assuming the same SerializationProvider is used of course)
*/
@Override
public List<LuceneWork> toLuceneWorks(byte[] data) {
try {
Deserializer deserializer = provider.getDeserializer();
LuceneWorkHydrator hydrator = new LuceneWorkHydrator( searchFactory );
deserializer.deserialize( data, hydrator );
return hydrator.getLuceneWorks();
}
catch ( RuntimeException e ) {
if ( e instanceof SearchException ) {
throw e;