openlsd.appli.admin.commoncopy
Class LSDCopyAbstract

java.lang.Object
  extended by openlsd.appli.admin.commoncopy.LSDCopyAbstract
Direct Known Subclasses:
LSDGetCopy

public abstract class LSDCopyAbstract
extends java.lang.Object

Simple class that shared common things and methods between copyers

Author:
Frederic BREGIER LGPL 2007

Field Summary
protected  LSDDbAdmin admin
          DB Admin Object
protected  LSDExtDbDocument document
          DB Document Object
protected  java.io.FileWriter fileErrWriter
          File error out
protected  java.lang.String filepath
          Original source file
protected  java.io.FileWriter fileWriter
          File out
protected  LSDDbIpPort ipportAdm
          IpPort Object
protected  LSDClientInfo lci
          Client Info Object
protected  LSDDbLegacy legacy
          DB Legacy Object
protected  long lid
          Legacy ID
protected  LSDBusiness lsdb
          String identifying one specific document in one legacy : Business object
 
Constructor Summary
LSDCopyAbstract(LSDLoadConfig llc)
          Create a new LSDCopyAbstract object
 
Method Summary
protected  void copyDocument()
          Truely copy the document in LSD then in DB
 int initCopy(java.lang.String[] args, int curargs, boolean keepalived)
          Init Copy context except file listing itself
 boolean runCopy(java.lang.String filepath)
          Run Copy from the file containing list of id Business
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

admin

protected LSDDbAdmin admin
DB Admin Object


legacy

protected LSDDbLegacy legacy
DB Legacy Object


document

protected LSDExtDbDocument document
DB Document Object


lid

protected long lid
Legacy ID


lsdb

protected LSDBusiness lsdb
String identifying one specific document in one legacy : Business object


ipportAdm

protected LSDDbIpPort ipportAdm
IpPort Object


lci

protected LSDClientInfo lci
Client Info Object


filepath

protected java.lang.String filepath
Original source file


fileWriter

protected java.io.FileWriter fileWriter
File out


fileErrWriter

protected java.io.FileWriter fileErrWriter
File error out

Constructor Detail

LSDCopyAbstract

public LSDCopyAbstract(LSDLoadConfig llc)
Create a new LSDCopyAbstract object

Parameters:
llc -
Method Detail

initCopy

public int initCopy(java.lang.String[] args,
                    int curargs,
                    boolean keepalived)
Init Copy context except file listing itself

Parameters:
args -
curargs -
keepalived -
Returns:
Next curargs or -1 if in error

runCopy

public boolean runCopy(java.lang.String filepath)
Run Copy from the file containing list of id Business

Parameters:
filepath -
Returns:
True if OK, else False

copyDocument

protected void copyDocument()
Truely copy the document in LSD then in DB