无法在Android项目中重新选择PropertyInfo类的setName、setValue、setType方法

无法在Android项目中重新选择PropertyInfo类的setName、setValue、setType方法,android,android-ksoap2,Android,Android Ksoap2,我在我的项目中使用了ksoap2-android-full-2.1.2 如果Celcius是一个类,则使用celsius.getClass()代替double.class 这就是我在KSOAP-2 requset中实现ComplexClass的方法 PropertyInfo celsiusPI = new PropertyInfo(); celsiusPI.setName("Celcius"); celsiusPI.setValue(celsius); celsiusPI.setType(dou

我在我的项目中使用了
ksoap2-android-full-2.1.2

如果Celcius是一个类,则使用celsius.getClass()代替double.class

这就是我在KSOAP-2 requset中实现ComplexClass的方法

PropertyInfo celsiusPI = new PropertyInfo();
celsiusPI.setName("Celcius");
celsiusPI.setValue(celsius);
celsiusPI.setType(double.class);
request.addProperty(celsiusPI);
如果你的celcius是一个复杂的类,你必须像我上面提到的那样去做


谢谢:)

是否发布完整的代码和您使用的
.jar
文件您是否添加了ksoap2-android-full-2.1.2作为依赖项?在作为依赖项添加后是否重新生成了?是的,我在依赖项中添加了它,并重新生成了alsoI。我想发布完整的代码,但它给了我更多的细节错误。如何跳过它
    //Complex-type class implementation
                    getPendingAmountInfo pendingAmountInfo = new getPendingAmountInfo();

                    pendingAmountInfo.altCustomerId = altCustId;
                    pendingAmountInfo.authToken = authToken;
                    pendingAmountInfo.imei = LoginActivity.imeiNo;

                    PropertyInfo pendingAmtproperty = new PropertyInfo();
                    pendingAmtproperty.setName("pendingAmountInfo");
                    pendingAmtproperty.setValue(pendingAmountInfo);
                    pendingAmtproperty.setType(pendingAmountInfo.getClass());

//Creating Soap request object
                SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);
                request.addProperty(pendingAmtproperty);