<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>HippoDraw Class Library</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> <link href="tabs.css" rel="stylesheet" type="text/css"> <link rel="shortcut icon" href="hippoApp.ico"> </head><body> <!-- Generated by Doxygen 1.6.2 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> <li><a href="dirs.html"><span>Directories</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>File Members</span></a></li> </ul> </div> <div class="navpath"><a class="el" href="dir_974d432048ef135a7d3fc83794dbf3e9.html">binners</a> </div> </div> <div class="contents"> <h1>BinnerAxisFactory.cxx</h1><a href="BinnerAxisFactory_8cxx.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span> <a name="l00002"></a>00002 <span class="comment"> * HippoPlot BinnerAxisFactory class implementation</span> <a name="l00003"></a>00003 <span class="comment"> *</span> <a name="l00004"></a>00004 <span class="comment"> * Copyright (C) 2003 The Board of Trustees of The Leland Stanford</span> <a name="l00005"></a>00005 <span class="comment"> * Junior University. All Rights Reserved.</span> <a name="l00006"></a>00006 <span class="comment"> *</span> <a name="l00007"></a>00007 <span class="comment"> * $Id: BinnerAxisFactory.cxx,v 1.4 2005/10/30 00:10:09 pfkeb Exp $</span> <a name="l00008"></a>00008 <span class="comment"> *</span> <a name="l00009"></a>00009 <span class="comment"> */</span> <a name="l00010"></a>00010 <a name="l00011"></a>00011 <span class="comment">// for truncation warning in debug mode</span> <a name="l00012"></a>00012 <span class="preprocessor">#ifdef _MSC_VER</span> <a name="l00013"></a>00013 <span class="preprocessor"></span><span class="preprocessor">#include "msdevstudio/MSconfig.h"</span> <a name="l00014"></a>00014 <span class="preprocessor">#endif</span> <a name="l00015"></a>00015 <span class="preprocessor"></span> <a name="l00016"></a>00016 <span class="preprocessor">#include "<a class="code" href="BinnerAxisFactory_8h.html">BinnerAxisFactory.h</a>"</span> <a name="l00017"></a>00017 <a name="l00018"></a>00018 <span class="comment">// List of default Binner container objects</span> <a name="l00019"></a>00019 <span class="preprocessor">#include "<a class="code" href="BinnerAxisLinear_8h.html" title="hippodraw::BinnerAxisLinear class interface">BinnerAxisLinear.h</a>"</span> <a name="l00020"></a>00020 <span class="preprocessor">#include "<a class="code" href="BinnerAxisLog_8h.html" title="hippodraw::BinnerAxisLog class interface">BinnerAxisLog.h</a>"</span> <a name="l00021"></a>00021 <a name="l00022"></a>00022 <span class="keyword">namespace </span>hippodraw { <a name="l00023"></a>00023 <a name="l00024"></a>00024 BinnerAxisFactory * <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a6830689780c37f5e564850011e7f17a9" title="A pointer to the singleton object.">BinnerAxisFactory::s_instance</a> = 0; <a name="l00025"></a><a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a3115c9c7a4864934f23f0d028b372abb">00025</a> <a name="l00026"></a>00026 <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a3115c9c7a4864934f23f0d028b372abb" title="A default constructor for prevent creation except by the itself or the derived classes...">BinnerAxisFactory::BinnerAxisFactory</a> () <a name="l00027"></a>00027 { <a name="l00028"></a>00028 } <a name="l00029"></a><a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#ac92fc653c73939b8f62963318215acd2">00029</a> <a name="l00030"></a>00030 <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html" title="A Factory singleton class for creating objects whose class derives from BinnerAxis...">BinnerAxisFactory</a> * <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#ac92fc653c73939b8f62963318215acd2" title="Returns a pointer to the singleton instance.">BinnerAxisFactory::instance</a> () <a name="l00031"></a>00031 { <a name="l00032"></a>00032 <span class="keywordflow">if</span> ( <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a6830689780c37f5e564850011e7f17a9" title="A pointer to the singleton object.">s_instance</a> == 0 ) { <a name="l00033"></a>00033 <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a6830689780c37f5e564850011e7f17a9" title="A pointer to the singleton object.">s_instance</a> = <span class="keyword">new</span> <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a3115c9c7a4864934f23f0d028b372abb" title="A default constructor for prevent creation except by the itself or the derived classes...">BinnerAxisFactory</a> (); <a name="l00034"></a>00034 <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a6830689780c37f5e564850011e7f17a9" title="A pointer to the singleton object.">s_instance</a>-><a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a25a40b6614565f755233080a384c35f1" title="Initializes the factory with a set of default functions.">initialize</a> (); <a name="l00035"></a>00035 } <a name="l00036"></a>00036 <span class="keywordflow">return</span> <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a6830689780c37f5e564850011e7f17a9" title="A pointer to the singleton object.">s_instance</a>; <a name="l00037"></a>00037 } <a name="l00038"></a><a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a25a40b6614565f755233080a384c35f1">00038</a> <a name="l00039"></a>00039 <span class="keywordtype">void</span> <a class="code" href="classhippodraw_1_1BinnerAxisFactory.html#a25a40b6614565f755233080a384c35f1" title="Initializes the factory with a set of default functions.">BinnerAxisFactory::initialize</a> () <a name="l00040"></a>00040 { <a name="l00041"></a>00041 <a class="code" href="classhippodraw_1_1Factory.html#a8aee137075d50e6fca916a1dbfd388c3" title="Adds a prototype object to the list of prototypes.">add</a> ( <span class="keyword">new</span> <a class="code" href="classhippodraw_1_1BinnerAxisLinear.html" title="The class for the constant width bins.">BinnerAxisLinear</a> () ); <a name="l00042"></a>00042 <a class="code" href="classhippodraw_1_1Factory.html#a8aee137075d50e6fca916a1dbfd388c3" title="Adds a prototype object to the list of prototypes.">add</a> ( <span class="keyword">new</span> <a class="code" href="classhippodraw_1_1BinnerAxisLog.html" title="The class for bins of logarithmically increasing widths.">BinnerAxisLog</a> () ); <a name="l00043"></a>00043 } <a name="l00044"></a>00044 <a name="l00045"></a>00045 } <span class="comment">// namespace hippodraw</span> </pre></div></div> <hr size="1"><address style="align: right;"><small> Generated for HippoDraw Class Library by <a href="http://www.doxygen.org/index.html"> <img src="doxygen.png" alt="doxygen" align="middle" border=0> </a> </small></address> </body> </html>