The Open Source Swiss Army Knife

/miscellany/alex/
/miscellany/alex/ + sub-categories
http://www.sirfsup.com/
web directory content
    
      

Not logged in
Chat Register Login
return to:  http:/www.sirfsup.com      /miscellany   /alex 
Permalink: client.cpp
Title: alexs files3
article options : please login   |  raw source view  

[b]This is a test to tell whether I really can edit the file this time!!![/b]

//////////////////////////////////////////////////////////////////////
#include <iostream.h>
#include "Client.h"

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

IMPLEMENT_SERIAL(CClient, CObject, 0)

void CClient::Serialize(CArchive& ar)
{
  CObject::Serialize (ar);

  if (ar.IsStoring())
    ar << mName << mGender << mAge;
  else
    ar >> mName >> mGender >> mAge;
}



CClient::CClient()
: mName("xxx"), mGender('X'), mAge(0)
{  }

CClient::~CClient()
{  }

void CClient::Input()
{
   char  name[20];

   cout << "\n Name   : "; cin >> name;
   mName = name;
   cout << " Gender : "; cin >> mGender;
   cout << " Age    : "; cin >> mAge;
   return;
}

void CClient::Display() const
{
  CString  s;
  s.Format ("%-10s  %c %d", mName, mGender, mAge);
  cout << s;
}

Leave a Reply
Your Name:     anonymous
Your Email:
Website:  
Comments:

The author will be notified of your reply.
return to top