Local Stub introduction has some error as following
package com.foo;
public class BarServiceStub implements BarService {
private final BarService barService;
// The real remote proxy object is passed in through the constructor
public (BarService barService) {
this.barService = barService;
}
public String sayHello(String name) {
// The following code is executed on the client. You can do local ThreadLocal caching on the client side, or verify parameters, etc.
try {
return barService.sayHello(name);
} catch (Exception e) {
// You can return the mock data.
return "MockData";
}
}
}
the constructor's signature should be
public BarServiceStub(BarService barService)
Local Stub introduction has some error as following
the constructor's signature should be