card.cpp

/*

Programmer: Jennifer Leopold

Date: April 6, 2018

File: card.cpp

Purpose: This file contains the definitions of the functions

for the Card class.

*/

#include "card.h"

using namespace std;

Card::Card()

{

m_rescueSymbol = DEFAULT_RESCUE_SYMBOL;

m_danger = "";

m_number = 0;

m_saying = "";

}

Card::Card(const unsigned int theNumber, const string theSaying,

const string theDanger, const Rescue theRescueSymbol)

{

m_rescueSymbol = theRescueSymbol;

m_danger = theDanger;

m_number = theNumber;

m_saying = theSaying;

}

ostream& operator << (ostream& outs, const Card& c)

{

outs << c.getNumber() << "|"

<< c.getSaying() << "|"

<< c.getDanger() << "|"

<< RescueToString(c.getRescueSymbol());

return(outs);

}