Play-Rest api with java - 对象不是包的成员

Play-Rest api with java - object is not a member of package

我有一个问题,我无法加载我的网站,因为出现了这个错误:

object UsersServices 不是包控制器的成员

我用休息 api :

# Routes
# This file defines all application routes (Higher priority routes first)
# ~~~~

# Home page
GET     /                           controllers.Assets.at(path="/public/view",file="index.html")

# Map static resources from the /public folder to the /assets URL path
GET  /public/*file        controllers.Assets.at(path="/public", file)


GET /api/users            controllers.UsersServices.getUsers()

java中的函数非常基础:

public static Result getUsers(){
        return ok(Json.toJson(Test);
    }

我靠不知道怎么解决。

根据您提供的信息,您似乎需要以下内容:

package controllers;
imports...

public class UsersServices extends Controller {

  public Result getUsers() {
  ...