CONVERT_PROC

Top  Previous  Next

typedef struct CONVERT_PROC {

int len;

struct CONVERT_PROC *next;

char *formatName;

void *params;

LONG (DLLENTRY *cv_getReadParamsOnce) (int argc,

char *argv [],

struct CONVERT_PROC *dataBlock);

LONG (DLLENTRY *cv_getReadParamsRepeated) (

int argc,

char *argv [],

struct CONVERT_PROC *dataBlock,

char *name,

char *pfad);

PPLANS (DLLENTRY *cv_readProject) (

int argc,

char *argv [],

struct CONVERT_PROC *dataBlock,

char *name,

char *pfad,

int write,

PROOT root,

char *source,

PPLANS flat,

int flags,

OBJECT_GROUP_DESCRIPTION *objects,

PLAN_SETTINGS *plSet,

char *identity);

LONG (DLLENTRY *cv_unlockProject) (PPLANS flat, int flags);

LONG (DLLENTRY *cv_lockProject) (PPLANS flat, int flags);

char *comment;

LONG (DLLENTRY *cv_getSaveParams) (

int argc,

char *argv [],

struct CONVERT_PROC *dataBlock,

PPLANS flat);

LONG (DLLENTRY *cv_saveProject) (

int argc,

char *argv [],

struct CONVERT_PROC *dataBlock,

PPLANS flat,

PROOT root,

char *newName,

char *newPath,

int flags);

LONG (DLLENTRY *cv_enumProjects) (

char *pfad,

struct CONVERT_PROC *dataBlock,

PROOT root,

int (DLLENTRY *actionProc) (

PLAN_SETTINGS* pSet,

void *params, PROOT root),

void *params,

char *muster,

int flags,

PSEGMENT segment);

int flags;//CONVERT_FLAGS_HAS_RIGHTS = 1

//CONVERT_FLAGS_LOAD_SELECTIV =2

LONG (DLLENTRY *cv_updateProject) (

int argc,

char *argv [],

struct CONVERT_PROC *dataBlock,

PLAN_SETTINGS *plSet,

int flags,

struct CONVERTobjectList *objects);

LONG (DLLENTRY *cv_exportProject) (

int argc,

char *argv [],

struct CONVERT_PROC *dataBlock,

PPLANS flat,

PROOT root,

POBJECT *objListe,

PLAN_SETTINGS *plSet,

int flags);

LONG (DLLENTRY *cv_commitOrRollback) (

struct CONVERT_PROC *dataBlock,

PROOT root,

int flags,

int doCommitNotRollback);

} CONVERT_PROC;

 

len (int)

Size of the structure in byte. Through this it is identified which version of the structure exists.

next struct CONVERT_PROC *)

Pointer on the next data format. If a DLL serves several data formats, these are exported as a list. Moskito chains, in addition, with the store all data formats.

formatName (char *)

Name of the data format. This string is used with the store and memories. In addition, he is used as a file ending if the format provides no enum function.

params (void *)

for the internal use by the converter.

cv_getReadParamsOnce (procedure pointers)

Serves the query of parametre values before the reading of data. The routine is called once for the whole data format.

 

Parametre

argc (int)

Number of the parametres by the call of the user function for this call. With it the user can give special parametres for a data converter.

badly (char **)

Text field with the parametres (see argc).

dataBlock (struct CONVERT_PROC *)

Pointer on the block with the procedure pointers for this format.

 

Result

(long int)

up to now without meaning

cv_getReadParamsRepeated (procedure pointer)

Serves the query of parametre values before the reading of data. The routine is called before every project / plan.

 

Parametre

argc (int)

Number of the parametres by the call of the user function for this call. With it the user can give special parametres for a data converter.

badly (char **)

Text field with the parametres (see argc).

dataBlock (struct CONVERT_PROC *)

Pointer on the block with the procedure pointers for this format.

name (char *)

Name of the file which should be read.

pfad (char *)

Path of the file which should be read. Path and name prove together the whole file name. However, this can also stand completely in one of both variables.

 

Result

(long int)

up to now without meaning

cv_readProject (procedure pointer)

The function must be called to load a plan or a project in the field of work.

 

Parametre

argc (int)

Number of the parametres by the call of the user function for this call. With it the user can give special parametres for a data converter.

badly (char **)

Text field with the parametres (see argc).

dataBlock (struct CONVERT_PROC *)

Pointer on the block with the procedure pointers for this format.

name (char *)

Name of the file which should be read.

pfad (char *)

Path of the file which should be read. Path and name prove together the whole file name. However, this can also stand completely in one of both variables.

write (int)

TRUE:: The plan should be writing loaded.

FALSE: The plan should be opened only with reading authorisation.

root (PROOT)

Act to the data bank.

source (char *)

Name of the file from which the plan should be read. It is used only if the plan is imported, stands so at another place than he should be stored away behind again.

flat (PPLANS)

Act of a plan to which the data should be added, or

Act of the segment in which the plan should be put on, or

Act to the data bank.

flags (int)

The counters which influence the behaviour with the store:

FLAG_PROJECTS_READ_NEED_WRITE The plan must be writing loaded. If this is not possible the loading should be broken off.

objects (OBJECT_GROUP_DESCRIPTION *)

List of the object types it should be loaded.

plSet (PLAN_SETTINGS *)

The qualities of the loaded plan are filed here, even if the plan became another hinzugeladen.

identity (char)

Name of the project which should be loaded. Under this name the project is later in the locomotive files can be found.

 

Result

PPLANS

The ZERO if no plan could be loaded,

the trading of the plan if this was correctly loaded.

cv_unlockProject (procedure pointer)

With this procedure a plan which is closed on grounds of a mistake against writers can become again entsperrt.

 

Parametre

Plan (PPLANS)

The trading of the plan which should become entsperrt.

Flags (int)

Books. Always 0.

 

Result

LONG

0 in the successful case,

but a mistake number.

cv_lockProject (procedure pointer)

With this procedure can be closed a plan which is not closed on grounds of a mistake against writers.

 

Parametre

Plan (PPLANS)

The trading of the plan which should be closed.

Flags (int)

Books. Always 0.

 

Result

LONG

0 in the successful case,

but a mistake number.

comment (char *)

Description is absent.

cv_getSaveParams (procedure pointer)

Description is absent.

 

Parametre

argc (int)

Number of the arguments in the command line.

argv [] (char *)

Field of sign chains. The number is determined by argc.

dataBlock (struct CONVERT_PROC *)

Description is absent.

flat (PPLANS)

Description is absent.

 

Result

LONG

0 in the successful case,

but a mistake number.

cv_saveProject (procedure pointer)

Description is absent.

 

Parametre

argc (int)

Number of the parametres in the command line.

argv [] (char *)

Field of sign chains. Number is determined from argc.

dataBlock (struct CONVERT_PROC *)

Description is absent.

flat (PPLANS)

Description is absent.

root (PROOT)

Pointer on the open data bank.

newName (char *)

Field of sign chains. Number is determined from argc.

newPath (char *)

Field of sign chains. Number is determined from argc.

flags (int)

Field of sign chains. Number is determined from argc.

 

Result

LONG

0 in the successful case,

but a mistake number.

cv_enumProjects (procedure pointer)

Description is absent.

 

Parametre

pfad (char *)

Sign chain the path of the project brags.

dataBlock (struct CONVERT_PROC *)

Description is absent.

root (PROOT)

Act on the open data bank.

actionProc (procedure pointer)

Parametre

pSet (PLAN_SETTINGS *)

params (void *)

root (PROOT)

Result

int

params (void *)

Description is absent.

muster (char *)

Description is absent.

flags (int)

Description is absent.

Segment (PSEGMENT)

Pointer on the segment in which flat should be loaded later. If ZERO is given here, some data formats cannot be loaded.

 

Result

LONG

0 in the successful case,

but a mistake number.

flags (int) //CONVERT_FLAGS_HAS_RIGHTS = 1

//CONVERT_FLAGS_LOAD_SELECTIV =2

cv_updateProject (procedure pointer)

Description is absent.

 

Parametre

argc (int)

Number of the arguments in the command line.

argv [] (char *)

Field of sign chains. Number is determined by argc.

dataBlock (struct CONVERT_PROC *)

Param description

plSet (PLAN_SETTINGS *)

Param description

flags (int)

Param description

objects (struct CONVERTobjectList *)

Param description

 

Result

LONG

0 in the successful case,

but a mistake number.

cv_exportProject (procedure pointer)

Description is absent.

 

Parametre

argc (int)

Number of the arguments in the command line.

argv [] (char *)

Field of sign chains. Number is determined by argc.

dataBlock (struct CONVERT_PROC *)

Param description

flat (PPLANS)

Param description

root (PROOT)

Act on the open data bank.

objList (POBJECT *)

Act on a list of objects.

plSet (PLAN_SETTINGS *)

Param description

flags (int)

Param description

 

Result

LONG

0 in the successful case,

but a mistake number.

//Call occurs if the changes are protected in all plans and is certain, whether Commit or rolling forecastle

 

cv_commitOrRollback (procedure pointer)

Description is absent.

 

Parametre

dataBlock (struct CONVERT_PROC *)

Param description

root (PROOT)

Act on the open data bank.

flags (int)

Param description

doCommitNotRollback (int)

Param description

 

Result

LONG

0 in the successful case,

but a mistake number.