org.eclipse.emf.emfstore.internal.client.configuration
Class Behavior

java.lang.Object
  extended by org.eclipse.emf.emfstore.internal.client.configuration.Behavior

public class Behavior
extends Object

Configuration options that influence the behavior of the client.

Author:
emueller, ovonwesen, mkoegel

Field Summary
static long NO_CHECKSUM
          The checksum value that is used in case no checksum should be computed.
 
Constructor Summary
Behavior()
           
 
Method Summary
 ESChecksumErrorHandler getChecksumErrorHandler()
          Returns the active ESChecksumErrorHandler.
 List<ServerInfo> getDefaultServerInfos()
          Get the default server info.
 boolean isAutoSaveEnabled()
          Whether auto-save is enabled.
 boolean isChecksumCheckActive()
          Whether the checksum check is active.
 Boolean isCutOffIncomingCrossReferencesActivated()
          Whether incoming cross references should be cut off.
 Boolean isDenyAddCutElementsToModelElementsFeatureActived()
          Whether cut elements are added automatically as regular model elements by default.
 Boolean isForceCommandsActived()
          Whether the usage of commands is enforced.
 Boolean isRerecordingActivated()
          Whether re-recording is enabled.
 void setAutoSave(boolean enabled)
          Whether to enable the automatic saving of the workspace.
 void setChecksumErrorHandler(ESChecksumErrorHandler errorHandler)
          Set the active ESChecksumErrorHandler.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NO_CHECKSUM

public static final long NO_CHECKSUM
The checksum value that is used in case no checksum should be computed.

See Also:
Constant Field Values
Constructor Detail

Behavior

public Behavior()
Method Detail

setAutoSave

public void setAutoSave(boolean enabled)
Whether to enable the automatic saving of the workspace. If disabled, performance improves vastly, but clients have to perform the saving of the workspace manually.

Parameters:
enabled - whether to enable auto save

isAutoSaveEnabled

public boolean isAutoSaveEnabled()
Whether auto-save is enabled.

Returns:
true, if auto-save is enabled, false otherwise

isRerecordingActivated

public Boolean isRerecordingActivated()
Whether re-recording is enabled.

Returns:
true, if re-recording is enabled, false otherwise

isCutOffIncomingCrossReferencesActivated

public Boolean isCutOffIncomingCrossReferencesActivated()
Whether incoming cross references should be cut off.

Returns:
Boolean.TRUE, if incoming cross references are cut off, Boolean.FALSE otherwise

isForceCommandsActived

public Boolean isForceCommandsActived()
Whether the usage of commands is enforced. Default is Boolean.FALSE.

Returns:
Boolean.TRUE, if usage of commands is enforced, Boolean.FALSE otherwise

isDenyAddCutElementsToModelElementsFeatureActived

public Boolean isDenyAddCutElementsToModelElementsFeatureActived()
Whether cut elements are added automatically as regular model elements by default.

Returns:
Boolean.TRUE, if cut elements are added automatically as regular elements, Boolean.FALSE otherwise

isChecksumCheckActive

public boolean isChecksumCheckActive()
Whether the checksum check is active. If true, and checksum comparison fails, an ESChecksumErrorHandler will be active.

Returns:
true, if the checksum comparison is activated, false otherwise

getChecksumErrorHandler

public ESChecksumErrorHandler getChecksumErrorHandler()
Returns the active ESChecksumErrorHandler. The default is ChecksumErrorHandler.AUTOCORRECT.

Returns:
the active checksum error handler

setChecksumErrorHandler

public void setChecksumErrorHandler(ESChecksumErrorHandler errorHandler)
Set the active ESChecksumErrorHandler.

Parameters:
errorHandler - the error handler to be set

getDefaultServerInfos

public List<ServerInfo> getDefaultServerInfos()
Get the default server info.

Returns:
server info


Copyright © 2015. All Rights Reserved.