0
我有一个类,如下图所示:春季球衣REST框架
@Path("/myrequest")
@Scope("request")
@Component
public class MyRESTCode implements IServicedResource<T> {
@Inject
private IMyService serviceImpl;
@Override
public void setServiceImpl(IMyService impl) {
serviceImpl = impl;
}
}
@Path("/users")
@POST
@Consumes ({MediaType.APPLICATION_JSON})
@Produces ({MediaType.APPLICATION_JSON})
public Response mymethod(Object obj) throws Exception {
serviceImpl.callme(obj);
return Response.noContent().build();
}
现在,这个呼我方法实现在其它的类(MyOtherClass.java)存在。
任何人都可以告诉我MyOtherClass.java中mymethod调用callme方法时,/用户POST请求被建立吗???
此外,谁调用setServiceImpl方法&它是如何设置的&它什么时候被调用?
谢谢!