All pastes #1272036 Raw Edit

Siddharth Dahiya

public text v1 · immutable
#1272036 ·published 2008-12-01 05:37 UTC
rendered paste body
/******************************************************
*                                                     *
*  Professor                 Lloyd Parker             *
*  Course:                   OOP244                   *
*  Assignment:               3                        *
*  Student:                  Siddharth Dahiya         *
*  Student #:                016-194-086              *
*  Student userid:           sdahiya1                 *
*  This File Name:           Account.h                *
*                                                     *
*******************************************************
*                                                     *
*  This assignment represents my own work in          *
*  accordance with Seneca Academic Policy             *
*                                                     *
*       Signature: Siddharth Dahiya                   *
*******************************************************

Header file for Account class. */
class Account 
{
	char * customer; // Null-terminated character array, 250 characters max, excluding '\0'.
	char accountNumber[16]; // Null-terminated character array, 15 characters max, exculding '\0'.
	int balance; // an Integer.
	
	//Function to clean excess whitespace, new lines, and horizontal tabs.
	void cleanSpace(char s[]); // remove cleanSpace.
	
    public:
	//Constructor of Account
	Account();

	Account(const Account& );
	
	//ac pointer to Account object, similar to 'customer'.
	void init(const char c[], char num[], int b);	

	//Constructor for cleaning excess whitespace
	Account(const char c[], char num[], int b);
	
	//Clean Customer array
	void changeCustomerInfo( const char c[] );
	
	//Change the Account Number of the Customer
	void changeAccountNumber( const char num[] );
		
	//Change the Balance of the customer
	void changeBalance(int b);
	
	//Get the account number of the customer
	void getAccountNumber(char st[]);
	
    //Get Last Name of the Customer
	void getLastName(char st[]);
	
	//Get First Name of the Customer
	void getFirstName(char st[]);
	
	//Get The Customer's city
	void getCity(char st[]);
	
	//Get Customer Phone Number
	void getPhoneNumber(char st[]);
	
	//Constant to return the address of data in Customer.
	const char* getCustomer() const;
	
	//Constant to return the address of data in Account Number.
	const char* getAccountNumber() const;
	
	//Constant to return the value of Balance.
	int getBalance() const; 
	
	//Overloaded Assignment operator to copy account details from left side to the right side
	const Account& operator=(const Account& );

	//Destructor to clean up everything
	~Account();		
};