从Java Play Framework调用Scala,该框架采用ClassTag
2022-09-03 12:44:50
我正在尝试从Play Java类调用Scala方法,该方法将ClassTag作为参数
我失败的尝试是
Option<LocalUser> localUser = Cache.getAs(userId.userId(), app, new ClassTag<LocalUser>() );
API 方法如下所示
Cache.getAs(String key, Application app, ClassTag<LocalUser> ct );