Update of /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/wbem
In directory vz-cvs-3.sog:/tmp/cvs-serv3157/src/org/sblim/cimclient/internal/wbem
Modified Files:
Tag: Experimental
WBEMClientCIMXML.java
Log Message:
3514685 - TCK: getProperty must return default values
Index: WBEMClientCIMXML.java
===================================================================
RCS file: /cvsroot/sblim/jsr48-client/src/org/sblim/cimclient/internal/wbem/WBEMClientCIMXML.java,v
retrieving revision 1.21.2.56
retrieving revision 1.21.2.57
diff -u -d -r1.21.2.56 -r1.21.2.57
--- WBEMClientCIMXML.java 3 Apr 2012 12:50:23 -0000 1.21.2.56
+++ WBEMClientCIMXML.java 3 Apr 2012 19:16:35 -0000 1.21.2.57
@@ -58,6 +58,7 @@
* 3423064 2011-10-13 blaschke-oss Add UpdateExpiredPassword Header for Reqs from Java Client
* 3496355 2012-03-02 blaschke-oss JSR48 1.0.0: add new WBEMClientConstants
* 3514537 2012-04-03 blaschke-oss TCK: execQueryInstances requires boolean, not Boolean
+ * 3514685 2012-04-03 blaschke-oss TCK: getProperty must return default values
*/
package org.sblim.cimclient.internal.wbem;
@@ -330,58 +331,36 @@
public String getProperty(String pKey) {
if (pKey.startsWith("javax.wbem.")) {
// Process JSR48 properties
- String SblimKey;
-
if (pKey.equals(WBEMClientConstants.PROP_ENABLE_CONSOLE_LOGGING)) {
- SblimKey = this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_CONSOLE_LEVEL);
- if (SblimKey == null) return null;
- return SblimKey.equals("OFF") ? "0" : "1";
+ return Level.OFF.equals(this.iConfiguration.getLogConsoleLevel()) ? "0" : "1";
} else if (pKey.equals(WBEMClientConstants.PROP_ENABLE_DEBUG)) {
- SblimKey = this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_DEBUG);
- if (SblimKey == null) return null;
- return SblimKey.equals("true") ? "1" : "0";
+ return this.iConfiguration.isLogDebug() ? "1" : "0";
} else if (pKey.equals(WBEMClientConstants.PROP_ENABLE_FILE_LOGGING)) {
- SblimKey = this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_FILE_LEVEL);
- if (SblimKey == null) return null;
- return SblimKey.equals("OFF") ? "0" : "1";
+ return Level.OFF.equals(this.iConfiguration.getLogFileLevel()) ? "0" : "1";
} else if (pKey.equals(WBEMClientConstants.PROP_LOG_BYTE_LIMIT)) {
- return this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_FILE_SIZE_LIMIT);
+ return Integer.toString(this.iConfiguration.getLogFileSizeLimit());
} else if (pKey.equals(WBEMClientConstants.PROP_LOG_DIR)) {
- SblimKey = this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_FILE_LOCATION);
+ String SblimKey = this.iConfiguration.getLogFileLocation();
if (SblimKey == null) return null;
int i = SblimKey.lastIndexOf(File.separatorChar);
return i != -1 ? SblimKey.substring(0, i) : null;
} else if (pKey.equals(WBEMClientConstants.PROP_LOG_FILENAME)) {
- SblimKey = this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_FILE_LOCATION);
+ String SblimKey = this.iConfiguration.getLogFileLocation();
if (SblimKey == null) return null;
int i = SblimKey.lastIndexOf(File.separatorChar);
return i != -1 ? SblimKey.substring(i + 1) : SblimKey;
} else if (pKey.equals(WBEMClientConstants.PROP_LOG_NUM_FILES)) {
- return this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.LOG_FILE_COUNT);
+ return Integer.toString(this.iConfiguration.getLogFileCount());
} else if (pKey.equals(WBEMClientConstants.PROP_TIMEOUT)) {
- return this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.HTTP_TIMEOUT);
+ return Integer.toString(this.iConfiguration.getHttpTimeout());
} else if (pKey.equals(WBEMClientConstants.PROPERTY_WBEM_CHUNKING)) {
- SblimKey = this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.HTTP_USE_CHUNKING);
- if (SblimKey == null) return null;
- return SblimKey.equals("true") ? "1" : "0";
+ return this.iConfiguration.isHttpChunked() ? "1" : "0";
} else if (pKey.equals(WBEMClientConstants.PROP_CLIENT_KEYSTORE)) {
- return this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.KEYSTORE_PATH);
+ return this.iConfiguration.getSslKeyStorePath();
} else if (pKey.equals(WBEMClientConstants.PROP_CLIENT_KEYSTORE_PASSWORD)) {
- return this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.KEYSTORE_PASSWORD);
+ return this.iConfiguration.getSslKeyStorePassword();
} else if (pKey.equals(WBEMClientConstants.PROP_CLIENT_TRUSTSTORE)) {
- return this.iConfiguration
- .getDomainProperty(WBEMConfigurationProperties.TRUSTSTORE_PATH);
+ return this.iConfiguration.getSslTrustStorePath();
} else {
return null;
}
|