com.gisgraphy.domain.repository
Class SolRSynchroniser

java.lang.Object
  extended by com.gisgraphy.domain.repository.SolRSynchroniser
All Implemented Interfaces:
ISolRSynchroniser

public class SolRSynchroniser
extends java.lang.Object
implements ISolRSynchroniser

Interface of data access object for Language

Author:
David Masclet
See Also:
ISolRSynchroniser

Field Summary
protected static org.slf4j.Logger logger
           
 
Constructor Summary
SolRSynchroniser(SolrClient solrClient)
           
 
Method Summary
 void commit()
          Send a commit to the full text search engine
 void deleteAll()
          /!
 void deleteAllByPlaceType(java.lang.Class<? extends GisFeature> placetype)
           
 void handleEvent(IEvent event)
          handle an event in order to synchronise Data (the event may be add, update, delete a GIS object)
 void handleEvent(PlaceTypeDeleteAllEvent placeTypeDeleteAllEvent)
           
 void optimize()
          Send a optimize command to the full text search engine
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected static final org.slf4j.Logger logger
Constructor Detail

SolRSynchroniser

public SolRSynchroniser(SolrClient solrClient)
Method Detail

deleteAll

public void deleteAll()
Description copied from interface: ISolRSynchroniser
/!\USE IT WITH CARE/!\ : The Database and The full text search engine may be de-synchronised, because this method does not delete data in Database Delete all the data in the fulltext search engine AND COMMIT

Specified by:
deleteAll in interface ISolRSynchroniser

handleEvent

public void handleEvent(PlaceTypeDeleteAllEvent placeTypeDeleteAllEvent)

deleteAllByPlaceType

public void deleteAllByPlaceType(java.lang.Class<? extends GisFeature> placetype)

handleEvent

public void handleEvent(IEvent event)
Description copied from interface: ISolRSynchroniser
handle an event in order to synchronise Data (the event may be add, update, delete a GIS object)

Specified by:
handleEvent in interface ISolRSynchroniser
Parameters:
event - The event to handle

commit

public void commit()
Description copied from interface: ISolRSynchroniser
Send a commit to the full text search engine

Specified by:
commit in interface ISolRSynchroniser

optimize

public void optimize()
Description copied from interface: ISolRSynchroniser
Send a optimize command to the full text search engine

Specified by:
optimize in interface ISolRSynchroniser


Copyright © 2009. All Rights Reserved.