net.datacrow.synchronizers
Class Synchronizer

java.lang.Object
  extended by net.datacrow.synchronizers.Synchronizer
Direct Known Subclasses:
DefaultSynchronizer

public abstract class Synchronizer
extends java.lang.Object


Field Summary
static int _ALL
           
static int _SELECTED
           
protected  ISynchronizerClient client
           
protected  int module
           
 
Constructor Summary
Synchronizer(java.lang.String title, int module)
           
 
Method Summary
abstract  boolean canParseFiles()
           
abstract  boolean canUseOnlineServices()
           
 java.lang.String getHelpIndex()
           
abstract  java.lang.String getHelpText()
           
abstract  java.lang.Thread getTask()
           
 java.lang.String getTitle()
           
 void merge(DcObject target, DcObject source)
          Merges the data of the source and the target with regard of the settings.
protected  void merge(DcObject target, DcObject source, OnlineSearchHelper osh)
          Merges the data of the source and the target with regard of the settings.
abstract  boolean onlineUpdate(ISynchronizerClient client, DcObject dco)
           
protected  boolean parseFiles(DcObject dco)
          Executed before the online update.
protected  void setValue(DcObject dco, int field, java.lang.Object value)
           
 void synchronize(ISynchronizerClient client)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

client

protected ISynchronizerClient client

_ALL

public static final int _ALL
See Also:
Constant Field Values

_SELECTED

public static final int _SELECTED
See Also:
Constant Field Values

module

protected final int module
Constructor Detail

Synchronizer

public Synchronizer(java.lang.String title,
                    int module)
Method Detail

getTask

public abstract java.lang.Thread getTask()

getHelpText

public abstract java.lang.String getHelpText()

canParseFiles

public abstract boolean canParseFiles()

canUseOnlineServices

public abstract boolean canUseOnlineServices()

getTitle

public java.lang.String getTitle()

getHelpIndex

public java.lang.String getHelpIndex()

onlineUpdate

public abstract boolean onlineUpdate(ISynchronizerClient client,
                                     DcObject dco)

parseFiles

protected boolean parseFiles(DcObject dco)
Executed before the online update.

Parameters:
dco -

merge

public void merge(DcObject target,
                  DcObject source)
Merges the data of the source and the target with regard of the settings.


merge

protected void merge(DcObject target,
                     DcObject source,
                     OnlineSearchHelper osh)
Merges the data of the source and the target with regard of the settings. The online search helper is used to query additional data when needed.


synchronize

public void synchronize(ISynchronizerClient client)

setValue

protected void setValue(DcObject dco,
                        int field,
                        java.lang.Object value)