mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
finally, data hiding for the account group
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@679 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
f2aab8ba35
commit
24eaffd8fe
@ -30,6 +30,7 @@
|
|||||||
#include "Account.h"
|
#include "Account.h"
|
||||||
#include "AccountP.h"
|
#include "AccountP.h"
|
||||||
#include "Group.h"
|
#include "Group.h"
|
||||||
|
#include "GroupP.h"
|
||||||
#include "date.h"
|
#include "date.h"
|
||||||
#include "messages.h"
|
#include "messages.h"
|
||||||
#include "Transaction.h"
|
#include "Transaction.h"
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
/********************************************************************\
|
/********************************************************************\
|
||||||
* Account.h -- the Account data structure *
|
* Account.h -- the Account data structure *
|
||||||
* Copyright (C) 1997 Robin D. Clark *
|
* Copyright (C) 1997 Robin D. Clark *
|
||||||
|
* Copyright (C) 1997, 1998 Linas Vepstas *
|
||||||
* *
|
* *
|
||||||
* This program is free software; you can redistribute it and/or *
|
* This program is free software; you can redistribute it and/or *
|
||||||
* modify it under the terms of the GNU General Public License as *
|
* modify it under the terms of the GNU General Public License as *
|
||||||
|
@ -87,6 +87,7 @@
|
|||||||
#include "AccountP.h"
|
#include "AccountP.h"
|
||||||
#include "FileIO.h"
|
#include "FileIO.h"
|
||||||
#include "Group.h"
|
#include "Group.h"
|
||||||
|
#include "GroupP.h"
|
||||||
#include "messages.h"
|
#include "messages.h"
|
||||||
#include "TransactionP.h"
|
#include "TransactionP.h"
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
|
@ -28,6 +28,7 @@
|
|||||||
#include "Account.h"
|
#include "Account.h"
|
||||||
#include "AccountP.h"
|
#include "AccountP.h"
|
||||||
#include "Group.h"
|
#include "Group.h"
|
||||||
|
#include "GroupP.h"
|
||||||
#include "TransactionP.h"
|
#include "TransactionP.h"
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/********************************************************************\
|
/********************************************************************\
|
||||||
* Group.h -- the main data structure of the program *
|
* Group.h -- the main data structure of the program *
|
||||||
* Copyright (C) 1997 Robin D. Clark *
|
* Copyright (C) 1997 Robin D. Clark *
|
||||||
* Copyright (C) 1997 Linas Vepstas *
|
* Copyright (C) 1997, 1998 Linas Vepstas *
|
||||||
* *
|
* *
|
||||||
* This program is free software; you can redistribute it and/or *
|
* This program is free software; you can redistribute it and/or *
|
||||||
* modify it under the terms of the GNU General Public License as *
|
* modify it under the terms of the GNU General Public License as *
|
||||||
@ -30,22 +30,6 @@
|
|||||||
|
|
||||||
#include "Account.h"
|
#include "Account.h"
|
||||||
|
|
||||||
/** STRUCTS *********************************************************/
|
|
||||||
struct _account_group {
|
|
||||||
/* The flags: */
|
|
||||||
unsigned int saved : 1;
|
|
||||||
unsigned int new : 1;
|
|
||||||
|
|
||||||
Account *parent; /* back-pointer to parent */
|
|
||||||
|
|
||||||
int numAcc; /* number of accounts in array */
|
|
||||||
Account **account; /* array of account pointers */
|
|
||||||
|
|
||||||
/* cached parameters */
|
|
||||||
double balance;
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
/** PROTOTYPES ******************************************************/
|
/** PROTOTYPES ******************************************************/
|
||||||
AccountGroup *xaccMallocAccountGroup( void );
|
AccountGroup *xaccMallocAccountGroup( void );
|
||||||
void xaccFreeAccountGroup( AccountGroup *account_group );
|
void xaccFreeAccountGroup( AccountGroup *account_group );
|
||||||
|
58
src/engine/GroupP.h
Normal file
58
src/engine/GroupP.h
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
/*
|
||||||
|
* FILE:
|
||||||
|
* GroupP.h
|
||||||
|
*
|
||||||
|
* FUNCTION:
|
||||||
|
* This is the *private* account group structure.
|
||||||
|
* This header should *not* be included by any code outside of the
|
||||||
|
* engine.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
/********************************************************************\
|
||||||
|
* GroupP.h -- the main data structure of the program *
|
||||||
|
* Copyright (C) 1997 Robin D. Clark *
|
||||||
|
* Copyright (C) 1997, 1998 Linas Vepstas *
|
||||||
|
* *
|
||||||
|
* This program is free software; you can redistribute it and/or *
|
||||||
|
* modify it under the terms of the GNU General Public License as *
|
||||||
|
* published by the Free Software Foundation; either version 2 of *
|
||||||
|
* the License, or (at your option) any later version. *
|
||||||
|
* *
|
||||||
|
* This program is distributed in the hope that it will be useful, *
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||||
|
* GNU General Public License for more details. *
|
||||||
|
* *
|
||||||
|
* You should have received a copy of the GNU General Public License*
|
||||||
|
* along with this program; if not, write to the Free Software *
|
||||||
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *
|
||||||
|
* *
|
||||||
|
* Author: Rob Clark *
|
||||||
|
* Internet: rclark@cs.hmc.edu *
|
||||||
|
* Address: 609 8th Street *
|
||||||
|
* Huntington Beach, CA 92648-4632 *
|
||||||
|
\********************************************************************/
|
||||||
|
|
||||||
|
#ifndef __XACC_ACCOUNT_GROUP_P_H__
|
||||||
|
#define __XACC_ACCOUNT_GROUP_P_H__
|
||||||
|
|
||||||
|
#include "config.h"
|
||||||
|
#include "Transaction.h"
|
||||||
|
|
||||||
|
/** STRUCTS *********************************************************/
|
||||||
|
struct _account_group {
|
||||||
|
/* The flags: */
|
||||||
|
unsigned int saved : 1;
|
||||||
|
unsigned int new : 1;
|
||||||
|
|
||||||
|
Account *parent; /* back-pointer to parent */
|
||||||
|
|
||||||
|
int numAcc; /* number of accounts in array */
|
||||||
|
Account **account; /* array of account pointers */
|
||||||
|
|
||||||
|
/* cached parameters */
|
||||||
|
double balance;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif /* __XACC_ACCOUNT_GROUP_P_H__ */
|
@ -23,6 +23,7 @@
|
|||||||
#include "Account.h"
|
#include "Account.h"
|
||||||
#include "AccountP.h"
|
#include "AccountP.h"
|
||||||
#include "Group.h"
|
#include "Group.h"
|
||||||
|
#include "GroupP.h"
|
||||||
#include "Transaction.h"
|
#include "Transaction.h"
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
|
|
||||||
|
@ -36,7 +36,9 @@
|
|||||||
#include "Account.h"
|
#include "Account.h"
|
||||||
#include "AccountP.h"
|
#include "AccountP.h"
|
||||||
#include "Group.h"
|
#include "Group.h"
|
||||||
|
#include "GroupP.h"
|
||||||
#include "FileIO.h"
|
#include "FileIO.h"
|
||||||
|
#include "Transaction.h"
|
||||||
#include "TransactionP.h"
|
#include "TransactionP.h"
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user