Netbeans 不兼容类型问题
我在 Netbeans 中收到以下警告:
incompatible types
found : carPackage.port.search
required : carPackage.SearchResponse
在我的 JSP 页面中,我有以下代码:
CarService service = new CarService();
CarPort port = service.getCarPort();
SearchResponse searchResult = port.search("Toyota");
错误显然发生在这一行:
SearchResponse searchResult = port.search("Toyota");
我应该输入什么数据类型而不是 SearchResponse?
谢谢, 卢卡斯
I am getting the following warning in Netbeans:
incompatible types
found : carPackage.port.search
required : carPackage.SearchResponse
In my JSP page, I have the following code:
CarService service = new CarService();
CarPort port = service.getCarPort();
SearchResponse searchResult = port.search("Toyota");
The error obviously occurs on this line:
SearchResponse searchResult = port.search("Toyota");
What datatype should I put in instead of SearchResponse?
Thanks,
Lucas
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你失踪了; 从最后。 如果 CarPort.search 返回 SearchResponse,则您的数据类型是正确的。
You're missing ; from the end. If CarPort.search returns SearchResponse, then your datatypes are correct.