/****************************************************************** ReindeerProv.H -- WBEM provider class definition Generated by Microsoft WBEM Code Generation Engine Description: Sample provider using the Provider Framework *******************************************************************/ // Property set identification //============================ #define PROVIDER_NAME_REINDEERPROV L"Reindeer" // Property name externs -- defined in ReindeerProv.cpp //================================================= extern const WCHAR* pName ; extern const WCHAR* pRedNose ; extern const WCHAR* pWeight ; class CReindeer : public Provider { public: // Constructor/destructor //======================= CReindeer(LPCWSTR chsClassName, LPCWSTR lpszNameSpace); virtual ~CReindeer(); protected: // Reading Functions //============================ virtual HRESULT EnumerateInstances(MethodContext* pMethodContext, long lFlags = 0L); virtual HRESULT GetObject(CInstance* pInstance, long lFlags = 0L); virtual HRESULT ExecQuery(MethodContext *pMethodContext, CFrameworkQuery& Query, long lFlags = 0L); // Writing Functions //============================ virtual HRESULT PutInstance(const CInstance& Instance, long lFlags = 0L); virtual HRESULT DeleteInstance(const CInstance& Instance, long lFlags = 0L); // Other Functions virtual HRESULT ExecMethod( const CInstance& Instance, const BSTR bstrMethodName, CInstance *pInParams, CInstance *pOutParams, long lFlags = 0L ); // TO DO: Declare any additional functions and accessor // functions for private data used by this class //=========================================================== private: // All data members for CReindeer should be included here. BOOL IsInList(const CHStringArray &asArray, LPCWSTR pszString); } ; // struct to hold instance information struct Deers { WCHAR* m_name; // name of Reindeer DWORD m_weight; // weight of reindeer bool m_redNose; // does he have a red nose? bool m_deleted; // has he been deleted? enum {NDeers = 9}; };