Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

CEGUIPropertySet.h

Go to the documentation of this file.
00001 /************************************************************************
00002         filename:       CEGUIPropertySet.h
00003         created:        21/2/2004
00004         author:         Paul D Turner
00005         
00006         purpose:        Defines interface for the PropertySet class
00007 *************************************************************************/
00008 /*************************************************************************
00009     Crazy Eddie's GUI System (http://www.cegui.org.uk)
00010     Copyright (C)2004 - 2005 Paul D Turner (paul@cegui.org.uk)
00011 
00012     This library is free software; you can redistribute it and/or
00013     modify it under the terms of the GNU Lesser General Public
00014     License as published by the Free Software Foundation; either
00015     version 2.1 of the License, or (at your option) any later version.
00016 
00017     This library is distributed in the hope that it will be useful,
00018     but WITHOUT ANY WARRANTY; without even the implied warranty of
00019     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00020     Lesser General Public License for more details.
00021 
00022     You should have received a copy of the GNU Lesser General Public
00023     License along with this library; if not, write to the Free Software
00024     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00025 *************************************************************************/
00026 #ifndef _CEGUIPropertySet_h_
00027 #define _CEGUIPropertySet_h_
00028 
00029 #include "CEGUIBase.h"
00030 #include "CEGUIString.h"
00031 #include "CEGUIIteratorBase.h"
00032 #include "CEGUIProperty.h"
00033 #include <map>
00034 
00035 
00036 #if defined(_MSC_VER)
00037 #       pragma warning(push)
00038 #       pragma warning(disable : 4251)
00039 #endif
00040 
00041 // Start of CEGUI namespace section
00042 namespace CEGUI
00043 {
00048 class CEGUIEXPORT PropertySet : public PropertyReceiver
00049 {
00050 public:
00055         PropertySet(void) {}
00056 
00057 
00062         virtual ~PropertySet(void) {}
00063 
00064 
00078         void    addProperty(Property* property);
00079 
00080 
00091         void    removeProperty(const String& name);
00092 
00093 
00101         void    clearProperties(void);
00102 
00103 
00114         bool    isPropertyPresent(const String& name) const;
00115 
00116 
00129         const String&   getPropertyHelp(const String& name) const;
00130 
00131 
00144         String  getProperty(const String& name) const;
00145 
00146 
00163         void    setProperty(const String& name, const String& value);
00164 
00165 
00177         bool    isPropertyDefault(const String& name) const;
00178 
00179 
00190         String  getPropertyDefault(const String& name) const;
00191 
00192 private:
00193         typedef std::map<String, Property*>     PropertyRegistry;
00194         PropertyRegistry        d_properties;
00195 
00196 
00197 public:
00198         /*************************************************************************
00199                 Iterator stuff
00200         *************************************************************************/
00201         typedef ConstBaseIterator<PropertyRegistry>     PropertyIterator;
00202 
00207         PropertyIterator        getIterator(void) const;
00208 };
00209 
00210 } // End of  CEGUI namespace section
00211 
00212 #if defined(_MSC_VER)
00213 #       pragma warning(pop)
00214 #endif
00215 
00216 #endif  // end of guard _CEGUIPropertySet_h_

Generated on Wed Sep 7 09:56:33 2005 for Crazy Eddies GUI System by  doxygen 1.4.3