circle.h

Go to the documentation of this file.
00001 #ifndef CIRCLE_CLASS
00002 #define CIRCLE_CLASS
00003 
00004 /*****************************************************************************\
00005 *                                                                             *
00006 *  Name   : circle                                                            *
00007 *  Author : Chris Koeritz                                                     *
00008 *                                                                             *
00009 *******************************************************************************
00010 * Copyright (c) 1992-$now By Author.  This program is free software; you can  *
00011 * redistribute it and/or modify it under the terms of the GNU General Public  *
00012 * License as published by the Free Software Foundation; either version 2 of   *
00013 * the License or (at your option) any later version.  This is online at:      *
00014 *     http://www.fsf.org/copyleft/gpl.html                                    *
00015 * Please send any updates to: fred@gruntose.com                               *
00016 \*****************************************************************************/
00017 
00018 #include "geometric_dll.h"
00019 
00020 namespace geometric {
00021 
00023 
00028 // forward.
00029 class cartesian_point;
00030 class cartesian_rectangle;
00031 class double_angle;
00032 
00033 class GEOMETRIC_CLASS_STYLE circle
00034 {
00035 public:
00036   circle();
00037   circle(double radius, const cartesian_point &center);
00038   ~circle();
00039 
00040   double area() const;
00042 
00043   double circumference() const;
00045 
00048   double diameter() const;
00050 
00053   bool inside(const cartesian_point &where) const;
00055 
00056   cartesian_point location(const double_angle &where) const;
00058 
00059   cartesian_rectangle dimensions() const;
00061 
00062   double radius() const;  
00063   void radius(double to_set);  
00064 
00065   cartesian_point center() const;  
00066   void center(const cartesian_point &to_set);  
00067 
00068 private:
00069   double _radius;  
00070   cartesian_point *_center;  
00071 };
00072 
00073 } // namespace.
00074 
00075 #endif
00076 

Generated on Fri Nov 28 04:29:14 2008 for HOOPLE Libraries by  doxygen 1.5.1