(file) Return to CQLFactor.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / CQL

Diff for /pegasus/src/Pegasus/CQL/CQLFactor.cpp between version 1.1.2.4 and 1.1.2.5

version 1.1.2.4, 2004/08/26 20:43:04 version 1.1.2.5, 2004/08/26 21:23:13
Line 7 
Line 7 
 #include <Pegasus/Common/ArrayImpl.h> #include <Pegasus/Common/ArrayImpl.h>
 #undef PEGASUS_ARRAY_T #undef PEGASUS_ARRAY_T
  
 //##ModelId=40FC34920351  
 CQLFactor::CQLFactor(const CQLFactor& inCQLFact) CQLFactor::CQLFactor(const CQLFactor& inCQLFact)
 { {
    _CQLVal = inCQLFact._CQLVal;    _CQLVal = inCQLFact._CQLVal;
Line 21 
Line 20 
    _CQLVal = inCQLVal;    _CQLVal = inCQLVal;
 } }
  
 //##ModelId=40FC34BC0061  
 CQLFactor::CQLFactor(CQLExpression& inCQLExp) CQLFactor::CQLFactor(CQLExpression& inCQLExp)
 { {
    _CQLExp = new CQLExpression(inCQLExp);    _CQLExp = new CQLExpression(inCQLExp);
 } }
  
 //##ModelId=40FC34E30391  
 CQLFactor::CQLFactor(CQLFunction inCQLFunc) CQLFactor::CQLFactor(CQLFunction inCQLFunc)
 { {
    _CQLFunct = new CQLFunction(inCQLFunc);    _CQLFunct = new CQLFunction(inCQLFunc);
 } }
  
 //##ModelId=40FC33B70262  
 CQLValue CQLFactor::getValue() CQLValue CQLFactor::getValue()
 { {
    return _CQLVal;    return _CQLVal;
Line 41 
Line 37 
  
 CQLValue CQLFactor::resolveValue(CIMInstance CI, QueryContext& QueryCtx) CQLValue CQLFactor::resolveValue(CIMInstance CI, QueryContext& QueryCtx)
 { {
      if(_CQLExp != NULL)
      {
         return _CQLExp->resolveValue(CI,QueryCtx);
      }
      else if (_CQLFunct != NULL)
      {
         return _CQLFunct->resolveValue(CI,QueryCtx);
      }
      else
      {
    _CQLVal.resolve(CI,QueryCtx);    _CQLVal.resolve(CI,QueryCtx);
    return _CQLVal;    return _CQLVal;
 } }
   }
  
 Boolean CQLFactor::isSimpleValue() Boolean CQLFactor::isSimpleValue()
 { {
Line 64 
Line 71 
 { {
    if(_CQLFunct != NULL)    if(_CQLFunct != NULL)
    {    {
       _CQLFunct->toString();        return _CQLFunct->toString();
    }    }
    else if(_CQLExp != NULL)    else if(_CQLExp != NULL)
    {    {
       _CQLExp->toString();        return _CQLExp->toString();
    }    }
    else    else
    {    {
       _CQLVal.toString();        return _CQLVal.toString();
    }    }
 } }
  
 void CQLFactor::applyScopes(Array<CQLScope> inScopes) void CQLFactor::applyScopes(Array<CQLScope> inScopes)
 { {
    // TODO:  
      if(_CQLFunct != NULL)
      {
         _CQLFunct->applyScopes(inScopes);
      }
      else if(_CQLExp != NULL)
      {
         _CQLExp->applyScopes(inScopes);
      }
      else
      {
         _CQLVal.applyScopes(inScopes);
      }
    return;    return;
 } }
  


Legend:
Removed from v.1.1.2.4  
changed lines
  Added in v.1.1.2.5

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2