Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
1.8 KiB

  1. /*++
  2. Copyright (C) 1996-1999 Microsoft Corporation
  3. Module Name:
  4. DUMBNODE.H
  5. Abstract:
  6. WBEM Dumb Node
  7. History:
  8. --*/
  9. #ifndef __WMI_DUMBNODE__H_
  10. #define __WMI_DUMBNODE__H_
  11. #include "evaltree.h"
  12. //
  13. // This node is used when not enough information exists about the objects being
  14. // tested to perform fast, strongly typed, handle-based comparisons. Instead,
  15. // it is based on the core query engine code for evaluating a token. Having
  16. // evaluated a token, it can take a NULL, TRUE, or FALSE branches.
  17. //
  18. class CDumbNode : public CBranchingNode
  19. {
  20. protected:
  21. QL_LEVEL_1_TOKEN m_Token;
  22. int EvaluateToken(IWbemPropertySource *pTestObj, QL_LEVEL_1_TOKEN& Tok);
  23. LPWSTR NormalizePath(LPCWSTR wszObjectPath);
  24. public:
  25. CDumbNode(QL_LEVEL_1_TOKEN& Token);
  26. CDumbNode(const CDumbNode& Other, BOOL bChildren = TRUE);
  27. virtual ~CDumbNode();
  28. HRESULT Validate(IWbemClassObject* pClass);
  29. virtual CEvalNode* Clone() const {return new CDumbNode(*this);}
  30. virtual CBranchingNode* CloneSelf() const
  31. {return new CDumbNode(*this, FALSE);}
  32. virtual HRESULT Compile(CContextMetaData* pNamespace,
  33. CImplicationList& Implications);
  34. virtual HRESULT CombineBranchesWith(CBranchingNode* pArg2, int nOp,
  35. CContextMetaData* pNamespace,
  36. CImplicationList& Implications,
  37. bool bDeleteThis, bool bDeleteArg2,
  38. CEvalNode** ppRes);
  39. virtual long GetSubType();
  40. virtual int SubCompare(CEvalNode* pOther);
  41. virtual int ComparePrecedence(CBranchingNode* pOther);
  42. virtual HRESULT Evaluate(CObjectInfo& ObjInfo, INTERNAL CEvalNode** ppNext);
  43. virtual void Dump(FILE* f, int nOffset);
  44. virtual HRESULT OptimizeSelf();
  45. };
  46. #endif