Package org.hibernate.search.indexes.serialization.impl

Examples of org.hibernate.search.indexes.serialization.impl.LuceneWorkSerializerImpl.toLuceneWorks()


        searchFactoryHolder.getSearchFactory()
    );
    List<LuceneWork> works = buildWorks();

    byte[] bytes = converter.toSerializedModel( works );
    List<LuceneWork> copyOfWorks = converter.toLuceneWorks( bytes );

    assertThat( copyOfWorks ).hasSize( works.size() );
    for ( int index = 0; index < works.size(); index++ ) {
      AvroTestHelpers.assertLuceneWork( works.get( index ), copyOfWorks.get( index ) );
    }
View Full Code Here


    //this is how the 'persistent-avro-1.0' resource was created:
    // final byte[] outbytes = converter.toSerializedModel( worksAsSerialized );
    // storeSerializedForm(outbytes);

    byte[] bytes = loadResource();
    List<LuceneWork> deserialized = converter.toLuceneWorks( bytes );

    assertThat( deserialized ).hasSize( worksAsSerialized.size() );
    for ( int index = 0; index < worksAsSerialized.size(); index++ ) {
      AvroTestHelpers.assertLuceneWork( worksAsSerialized.get( index ), deserialized.get( index ) );
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.