|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.compass.gps.impl.AbstractCompassGps
org.compass.gps.impl.SingleCompassGps
public class SingleCompassGps
A CompassGps implementation that holds a
single Compass instance. The Compass instance
is used for both the index operation and the mirror operation.
When executing the mirror operation, the implementation will not use the
configured transaction isolation, but will use the
setIndexTransactionIsolation(CompassTransaction.TransactionIsolation)
transaction isolation, which defaults to lucene. Cascading
will also be disabled.
| Field Summary |
|---|
| Fields inherited from class org.compass.gps.impl.AbstractCompassGps |
|---|
devices, log |
| Constructor Summary | |
|---|---|
SingleCompassGps()
|
|
SingleCompassGps(Compass compass)
|
|
| Method Summary | |
|---|---|
protected void |
doIndex(IndexPlan indexPlan)
|
protected void |
doStart()
|
protected void |
doStop()
|
void |
executeForIndex(CompassCallback callback)
Executes the given callback for index operations. |
void |
executeForMirror(CompassCallback callback)
Executes the given callback for mirror operations. |
Compass |
getIndexCompass()
Returns the Compass instance used for indexing. |
ResourceMapping |
getMappingForEntityForIndex(Class clazz)
Returns the mapping for the given class name when performing the index operation. |
ResourceMapping |
getMappingForEntityForIndex(String name)
Returns the mapping of the given name (alias or class name) when performing the index operation. |
Compass |
getMirrorCompass()
Returns the Compass instance used for mirroring. |
boolean |
hasMappingForEntityForIndex(Class clazz)
Returns true if there is mapping for the given class when
performing the index operation. |
boolean |
hasMappingForEntityForIndex(String name)
Returns true if there is mapping for the given name (alias
or class name) when performing the index operation. |
boolean |
hasMappingForEntityForMirror(Class clazz,
CascadeMapping.Cascade cascade)
Returns true if there is mapping for the given class when
performing the mirror operation. |
boolean |
hasMappingForEntityForMirror(String name,
CascadeMapping.Cascade cascade)
Returns true if there is mapping for the given name (alias
or class name) when performing the mirror operation. |
void |
setCompass(Compass compass)
Sets the compass instance that will be used with this Gps implementation. |
void |
setIndexProperties(Properties indexSettings)
Sets the additional cloned compass index settings. |
void |
setIndexSettings(CompassSettings indexSettings)
Sets the additional cloned compass index settings. |
void |
setIndexSettings(Map<String,Object> indexSettings)
Sets the additional cloned compass index settings. |
void |
setIndexSettings(Properties indexSettings)
Sets the additional cloned compass index settings. |
void |
setIndexTransactionIsolation(CompassTransaction.TransactionIsolation indexTransactionIsolation)
Sets the transaction isolation for the clones compass used for the index process. |
| Methods inherited from class org.compass.gps.impl.AbstractCompassGps |
|---|
addGpsDevice, finalize, getGpsDevice, getMappingForEntity, getRootMappingForEntity, getRootMappingForEntity, hasMappingForEntity, hasMappingForEntity, hasRootMappingForEntity, hasRootMappingForEntity, index, index, index, index, isPerformingIndexOperation, isRunning, refresh, setGpsDevices, start, stop |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SingleCompassGps()
public SingleCompassGps(Compass compass)
| Method Detail |
|---|
protected void doStart()
throws CompassGpsException
doStart in class AbstractCompassGpsCompassGpsException
protected void doStop()
throws CompassGpsException
doStop in class AbstractCompassGpsCompassGpsException
protected void doIndex(IndexPlan indexPlan)
throws CompassGpsException
doIndex in class AbstractCompassGpsCompassGpsException
public void executeForIndex(CompassCallback callback)
throws CompassException
CompassGpsInterfaceDevice
CompassException
public void executeForMirror(CompassCallback callback)
throws CompassException
CompassGpsInterfaceDevice
CompassException
public boolean hasMappingForEntityForIndex(Class clazz)
throws CompassException
CompassGpsInterfaceDevicetrue if there is mapping for the given class when
performing the index operation.
CompassException
public boolean hasMappingForEntityForIndex(String name)
throws CompassException
CompassGpsInterfaceDevicetrue if there is mapping for the given name (alias
or class name) when performing the index operation.
CompassException
public boolean hasMappingForEntityForMirror(Class clazz,
CascadeMapping.Cascade cascade)
throws CompassException
CompassGpsInterfaceDevicetrue if there is mapping for the given class when
performing the mirror operation.
CompassException
public boolean hasMappingForEntityForMirror(String name,
CascadeMapping.Cascade cascade)
throws CompassException
CompassGpsInterfaceDevicetrue if there is mapping for the given name (alias
or class name) when performing the mirror operation.
CompassException
public ResourceMapping getMappingForEntityForIndex(String name)
throws CompassException
CompassGpsInterfaceDevice
CompassException
public ResourceMapping getMappingForEntityForIndex(Class clazz)
throws CompassException
CompassGpsInterfaceDevice
CompassExceptionpublic Compass getIndexCompass()
CompassGpsInterfaceDeviceCompass instance used for indexing. Note that
no operations that will affect the index should be made using it, use
CompassGpsInterfaceDevice.executeForIndex(CompassCallback) operation instead.
public Compass getMirrorCompass()
CompassGpsInterfaceDeviceCompass instance used for mirroring. Note that
no operations that will affect the index should be made using it, use
CompassGpsInterfaceDevice.executeForMirror(CompassCallback) operation instead.
public void setCompass(Compass compass)
setIndexSettings(java.util.Properties)
for index operations.
public void setIndexTransactionIsolation(CompassTransaction.TransactionIsolation indexTransactionIsolation)
public void setIndexSettings(Properties indexSettings)
public void setIndexSettings(Map<String,Object> indexSettings)
public void setIndexProperties(Properties indexSettings)
public void setIndexSettings(CompassSettings indexSettings)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||