cmpi

cmpi/CmpiObject.h

Go to the documentation of this file.
00001 /*
00002  *
00003  * $Id: CmpiObject.h,v 1.3 2008/07/09 19:36:59 tyreld Exp $
00004  *
00005  * (C) Copyright IBM Corp. 2003, 2005, 2008
00006  *
00007  * THIS FILE IS PROVIDED UNDER THE TERMS OF THE ECLIPSE PUBLIC LICENSE
00008  * ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE
00009  * CONSTITUTES RECIPIENTS ACCEPTANCE OF THE AGREEMENT.
00010  *
00011  * You can obtain a current copy of the Eclipse Public License from
00012  * http://www.opensource.org/licenses/eclipse-1.0.txt
00013  *
00014  * Author:        Adrian Schuur <schuur@de.ibm.com>
00015  * Contributors:  Heidi Neumann, heidineu@de.ibm.com
00016  *                Angel Nunez Mencias, anunez@de.ibm.com
00017  *                Viktor Mihajlovski, mihajlov@de.ibm.com
00018  *
00019  * Description: CMPI Object Definitions
00020  *
00021  */
00022 
00023 #ifndef _CmpiObject_h_
00024 #define _CmpiObject_h_
00025 
00026 #include "cmpidt.h"
00027 #include "cmpift.h"
00028 
00029 #ifndef CmpiBoolean
00030 #define CmpiBoolean CMPIBoolean
00031 #define CmpiRc      CMPIrc
00032 #endif
00033 
00034 #include "Linkage.h"
00035 #include "CmpiString.h"
00036 
00037 class CmpiBroker;
00038 
00042 class CMPI_PROVIDER_LINKAGE CmpiObject {
00043    friend class CmpiBroker;
00044    friend class CmpiObjectPath;
00045    friend class CmpiInstance;
00046 protected:
00049    void *enc;
00052    CmpiObject();
00053 
00056    CmpiObject(const void* enc);
00057 
00058    CmpiString doToString(CMPIBroker *mb);
00059 
00060    CmpiBoolean doIsA(CMPIBroker *mb, const char *typeName) const;
00061 private:
00062 public:
00065    CmpiBoolean isNull() const;
00066 
00069    CmpiString toString();
00070 
00073    CmpiBoolean isA(const char *typeName) const;
00074 };
00075 
00076 #endif
00077