#ifndef H_sphereType
#define H_sphereType
#include "circleType.h"
#include
using namespace std;
class sphereType : public circleType
{
public:
sphereType(double rad = 1.0);
//Constructor with one default parameter. Client assigned.
//Postcondition: if parameters are given: radius = r
// without parameters: radius = 1.0
// name is assigned "Sphere"
~sphereType();
//Destructor destroys any objects made, returns memory to the heap
double area() const;
//Function to return the surface area of a sphere
//Overrides the circle's area function.
//Postcondition: Surface area is calculated and returned.
double volume() const;
//Function to return the volume of a sphere
//Postcondition: Volume is calculated and returned.
double getHeight() const;
// Function to return the height of a sphere (really the same as diameter)
// Postcondition: height (diameter) is calculated and returned
void setHeight(double);
// set the height (diameter) of the sphere
// by setting the circle's radius = height / 2.0;
void print(ostream& ) const;
// function to override circle's print
// displays the radius, surface area, and volume
string getName() const;
// gets the name of the object
private:
string name;
};
#endif