cannot select Parameterized Type

后端 未结 2 1246
感情败类
感情败类 2020-12-20 12:59

I want to create a rest to communicate between server and client.

The constructor given below:

public class RestHelper {
    public Rest         


        
2条回答
  •  再見小時候
    2020-12-20 13:25

    I got the solution.

    ResultContainData result = new ResultContainData<>();
    RestHelper> helper = new RestHelper<>(url, user, (Class>)result.getClass());
    

    It's working for me. I am still looking for a better solution.

提交回复
热议问题