|
From: Dave B. <bla...@us...> - 2012-05-17 12:17:52
|
Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml
In directory vz-cvs-3.sog:/tmp/cvs-serv4063/src/org/sblim/cimclient/internal/cimxml
Modified Files:
Tag: Experimental
CIMClientXML_HelperImpl.java
Log Message:
3527580 - WBEMClient should not throw IllegalArgumentException
Index: CIMClientXML_HelperImpl.java
===================================================================
RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/cimxml/CIMClientXML_HelperImpl.java,v
retrieving revision 1.18.2.29
retrieving revision 1.18.2.30
diff -u -d -r1.18.2.29 -r1.18.2.30
--- CIMClientXML_HelperImpl.java 25 Apr 2012 02:34:36 -0000 1.18.2.29
+++ CIMClientXML_HelperImpl.java 17 May 2012 12:17:49 -0000 1.18.2.30
@@ -47,6 +47,7 @@
* 3062747 2010-09-21 blaschke-oss SblimCIMClient does not log all CIM-XML responces.
* 3514537 2012-04-03 blaschke-oss TCK: execQueryInstances requires boolean, not Boolean
* 3521119 2012-04-24 blaschke-oss JSR48 1.0.0: remove CIMObjectPath 2/3/4-parm ctors
+ * 3527580 2012-05-17 blaschke-oss WBEMClient should not throw IllegalArgumentException
*/
package org.sblim.cimclient.internal.cimxml;
@@ -388,7 +389,7 @@
CIMProperty<?>[] keysA = pObjectName.getKeys();
// Make sure keys are populated
- if (keysA.length == 0) throw new IllegalArgumentException(
+ if (keysA.length == 0) throw new WBEMException(WBEMException.CIM_ERR_INVALID_PARAMETER,
"associatorInstances requires keys for the instance to be populated");
Element simplereqE = CIMXMLBuilderImpl.createSIMPLEREQ(pDoc);
@@ -463,7 +464,8 @@
"null class name");
// Make sure keys are not populated
- if (pObjectName.getKeys().length != 0) throw new IllegalArgumentException(
+ if (pObjectName.getKeys().length != 0) throw new WBEMException(
+ WBEMException.CIM_ERR_INVALID_PARAMETER,
"Keys should not be populated for associatorClasses");
Element simplereqE = CIMXMLBuilderImpl.createSIMPLEREQ(pDoc);
@@ -1305,7 +1307,8 @@
"null class name");
// Make sure keys are not populated
- if (pPath.getKeys().length != 0) throw new IllegalArgumentException(
+ if (pPath.getKeys().length != 0) throw new WBEMException(
+ WBEMException.CIM_ERR_INVALID_PARAMETER,
"Keys should not be populated for referenceClasses");
Element simplereqE = CIMXMLBuilderImpl.createSIMPLEREQ(pDoc);
@@ -1365,7 +1368,8 @@
"null class name");
// keys are required for CIMInstance
- if (pPath.getKeys().length == 0) throw new IllegalArgumentException(
+ if (pPath.getKeys().length == 0) throw new WBEMException(
+ WBEMException.CIM_ERR_INVALID_PARAMETER,
"refrenceInstances requires keys for the instance to be populated");
Element simplereqE = CIMXMLBuilderImpl.createSIMPLEREQ(pDoc);
|