version 1.1.2.15, 2004/10/19 17:48:53
|
version 1.1.2.16, 2004/10/19 20:06:37
|
|
|
} | } |
case CQLValue::CIMInstance_type: | case CQLValue::CIMInstance_type: |
{ | { |
_theValue._IN = new CIMInstance(*val->_theValue._IN); |
_theValue._IN = new CIMInstance(val->_theValue._IN->clone()); |
break; | break; |
} | } |
case CQLValue::CIMClass_type: | case CQLValue::CIMClass_type: |
{ | { |
_theValue._CL = new CIMClass(*val->_theValue._CL); |
_theValue._CL = new CIMClass(val->_theValue._CL->clone()); |
break; | break; |
} | } |
default: | default: |
|
|
| |
CQLValueRep::CQLValueRep(const CIMInstance& inInstance) | CQLValueRep::CQLValueRep(const CIMInstance& inInstance) |
{ | { |
_theValue._IN = new CIMInstance(inInstance); |
_theValue._IN = new CIMInstance(inInstance.clone()); |
_valueType = CQLValue::CIMInstance_type; | _valueType = CQLValue::CIMInstance_type; |
_isResolved = true; | _isResolved = true; |
} | } |
| |
CQLValueRep::CQLValueRep(const CIMClass& inClass) | CQLValueRep::CQLValueRep(const CIMClass& inClass) |
{ | { |
_theValue._CL = new CIMClass(inClass); |
_theValue._CL = new CIMClass(inClass.clone()); |
_valueType = CQLValue::CIMClass_type; | _valueType = CQLValue::CIMClass_type; |
_isResolved = true; | _isResolved = true; |
} | } |
|
|
| |
void CQLValueRep::resolve(CIMInstance& CI, QueryContext& inQueryCtx) | void CQLValueRep::resolve(CIMInstance& CI, QueryContext& inQueryCtx) |
{ | { |
if(_isResolved) |
if(_CQLChainId.size() == 0) |
{ | { |
return; | return; |
} | } |
|
|
{ | { |
// A class was passed in with no property indicated. | // A class was passed in with no property indicated. |
// Set the instance passed in, as a primitive. | // Set the instance passed in, as a primitive. |
_theValue._IN = (CIMInstance *) new CIMInstance(CI); |
_theValue._IN = (CIMInstance *) new CIMInstance(CI.clone()); |
_valueType = CQLValue::CIMInstance_type; | _valueType = CQLValue::CIMInstance_type; |
_isResolved = true; | _isResolved = true; |
return; // Done. | return; // Done. |
|
|
// Since no further processing is necessary for this case. | // Since no further processing is necessary for this case. |
if(Idstrings[index].isWildcard()) | if(Idstrings[index].isWildcard()) |
{ | { |
_theValue._IN = new CIMInstance(CI); |
_theValue._IN = new CIMInstance(CI.clone()); |
_valueType = CQLValue::CIMInstance_type; | _valueType = CQLValue::CIMInstance_type; |
_isResolved = true; | _isResolved = true; |
return; | return; |
|
|
_theValue._OP = new CIMObjectPath(rhs.getReference()); | _theValue._OP = new CIMObjectPath(rhs.getReference()); |
break; | break; |
case CQLValue::CIMInstance_type: | case CQLValue::CIMInstance_type: |
_theValue._IN = new CIMInstance(rhs.getInstance()); |
_theValue._IN = new CIMInstance(rhs.getInstance().clone()); |
break; | break; |
case CQLValue::CIMClass_type: | case CQLValue::CIMClass_type: |
_theValue._CL = new CIMClass(rhs.getClass()); |
_theValue._CL = new CIMClass(rhs.getClass().clone()); |
break; | break; |
case CQLValue::Boolean_type: | case CQLValue::Boolean_type: |
case CQLValue::Sint64_type: | case CQLValue::Sint64_type: |
|
|
return true; | return true; |
} | } |
| |
|
/* |
CQLValueRep CQLValueRep::operator+(const CQLValueRep x) | CQLValueRep CQLValueRep::operator+(const CQLValueRep x) |
{ | { |
| |
|
|
break; | break; |
} | } |
| |
// control should never reach here |
|
return x; | return x; |
} | } |
| |
|
|
throw(Exception(String("CQLValueRep::operator-"))); | throw(Exception(String("CQLValueRep::operator-"))); |
break; | break; |
} | } |
// control should never reach here |
|
return x; | return x; |
} | } |
| |
|
|
throw(Exception(String("CQLValueRep::operator*"))); | throw(Exception(String("CQLValueRep::operator*"))); |
break; | break; |
} | } |
// control should never reach here |
|
return x; | return x; |
} | } |
| |
|
|
throw(Exception(String("CQLValueRep::operator/"))); | throw(Exception(String("CQLValueRep::operator/"))); |
break; | break; |
} | } |
// control should never reach here |
|
return x; | return x; |
} | } |
|
*/ |
//##ModelId=40FC3F6F0302 | //##ModelId=40FC3F6F0302 |
CQLValue::CQLValueType CQLValueRep::getValueType() | CQLValue::CQLValueType CQLValueRep::getValueType() |
{ | { |