d17c842cdc
git-svn-id: svn://10.65.10.50/trunk@193 c028cbd2-c16b-5b4b-a496-9718f37d4682
52 lines
1.6 KiB
C++
Executable File
52 lines
1.6 KiB
C++
Executable File
#ifndef __CG2101_H
|
|
#define __CG2101_H
|
|
|
|
#ifndef __RELATION_H
|
|
#include <relation.h>
|
|
#endif
|
|
|
|
int date2esc(const TDate& d, int* prevesc = NULL);
|
|
|
|
class TMovimentoPN : public TRelation
|
|
{
|
|
// class TMovimentoPN : public TRelation
|
|
// @END
|
|
|
|
// @DPRIV
|
|
TArray _cg, _iva;
|
|
int _oldcg, _oldiva;
|
|
real _balance;
|
|
// @END
|
|
|
|
protected:
|
|
// @FPROT
|
|
int write_rec(bool re, const TRectype&r, TLocalisamfile* f);
|
|
int cancella(TLocalisamfile* f, int da, int a);
|
|
int registra(bool re, bool force);
|
|
int read_mov_rows();
|
|
// @END
|
|
|
|
public:
|
|
// @FPUB
|
|
virtual int next(TReclock lockop = _nolock) { return (file()->next(lockop) || read_mov_rows()); }
|
|
virtual int prev(TReclock lockop = _nolock) { return (file()->prev(lockop) || read_mov_rows()); }
|
|
virtual int first(TReclock lockop = _nolock) { return (file()->first(lockop) || read_mov_rows()); }
|
|
virtual int last(TReclock lockop = _nolock) { return (file()->last(lockop) || read_mov_rows()); }
|
|
virtual int skip(TRecnotype nrec, TReclock lockop = _nolock) { return (file()->skip(nrec, lockop) || read_mov_rows()); }
|
|
virtual int read(TIsamop op = _isgteq, TReclock lockop = _nolock, TDate& atdate = (TDate&)botime);
|
|
virtual int write (bool force = TRUE, TDate& atdate = (TDate&)botime);
|
|
virtual int rewrite(bool force = TRUE, TDate& atdate = (TDate&)botime);
|
|
virtual int remove (TDate& atdate = (TDate&)botime);
|
|
|
|
TRectype& cg(int i);
|
|
TRectype& iva(int i);
|
|
int cg_items() const { return _cg.items(); }
|
|
int iva_items() const { return _iva.items(); }
|
|
void destroy_rows();
|
|
|
|
TMovimentoPN();
|
|
virtual ~TMovimentoPN() {}
|
|
};
|
|
|
|
#endif
|