Could not find a suitable constructor in 〜 エラーの対処方法
環境:ScalaIDE(eclipse4.2) + Scala + Play2.4
下記エラーが出た時の対処方法
1) Could not find a suitable constructor in controllers.UserController. Classes must have either one (and only one) constructor annotated with @Inject or a zero-argument constructor that is not private.
at controllers.UserController.class(UserController.scala:11)
while locating controllers.UserController
for parameter 5 at router.Routes.<init>(Routes.scala:43)
while locating router.Routes
while locating play.api.inject.RoutesProvider
while locating play.api.routing.Router
eclipse上で.scalaファイルを開き*マークが付いてるファイルが無いか探す。
あった場合、下記リンク参照して全てのファイルを消すとエラーが無くなる。
英語版の場合、フォルダ上で右クリックして「Team」→「Apply Patch...」
対象ファイルを選択して「Finish」する。
以上。