FastCGIApplication.h

Go to the documentation of this file.
00001 /* -*- c++ -*-
00002  * $Id: FastCGIApplication.h,v 1.8 2006/05/16 20:12:15 brook Exp $
00003  */
00004 
00005 /*
00006  * ClearSilver++ Software License.
00007  *
00008  * Copyright (c) 2006 Brook Milligan <brook@nmsu.edu>
00009  * All rights reserved.
00010  * 
00011  * Redistribution and use in source and binary forms, with or without
00012  * modification, are permitted provided that the following conditions
00013  * are met:
00014  * 
00015  * 1. Redistributions of source code must retain the above copyright
00016  *    notice, this list of conditions and the following disclaimer.
00017  * 2. Redistributions in binary form must reproduce the above
00018  *    copyright notice, this list of conditions and the following
00019  *    disclaimer in the documentation and/or other materials provided
00020  *    with the distribution.
00021  * 3. The name of the author may not be used to endorse or promote
00022  *    products derived from this software without specific prior
00023  *    written permission.
00024  * 
00025  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
00026  * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
00027  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
00028  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
00029  * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
00030  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
00031  * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
00032  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
00033  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
00034  * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
00035  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00036  */
00037 
00038 /*
00039  * Note: The inspiration for creating a FastCGI application using the
00040  * CGI and HDF classes came from Gerald Dachs <gda@gmx.de>.  His
00041  * example implementation provided the basis for designing this
00042  * FastCGIApplication framework.
00043  */
00044 
00050 #ifndef FastCGIApplication_h_
00051 #define FastCGIApplication_h_ 1
00052 
00053 #include <boost/shared_ptr.hpp>
00054 #include "CGIApplication.h"
00055 #include "TraceObject.h"
00056 
00057 namespace ClearSilver
00058 {
00059 
00093   class FastCGIApplication : ClearSilver::TraceObject
00094   {
00095   public:
00097     //\{
00098     typedef boost::shared_ptr<FastCGIApplication> Ptr;
00099     //\}
00100 
00101   public:
00103     //\{
00104                                 // constructors
00106     FastCGIApplication ();
00108     explicit FastCGIApplication (CGIApplication::Ptr);
00110     explicit FastCGIApplication (CGIApplication::Ptr, const HDF&);
00112     FastCGIApplication (const FastCGIApplication&);
00114     virtual ~FastCGIApplication () throw();
00115 
00117     FastCGIApplication& operator = (const FastCGIApplication&);
00119     void swap (FastCGIApplication&) throw();
00120     //\}
00121 
00138     virtual void operator () ();
00139 
00141     CGIApplication::Ptr cgi () const;
00142 
00144     HDF hdf ();
00145 
00152   static bool& debug ();
00153 
00154   private:
00155     CGIApplication::Ptr cgi_;
00156     HDF hdf_;
00157   };
00158 
00159 };                              // namespace ClearSilver
00160 
00161 #endif

Generated on Tue May 16 14:50:52 2006 for ClearSilver C++ Library by  doxygen 1.4.5