// Name: Sean Smith // Class and Section: CS 54, Section // Date: April 17, 2007 // Purpose: Definitions for the different bands for the templated Radio #ifndef BANDS_H #define BANDS_H #include #include using namespace std; /* 24, 32, 48, 64, 96, 128, 192, 256, 320 kbps */ const int NUM_BITRATES = 9; const int validBitRates[NUM_BITRATES] = {24576, 32768, 49152, 65536, 98304, 131072, 196608, 262144, 327680}; class AM { public: AM(); AM(int newFrequency, bool newStereo); bool inStereo() const; int getFrequency() const; void print() const; void setFrequency(int newFrequency); void setStereo(bool newStereo); private: int frequency; bool stereo; }; class FM { public: FM(); FM(double newFrequency, bool newStereo); bool inStereo() const; double getFrequency() const; void print() const; void setFrequency(double newFrequency); void setStereo(bool newStereo); private: double frequency; bool stereo; }; class IceCast { public: IceCast(); IceCast(string newURL, int newBitRate); int getBitRate() const; string getURL() const; void print() const; void setBitRate(int newBitRate); void setURL(string newURL); private: string url; int bitRate; }; #endif