SOAP fault handling in java

后端 未结 1 544
春和景丽
春和景丽 2021-01-24 08:37

I am pretty new to SOAP and I am trying to understand SOAP fault handling (in Java). I have done reading about this topic but there are still some concepts that remain unclear

1条回答
  •  臣服心动
    2021-01-24 09:05

    If you want to return a proper response to the caller. Then you need to return an object not only one fields. For example you can create new class you can call it Response that contains the fields you want to display it to the caller like responCode and responseDescription. Using these two fields you can cover the different error cases you have. And of course you need to change the return type of the method playUserInfo to be of type Response

    0 讨论(0)
提交回复
热议问题