VR-Forces 4.0.4 Class Documentation
examples/addEntity/spacePar.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2004 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 /*******************************************************************************
00006 ** $RCSfile: spacePar.h,v $ $Revision: 1.11 $ $State: Exp $
00007 *******************************************************************************/
00008 
00009 
00010 //
00011 //File:        spacePar.h
00012 //
00013 //Class:       DtSpaceEntityParameters
00014 //
00015 //Description: This parameter class holds all of the parameters required by
00016 //space entities (entities having a state repository class of type
00017 //DtSpaceEntityStateRepository).  It contains a single the readable/writeable
00018 //parameter data members specific to space entities.  In this example, we add a
00019 //single new readable/writeable parameter, myMaxHullTemperature.
00020 
00021 #ifndef DtSpaceEntityParameters_H_
00022 #define DtSpaceEntityParameters_H_
00023 
00024 #include "vrfobjparam/mvObjParams.h"
00025 #include "vrfobjparam/vrfObjParams.h"
00026 #include "vrfobjcore/rwGndInter.h"
00027 
00028 
00029 class DtString;
00030 class DtReaderWriterRegistry;
00031 class DtVector;
00032 
00033 class DtSpaceEntityParameters : public DtMovingObjectParameters
00034 {
00035 public:
00036 
00037    //constructor with parameters to set up read/writability correctly
00038    DtSpaceEntityParameters(const DtString& name = DtString::nullString(), 
00039       DtReaderWriterRegistry* parentRegistry = NULL);
00040 
00041    //copy constructor
00042    DtSpaceEntityParameters(const DtSpaceEntityParameters& orig,
00043       const DtString& name, 
00044       DtReaderWriterRegistry* parentRegistry = NULL);
00045 
00046    const DtSpaceEntityParameters & operator=(const 
00047       DtSpaceEntityParameters& orig);
00048 
00049    //destructor
00050    virtual ~DtSpaceEntityParameters();
00051 
00052    //Returns new copy of this object
00053    virtual DtVrfObjectParameters* clone(
00054       const DtString& name = DtString::nullString(), 
00055       DtReaderWriterRegistry* parentRegistry = 0) const;
00056 
00057    //should return the type of entity this is a parameter block for.
00058    //Use the strings in paramTypes.h
00059    virtual DtString type() const;
00060 
00061    //Accessor/mutator for our new parameter, myMaxHullTemperature.
00062    //Set/get maximum hull temperature this entity can sustain.
00063    //In degrees Celsius.
00064    virtual void setMaxHullTemperature(DtReal temp);
00065    virtual DtReal maxHullTemperature() const;
00066 
00067    static DtVrfObjectParameters* creator();
00068 
00069 protected:
00070 
00071    DtRwReal myMaxHullTemperature;
00072 };
00073 
00074 #endif
00075 

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)