Mercurial > hg > Members > nobuyasu > Consensus
changeset 40:1d5c086e069b
create getAllUsers() action.
line wrap: on
line diff
--- a/app/controllers/User.java Thu Oct 04 01:39:44 2012 +0900 +++ b/app/controllers/User.java Thu Oct 04 01:59:21 2012 +0900 @@ -30,6 +30,7 @@ return created(); } + public static Result getUser(String name) { TPGraph tpGraph = TPGraph.getInstance(); @@ -44,6 +45,16 @@ } } + public static Result getAllUsers() { + TPGraph tpGraph = TPGraph.getInstance(); + Object[] allUser = tpGraph.searchAllUser(); + if (allUser == null) { + return badRequest("User does not exist."); + } + return ok(Json.toJson(allUser)); + } + + public static Result getUserRequests(String name) { TPGraph tpGraph = TPGraph.getInstance(); Graph graph = tpGraph.getGraph(); @@ -53,7 +64,9 @@ } else { UserModel user = new UserModel(v); Object[] requests = user.getUserRequests(); - if (requests == null) return notFound("Requests not found"); + if (requests == null) { + return notFound("Requests not found"); + } return created(Json.toJson(requests)); } }
--- a/app/models/TPGraph.java Thu Oct 04 01:39:44 2012 +0900 +++ b/app/models/TPGraph.java Thu Oct 04 01:59:21 2012 +0900 @@ -130,6 +130,20 @@ return setLabel(fromClaim.getVertex(), toClaim.getVertex(), label); } + public Object[] searchAllUser() { + Vertex userRootVertex = graph.getVertex(getUserRootId()); + GremlinPipeline<Vertex,Vertex> pipe = new GremlinPipeline<Vertex,Vertex>(); + pipe.start(userRootVertex).out(CHILD); + ArrayList<Object> userArray = new ArrayList<Object>(); + for (Vertex userVertex : pipe) { + userArray.add(userVertex.getId()); + } + if (userArray.size() == 0) { + return null; + } + return userArray.toArray(); + } + public Boolean deleteRequestEdge(ClaimModel claim, HashSet<Object> userSet) { GremlinPipeline<Vertex,Edge> pipeEdge = new GremlinPipeline<Vertex,Edge>(); pipeEdge.start(claim.getVertex()).outE(NodeModel.L_REQUEST);
--- a/conf/routes Thu Oct 04 01:39:44 2012 +0900 +++ b/conf/routes Thu Oct 04 01:59:21 2012 +0900 @@ -4,6 +4,7 @@ # Home page GET / controllers.Application.index() +GET /users/all controllers.User.getAllUsers() PUT /users/create/:name controllers.User.createUser(name: String) GET /users/browse/:name controllers.User.getUser(name: String) GET /users/requests/:name controllers.User.getUserRequests(name: String) @@ -14,6 +15,7 @@ GET /consensus/browse/:id controllers.Claim.getClaimTree(id: String) GET /claims/answer/:id/:name controllers.Claim.getUserConsensusStatus(id: String, name: String) + POST /claims/create controllers.Claim.crateClaim() POST /claims/:mentionType/:id/create controllers.Claim.createMention(mentionType: String ,id: String) POST /claims/edit/:id controllers.Claim.editClaim(id: String)
--- a/logs/application.log Thu Oct 04 01:39:44 2012 +0900 +++ b/logs/application.log Thu Oct 04 01:59:21 2012 +0900 @@ -1,24 +1,246 @@ -2012-10-04 00:57:27,766 - [INFO] - from play in main +2012-10-04 01:56:00,062 - [INFO] - from play in main Listening for HTTP on port 9000... -2012-10-04 00:57:32,759 - [INFO] - from play in play-akka.actor.default-dispatcher-1 -Application started (Dev) +2012-10-04 01:56:06,675 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [PUT /users/create/akifumi] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] + +2012-10-04 01:56:07,815 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [PUT /users/create/takaaki] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] + +2012-10-04 01:56:08,993 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [PUT /users/create/yosiaki] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] + +2012-10-04 01:56:10,117 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [PUT /users/create/suzuki] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] -2012-10-04 01:01:31,070 - [INFO] - from application in play-akka.actor.default-dispatcher-1 -Application shutdown... +2012-10-04 01:56:11,774 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [POST /claims/create] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] + +2012-10-04 01:56:12,791 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [POST /claims/create] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] -2012-10-04 01:01:31,090 - [INFO] - from play in play-akka.actor.default-dispatcher-1 +2012-10-04 01:56:13,642 - [ERROR] - from application in New I/O worker #1 + + +! Internal server error, for request [GET /users/consensus/akifumi] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] + +2012-10-04 01:57:05,370 - [ERROR] - from application in New I/O worker #2 + + +! Internal server error, for request [PUT /users/create/akifumi] -> + +sbt.PlayExceptions$CompilationException: Compilation error [value getAllUsers is not a member of object controllers.User] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12$$anonfun$apply$13.apply(PlayReloader.scala:229) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:229) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4$$anonfun$apply$12.apply(PlayReloader.scala:226) ~[na:na] + at scala.Option.map(Option.scala:133) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:226) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3$$anonfun$4.apply(PlayReloader.scala:224) ~[na:na] + at scala.Either$LeftProjection.map(Either.scala:183) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:224) ~[na:na] + at sbt.PlayReloader$$anon$2$$anonfun$reload$3.apply(PlayReloader.scala:219) ~[na:na] + at scala.Option.getOrElse(Option.scala:108) ~[scala-library.jar:0.11.3] + at sbt.PlayReloader$$anon$2.reload(PlayReloader.scala:219) ~[na:na] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at play.core.ReloadableApplication$$anonfun$get$1.apply(ApplicationProvider.scala:110) ~[play_2.9.1.jar:2.0.3] + at akka.dispatch.Future$$anon$3.liftedTree1$1(Future.scala:195) ~[akka-actor.jar:2.0.2] + at akka.dispatch.Future$$anon$3.run(Future.scala:194) ~[akka-actor.jar:2.0.2] + at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:94) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1381) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:259) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:975) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1479) ~[akka-actor.jar:2.0.2] + at akka.jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ~[akka-actor.jar:2.0.2] + +2012-10-04 01:58:10,629 - [INFO] - from play in play-akka.actor.default-dispatcher-3 Application started (Dev) -2012-10-04 01:04:06,784 - [INFO] - from application in play-akka.actor.default-dispatcher-2 -Application shutdown... - -2012-10-04 01:04:06,801 - [INFO] - from play in play-akka.actor.default-dispatcher-2 -Application started (Dev) - -2012-10-04 01:04:11,405 - [INFO] - from application in play-akka.actor.default-dispatcher-2 -Application shutdown... - -2012-10-04 01:04:11,430 - [INFO] - from play in play-akka.actor.default-dispatcher-2 -Application started (Dev) -
Binary file target/scala-2.9.1/classes/Routes$$anonfun$routes$1$$anonfun$apply$1$$anonfun$apply$2.class has changed
Binary file target/scala-2.9.1/classes/Routes$$anonfun$routes$1$$anonfun$apply$3$$anonfun$apply$4.class has changed
Binary file target/scala-2.9.1/classes/Routes$$anonfun$routes$1$$anonfun$apply$5$$anonfun$apply$6.class has changed
Binary file target/scala-2.9.1/classes/controllers/ref/ReverseApplication$$anonfun$hello$1.class has changed
Binary file target/scala-2.9.1/classes/controllers/ref/ReverseApplication$$anonfun$index$1.class has changed
Binary file target/scala-2.9.1/classes/controllers/ref/ReverseAssets$$anonfun$at$1.class has changed
--- a/target/scala-2.9.1/classes/routes Thu Oct 04 01:39:44 2012 +0900 +++ b/target/scala-2.9.1/classes/routes Thu Oct 04 01:59:21 2012 +0900 @@ -4,19 +4,21 @@ # Home page GET / controllers.Application.index() +GET /users/all controllers.User.getAllUsers() PUT /users/create/:name controllers.User.createUser(name: String) GET /users/browse/:name controllers.User.getUser(name: String) GET /users/requests/:name controllers.User.getUserRequests(name: String) GET /users/consensus/:name controllers.User.getUserConsensus(name: String) GET /users/claims/:name controllers.User.getUserClaims(name: String) - GET /claims/browse/:id controllers.Claim.getClaimInfo(id: String) GET /claims/consensus/:id controllers.Claim.getClaimTree(id: String) +GET /consensus/browse/:id controllers.Claim.getClaimTree(id: String) +GET /claims/answer/:id/:name controllers.Claim.getUserConsensusStatus(id: String, name: String) + POST /claims/create controllers.Claim.crateClaim() POST /claims/:mentionType/:id/create controllers.Claim.createMention(mentionType: String ,id: String) POST /claims/edit/:id controllers.Claim.editClaim(id: String) -GET /consensus/browse/:id controllers.Claim.getClaimTree(id: String) # test action
Binary file target/scala-2.9.1/classes_managed/Routes$$anonfun$routes$1$$anonfun$apply$1$$anonfun$apply$2.class has changed
Binary file target/scala-2.9.1/classes_managed/Routes$$anonfun$routes$1$$anonfun$apply$1.class has changed
Binary file target/scala-2.9.1/classes_managed/Routes$$anonfun$routes$1$$anonfun$apply$3$$anonfun$apply$4.class has changed
Binary file target/scala-2.9.1/classes_managed/Routes$$anonfun$routes$1$$anonfun$apply$3.class has changed
Binary file target/scala-2.9.1/classes_managed/Routes$$anonfun$routes$1$$anonfun$apply$5$$anonfun$apply$6.class has changed
Binary file target/scala-2.9.1/classes_managed/Routes$$anonfun$routes$1$$anonfun$apply$5.class has changed
Binary file target/scala-2.9.1/classes_managed/controllers/javascript/ReverseApplication.class has changed
Binary file target/scala-2.9.1/classes_managed/controllers/javascript/ReverseAssets.class has changed
Binary file target/scala-2.9.1/classes_managed/controllers/ref/ReverseApplication$$anonfun$hello$1.class has changed
Binary file target/scala-2.9.1/classes_managed/controllers/ref/ReverseApplication$$anonfun$index$1.class has changed
Binary file target/scala-2.9.1/classes_managed/controllers/ref/ReverseAssets$$anonfun$at$1.class has changed
--- a/target/scala-2.9.1/src_managed/main/controllers/routes.java Thu Oct 04 01:39:44 2012 +0900 +++ b/target/scala-2.9.1/src_managed/main/controllers/routes.java Thu Oct 04 01:59:21 2012 +0900 @@ -1,6 +1,6 @@ // @SOURCE:/Users/aotokage/workspace/Consensus/conf/routes -// @HASH:9e0fa937ed92ecd1dae3165cbcac7424dc77d60f -// @DATE:Wed Oct 03 23:35:23 JST 2012 +// @HASH:0d161c51591c2cc11bf38fb7f107b713d79cc370 +// @DATE:Thu Oct 04 01:56:05 JST 2012 package controllers;
--- a/target/scala-2.9.1/src_managed/main/routes_reverseRouting.scala Thu Oct 04 01:39:44 2012 +0900 +++ b/target/scala-2.9.1/src_managed/main/routes_reverseRouting.scala Thu Oct 04 01:59:21 2012 +0900 @@ -1,6 +1,6 @@ // @SOURCE:/Users/aotokage/workspace/Consensus/conf/routes -// @HASH:9e0fa937ed92ecd1dae3165cbcac7424dc77d60f -// @DATE:Wed Oct 03 23:35:23 JST 2012 +// @HASH:0d161c51591c2cc11bf38fb7f107b713d79cc370 +// @DATE:Thu Oct 04 01:56:05 JST 2012 import play.core._ import play.core.Router._ @@ -12,15 +12,17 @@ import Router.queryString -// @LINE:28 -// @LINE:24 -// @LINE:23 +// @LINE:30 +// @LINE:26 +// @LINE:25 +// @LINE:21 +// @LINE:20 // @LINE:19 -// @LINE:18 -// @LINE:17 // @LINE:16 +// @LINE:15 // @LINE:14 // @LINE:13 +// @LINE:12 // @LINE:11 // @LINE:10 // @LINE:9 @@ -29,10 +31,11 @@ // @LINE:6 package controllers { +// @LINE:21 +// @LINE:20 // @LINE:19 -// @LINE:18 -// @LINE:17 // @LINE:16 +// @LINE:15 // @LINE:14 // @LINE:13 class ReverseClaim { @@ -40,38 +43,44 @@ -// @LINE:16 +// @LINE:19 def crateClaim() = { Call("POST", "/claims/create") } -// @LINE:18 +// @LINE:21 def editClaim(id:String) = { Call("POST", "/claims/edit/" + implicitly[PathBindable[String]].unbind("id", id)) } -// @LINE:17 +// @LINE:20 def createMention(mentionType:String, id:String) = { Call("POST", "/claims/" + implicitly[PathBindable[String]].unbind("mentionType", mentionType) + "/" + implicitly[PathBindable[String]].unbind("id", id) + "/create") } +// @LINE:16 +def getUserConsensusStatus(id:String, name:String) = { + Call("GET", "/claims/answer/" + implicitly[PathBindable[String]].unbind("id", id) + "/" + implicitly[PathBindable[String]].unbind("name", name)) +} + + // @LINE:13 def getClaimInfo(id:String) = { Call("GET", "/claims/browse/" + implicitly[PathBindable[String]].unbind("id", id)) } -// @LINE:19 +// @LINE:15 // @LINE:14 def getClaimTree(id:String) = { (id) match { // @LINE:14 case (id) if true => Call("GET", "/claims/consensus/" + implicitly[PathBindable[String]].unbind("id", id)) -// @LINE:19 +// @LINE:15 case (id) if true => Call("GET", "/consensus/browse/" + implicitly[PathBindable[String]].unbind("id", id)) } @@ -83,15 +92,15 @@ } -// @LINE:24 -// @LINE:23 +// @LINE:26 +// @LINE:25 // @LINE:6 class ReverseApplication { -// @LINE:24 +// @LINE:26 def test() = { Call("GET", "/test") } @@ -103,7 +112,7 @@ } -// @LINE:23 +// @LINE:25 def hello() = { Call("POST", "/hello") } @@ -114,13 +123,13 @@ } -// @LINE:28 +// @LINE:30 class ReverseAssets { -// @LINE:28 +// @LINE:30 def at(file:String) = { Call("GET", "/assets/" + implicitly[PathBindable[String]].unbind("file", file)) } @@ -131,6 +140,7 @@ } +// @LINE:12 // @LINE:11 // @LINE:10 // @LINE:9 @@ -141,31 +151,37 @@ -// @LINE:7 +// @LINE:8 def createUser(name:String) = { Call("PUT", "/users/create/" + implicitly[PathBindable[String]].unbind("name", name)) } -// @LINE:9 +// @LINE:10 def getUserRequests(name:String) = { Call("GET", "/users/requests/" + implicitly[PathBindable[String]].unbind("name", name)) } -// @LINE:8 +// @LINE:9 def getUser(name:String) = { Call("GET", "/users/browse/" + implicitly[PathBindable[String]].unbind("name", name)) } -// @LINE:10 +// @LINE:7 +def getAllUsers() = { + Call("GET", "/users/all") +} + + +// @LINE:11 def getUserConsensus(name:String) = { Call("GET", "/users/consensus/" + implicitly[PathBindable[String]].unbind("name", name)) } -// @LINE:11 +// @LINE:12 def getUserClaims(name:String) = { Call("GET", "/users/claims/" + implicitly[PathBindable[String]].unbind("name", name)) } @@ -179,15 +195,17 @@ -// @LINE:28 -// @LINE:24 -// @LINE:23 +// @LINE:30 +// @LINE:26 +// @LINE:25 +// @LINE:21 +// @LINE:20 // @LINE:19 -// @LINE:18 -// @LINE:17 // @LINE:16 +// @LINE:15 // @LINE:14 // @LINE:13 +// @LINE:12 // @LINE:11 // @LINE:10 // @LINE:9 @@ -196,10 +214,11 @@ // @LINE:6 package controllers.javascript { +// @LINE:21 +// @LINE:20 // @LINE:19 -// @LINE:18 -// @LINE:17 // @LINE:16 +// @LINE:15 // @LINE:14 // @LINE:13 class ReverseClaim { @@ -207,7 +226,7 @@ -// @LINE:16 +// @LINE:19 def crateClaim = JavascriptReverseRoute( "controllers.Claim.crateClaim", """ @@ -218,7 +237,7 @@ ) -// @LINE:18 +// @LINE:21 def editClaim = JavascriptReverseRoute( "controllers.Claim.editClaim", """ @@ -229,7 +248,7 @@ ) -// @LINE:17 +// @LINE:20 def createMention = JavascriptReverseRoute( "controllers.Claim.createMention", """ @@ -240,6 +259,17 @@ ) +// @LINE:16 +def getUserConsensusStatus = JavascriptReverseRoute( + "controllers.Claim.getUserConsensusStatus", + """ + function(id,name) { + return _wA({method:"GET", url:"/claims/answer/" + (""" + implicitly[PathBindable[String]].javascriptUnbind + """)("id", id) + "/" + (""" + implicitly[PathBindable[String]].javascriptUnbind + """)("name", name)}) + } + """ +) + + // @LINE:13 def getClaimInfo = JavascriptReverseRoute( "controllers.Claim.getClaimInfo", @@ -251,7 +281,7 @@ ) -// @LINE:19 +// @LINE:15 // @LINE:14 def getClaimTree = JavascriptReverseRoute( "controllers.Claim.getClaimTree", @@ -273,15 +303,15 @@ } -// @LINE:24 -// @LINE:23 +// @LINE:26 +// @LINE:25 // @LINE:6 class ReverseApplication { -// @LINE:24 +// @LINE:26 def test = JavascriptReverseRoute( "controllers.Application.test", """ @@ -303,7 +333,7 @@ ) -// @LINE:23 +// @LINE:25 def hello = JavascriptReverseRoute( "controllers.Application.hello", """ @@ -319,13 +349,13 @@ } -// @LINE:28 +// @LINE:30 class ReverseAssets { -// @LINE:28 +// @LINE:30 def at = JavascriptReverseRoute( "controllers.Assets.at", """ @@ -341,6 +371,7 @@ } +// @LINE:12 // @LINE:11 // @LINE:10 // @LINE:9 @@ -351,7 +382,7 @@ -// @LINE:7 +// @LINE:8 def createUser = JavascriptReverseRoute( "controllers.User.createUser", """ @@ -362,7 +393,7 @@ ) -// @LINE:9 +// @LINE:10 def getUserRequests = JavascriptReverseRoute( "controllers.User.getUserRequests", """ @@ -373,7 +404,7 @@ ) -// @LINE:8 +// @LINE:9 def getUser = JavascriptReverseRoute( "controllers.User.getUser", """ @@ -384,7 +415,18 @@ ) -// @LINE:10 +// @LINE:7 +def getAllUsers = JavascriptReverseRoute( + "controllers.User.getAllUsers", + """ + function() { + return _wA({method:"GET", url:"/users/all"}) + } + """ +) + + +// @LINE:11 def getUserConsensus = JavascriptReverseRoute( "controllers.User.getUserConsensus", """ @@ -395,7 +437,7 @@ ) -// @LINE:11 +// @LINE:12 def getUserClaims = JavascriptReverseRoute( "controllers.User.getUserClaims", """ @@ -414,15 +456,17 @@ -// @LINE:28 -// @LINE:24 -// @LINE:23 +// @LINE:30 +// @LINE:26 +// @LINE:25 +// @LINE:21 +// @LINE:20 // @LINE:19 -// @LINE:18 -// @LINE:17 // @LINE:16 +// @LINE:15 // @LINE:14 // @LINE:13 +// @LINE:12 // @LINE:11 // @LINE:10 // @LINE:9 @@ -431,10 +475,11 @@ // @LINE:6 package controllers.ref { +// @LINE:21 +// @LINE:20 // @LINE:19 -// @LINE:18 -// @LINE:17 // @LINE:16 +// @LINE:15 // @LINE:14 // @LINE:13 class ReverseClaim { @@ -442,24 +487,30 @@ -// @LINE:16 +// @LINE:19 def crateClaim() = new play.api.mvc.HandlerRef( controllers.Claim.crateClaim(), HandlerDef(this, "controllers.Claim", "crateClaim", Seq()) ) -// @LINE:18 +// @LINE:21 def editClaim(id:String) = new play.api.mvc.HandlerRef( controllers.Claim.editClaim(id), HandlerDef(this, "controllers.Claim", "editClaim", Seq(classOf[String])) ) -// @LINE:17 +// @LINE:20 def createMention(mentionType:String, id:String) = new play.api.mvc.HandlerRef( controllers.Claim.createMention(mentionType, id), HandlerDef(this, "controllers.Claim", "createMention", Seq(classOf[String], classOf[String])) ) +// @LINE:16 +def getUserConsensusStatus(id:String, name:String) = new play.api.mvc.HandlerRef( + controllers.Claim.getUserConsensusStatus(id, name), HandlerDef(this, "controllers.Claim", "getUserConsensusStatus", Seq(classOf[String], classOf[String])) +) + + // @LINE:13 def getClaimInfo(id:String) = new play.api.mvc.HandlerRef( controllers.Claim.getClaimInfo(id), HandlerDef(this, "controllers.Claim", "getClaimInfo", Seq(classOf[String])) @@ -477,15 +528,15 @@ } -// @LINE:24 -// @LINE:23 +// @LINE:26 +// @LINE:25 // @LINE:6 class ReverseApplication { -// @LINE:24 +// @LINE:26 def test() = new play.api.mvc.HandlerRef( controllers.Application.test(), HandlerDef(this, "controllers.Application", "test", Seq()) ) @@ -497,7 +548,7 @@ ) -// @LINE:23 +// @LINE:25 def hello() = new play.api.mvc.HandlerRef( controllers.Application.hello(), HandlerDef(this, "controllers.Application", "hello", Seq()) ) @@ -508,13 +559,13 @@ } -// @LINE:28 +// @LINE:30 class ReverseAssets { -// @LINE:28 +// @LINE:30 def at(path:String, file:String) = new play.api.mvc.HandlerRef( controllers.Assets.at(path, file), HandlerDef(this, "controllers.Assets", "at", Seq(classOf[String], classOf[String])) ) @@ -525,6 +576,7 @@ } +// @LINE:12 // @LINE:11 // @LINE:10 // @LINE:9 @@ -535,31 +587,37 @@ -// @LINE:7 +// @LINE:8 def createUser(name:String) = new play.api.mvc.HandlerRef( controllers.User.createUser(name), HandlerDef(this, "controllers.User", "createUser", Seq(classOf[String])) ) -// @LINE:9 +// @LINE:10 def getUserRequests(name:String) = new play.api.mvc.HandlerRef( controllers.User.getUserRequests(name), HandlerDef(this, "controllers.User", "getUserRequests", Seq(classOf[String])) ) -// @LINE:8 +// @LINE:9 def getUser(name:String) = new play.api.mvc.HandlerRef( controllers.User.getUser(name), HandlerDef(this, "controllers.User", "getUser", Seq(classOf[String])) ) -// @LINE:10 +// @LINE:7 +def getAllUsers() = new play.api.mvc.HandlerRef( + controllers.User.getAllUsers(), HandlerDef(this, "controllers.User", "getAllUsers", Seq()) +) + + +// @LINE:11 def getUserConsensus(name:String) = new play.api.mvc.HandlerRef( controllers.User.getUserConsensus(name), HandlerDef(this, "controllers.User", "getUserConsensus", Seq(classOf[String])) ) -// @LINE:11 +// @LINE:12 def getUserClaims(name:String) = new play.api.mvc.HandlerRef( controllers.User.getUserClaims(name), HandlerDef(this, "controllers.User", "getUserClaims", Seq(classOf[String])) )
--- a/target/scala-2.9.1/src_managed/main/routes_routing.scala Thu Oct 04 01:39:44 2012 +0900 +++ b/target/scala-2.9.1/src_managed/main/routes_routing.scala Thu Oct 04 01:59:21 2012 +0900 @@ -1,6 +1,6 @@ // @SOURCE:/Users/aotokage/workspace/Consensus/conf/routes -// @HASH:9e0fa937ed92ecd1dae3165cbcac7424dc77d60f -// @DATE:Wed Oct 03 23:35:23 JST 2012 +// @HASH:0d161c51591c2cc11bf38fb7f107b713d79cc370 +// @DATE:Thu Oct 04 01:56:05 JST 2012 import play.core._ import play.core.Router._ @@ -19,61 +19,69 @@ // @LINE:7 -val controllers_User_createUser1 = Route("PUT", PathPattern(List(StaticPart("/users/create/"),DynamicPart("name", """[^/]+""")))) +val controllers_User_getAllUsers1 = Route("GET", PathPattern(List(StaticPart("/users/all")))) // @LINE:8 -val controllers_User_getUser2 = Route("GET", PathPattern(List(StaticPart("/users/browse/"),DynamicPart("name", """[^/]+""")))) +val controllers_User_createUser2 = Route("PUT", PathPattern(List(StaticPart("/users/create/"),DynamicPart("name", """[^/]+""")))) // @LINE:9 -val controllers_User_getUserRequests3 = Route("GET", PathPattern(List(StaticPart("/users/requests/"),DynamicPart("name", """[^/]+""")))) +val controllers_User_getUser3 = Route("GET", PathPattern(List(StaticPart("/users/browse/"),DynamicPart("name", """[^/]+""")))) // @LINE:10 -val controllers_User_getUserConsensus4 = Route("GET", PathPattern(List(StaticPart("/users/consensus/"),DynamicPart("name", """[^/]+""")))) +val controllers_User_getUserRequests4 = Route("GET", PathPattern(List(StaticPart("/users/requests/"),DynamicPart("name", """[^/]+""")))) // @LINE:11 -val controllers_User_getUserClaims5 = Route("GET", PathPattern(List(StaticPart("/users/claims/"),DynamicPart("name", """[^/]+""")))) +val controllers_User_getUserConsensus5 = Route("GET", PathPattern(List(StaticPart("/users/consensus/"),DynamicPart("name", """[^/]+""")))) + + +// @LINE:12 +val controllers_User_getUserClaims6 = Route("GET", PathPattern(List(StaticPart("/users/claims/"),DynamicPart("name", """[^/]+""")))) // @LINE:13 -val controllers_Claim_getClaimInfo6 = Route("GET", PathPattern(List(StaticPart("/claims/browse/"),DynamicPart("id", """[^/]+""")))) +val controllers_Claim_getClaimInfo7 = Route("GET", PathPattern(List(StaticPart("/claims/browse/"),DynamicPart("id", """[^/]+""")))) // @LINE:14 -val controllers_Claim_getClaimTree7 = Route("GET", PathPattern(List(StaticPart("/claims/consensus/"),DynamicPart("id", """[^/]+""")))) +val controllers_Claim_getClaimTree8 = Route("GET", PathPattern(List(StaticPart("/claims/consensus/"),DynamicPart("id", """[^/]+""")))) + + +// @LINE:15 +val controllers_Claim_getClaimTree9 = Route("GET", PathPattern(List(StaticPart("/consensus/browse/"),DynamicPart("id", """[^/]+""")))) // @LINE:16 -val controllers_Claim_crateClaim8 = Route("POST", PathPattern(List(StaticPart("/claims/create")))) - - -// @LINE:17 -val controllers_Claim_createMention9 = Route("POST", PathPattern(List(StaticPart("/claims/"),DynamicPart("mentionType", """[^/]+"""),StaticPart("/"),DynamicPart("id", """[^/]+"""),StaticPart("/create")))) - - -// @LINE:18 -val controllers_Claim_editClaim10 = Route("POST", PathPattern(List(StaticPart("/claims/edit/"),DynamicPart("id", """[^/]+""")))) +val controllers_Claim_getUserConsensusStatus10 = Route("GET", PathPattern(List(StaticPart("/claims/answer/"),DynamicPart("id", """[^/]+"""),StaticPart("/"),DynamicPart("name", """[^/]+""")))) // @LINE:19 -val controllers_Claim_getClaimTree11 = Route("GET", PathPattern(List(StaticPart("/consensus/browse/"),DynamicPart("id", """[^/]+""")))) +val controllers_Claim_crateClaim11 = Route("POST", PathPattern(List(StaticPart("/claims/create")))) -// @LINE:23 -val controllers_Application_hello12 = Route("POST", PathPattern(List(StaticPart("/hello")))) +// @LINE:20 +val controllers_Claim_createMention12 = Route("POST", PathPattern(List(StaticPart("/claims/"),DynamicPart("mentionType", """[^/]+"""),StaticPart("/"),DynamicPart("id", """[^/]+"""),StaticPart("/create")))) + + +// @LINE:21 +val controllers_Claim_editClaim13 = Route("POST", PathPattern(List(StaticPart("/claims/edit/"),DynamicPart("id", """[^/]+""")))) -// @LINE:24 -val controllers_Application_test13 = Route("GET", PathPattern(List(StaticPart("/test")))) +// @LINE:25 +val controllers_Application_hello14 = Route("POST", PathPattern(List(StaticPart("/hello")))) -// @LINE:28 -val controllers_Assets_at14 = Route("GET", PathPattern(List(StaticPart("/assets/"),DynamicPart("file", """.+""")))) +// @LINE:26 +val controllers_Application_test15 = Route("GET", PathPattern(List(StaticPart("/test")))) -def documentation = List(("""GET""","""/""","""controllers.Application.index()"""),("""PUT""","""/users/create/$name<[^/]+>""","""controllers.User.createUser(name:String)"""),("""GET""","""/users/browse/$name<[^/]+>""","""controllers.User.getUser(name:String)"""),("""GET""","""/users/requests/$name<[^/]+>""","""controllers.User.getUserRequests(name:String)"""),("""GET""","""/users/consensus/$name<[^/]+>""","""controllers.User.getUserConsensus(name:String)"""),("""GET""","""/users/claims/$name<[^/]+>""","""controllers.User.getUserClaims(name:String)"""),("""GET""","""/claims/browse/$id<[^/]+>""","""controllers.Claim.getClaimInfo(id:String)"""),("""GET""","""/claims/consensus/$id<[^/]+>""","""controllers.Claim.getClaimTree(id:String)"""),("""POST""","""/claims/create""","""controllers.Claim.crateClaim()"""),("""POST""","""/claims/$mentionType<[^/]+>/$id<[^/]+>/create""","""controllers.Claim.createMention(mentionType:String, id:String)"""),("""POST""","""/claims/edit/$id<[^/]+>""","""controllers.Claim.editClaim(id:String)"""),("""GET""","""/consensus/browse/$id<[^/]+>""","""controllers.Claim.getClaimTree(id:String)"""),("""POST""","""/hello""","""controllers.Application.hello()"""),("""GET""","""/test""","""controllers.Application.test()"""),("""GET""","""/assets/$file<.+>""","""controllers.Assets.at(path:String = "/public", file:String)""")) + +// @LINE:30 +val controllers_Assets_at16 = Route("GET", PathPattern(List(StaticPart("/assets/"),DynamicPart("file", """.+""")))) + +def documentation = List(("""GET""","""/""","""controllers.Application.index()"""),("""GET""","""/users/all""","""controllers.User.getAllUsers()"""),("""PUT""","""/users/create/$name<[^/]+>""","""controllers.User.createUser(name:String)"""),("""GET""","""/users/browse/$name<[^/]+>""","""controllers.User.getUser(name:String)"""),("""GET""","""/users/requests/$name<[^/]+>""","""controllers.User.getUserRequests(name:String)"""),("""GET""","""/users/consensus/$name<[^/]+>""","""controllers.User.getUserConsensus(name:String)"""),("""GET""","""/users/claims/$name<[^/]+>""","""controllers.User.getUserClaims(name:String)"""),("""GET""","""/claims/browse/$id<[^/]+>""","""controllers.Claim.getClaimInfo(id:String)"""),("""GET""","""/claims/consensus/$id<[^/]+>""","""controllers.Claim.getClaimTree(id:String)"""),("""GET""","""/consensus/browse/$id<[^/]+>""","""controllers.Claim.getClaimTree(id:String)"""),("""GET""","""/claims/answer/$id<[^/]+>/$name<[^/]+>""","""controllers.Claim.getUserConsensusStatus(id:String, name:String)"""),("""POST""","""/claims/create""","""controllers.Claim.crateClaim()"""),("""POST""","""/claims/$mentionType<[^/]+>/$id<[^/]+>/create""","""controllers.Claim.createMention(mentionType:String, id:String)"""),("""POST""","""/claims/edit/$id<[^/]+>""","""controllers.Claim.editClaim(id:String)"""),("""POST""","""/hello""","""controllers.Application.hello()"""),("""GET""","""/test""","""controllers.Application.test()"""),("""GET""","""/assets/$file<.+>""","""controllers.Assets.at(path:String = "/public", file:String)""")) def routes:PartialFunction[RequestHeader,Handler] = { @@ -87,39 +95,47 @@ // @LINE:7 -case controllers_User_createUser1(params) => { +case controllers_User_getAllUsers1(params) => { + call { + invokeHandler(_root_.controllers.User.getAllUsers(), HandlerDef(this, "controllers.User", "getAllUsers", Nil)) + } +} + + +// @LINE:8 +case controllers_User_createUser2(params) => { call(params.fromPath[String]("name", None)) { (name) => invokeHandler(_root_.controllers.User.createUser(name), HandlerDef(this, "controllers.User", "createUser", Seq(classOf[String]))) } } -// @LINE:8 -case controllers_User_getUser2(params) => { +// @LINE:9 +case controllers_User_getUser3(params) => { call(params.fromPath[String]("name", None)) { (name) => invokeHandler(_root_.controllers.User.getUser(name), HandlerDef(this, "controllers.User", "getUser", Seq(classOf[String]))) } } -// @LINE:9 -case controllers_User_getUserRequests3(params) => { +// @LINE:10 +case controllers_User_getUserRequests4(params) => { call(params.fromPath[String]("name", None)) { (name) => invokeHandler(_root_.controllers.User.getUserRequests(name), HandlerDef(this, "controllers.User", "getUserRequests", Seq(classOf[String]))) } } -// @LINE:10 -case controllers_User_getUserConsensus4(params) => { +// @LINE:11 +case controllers_User_getUserConsensus5(params) => { call(params.fromPath[String]("name", None)) { (name) => invokeHandler(_root_.controllers.User.getUserConsensus(name), HandlerDef(this, "controllers.User", "getUserConsensus", Seq(classOf[String]))) } } -// @LINE:11 -case controllers_User_getUserClaims5(params) => { +// @LINE:12 +case controllers_User_getUserClaims6(params) => { call(params.fromPath[String]("name", None)) { (name) => invokeHandler(_root_.controllers.User.getUserClaims(name), HandlerDef(this, "controllers.User", "getUserClaims", Seq(classOf[String]))) } @@ -127,7 +143,7 @@ // @LINE:13 -case controllers_Claim_getClaimInfo6(params) => { +case controllers_Claim_getClaimInfo7(params) => { call(params.fromPath[String]("id", None)) { (id) => invokeHandler(_root_.controllers.Claim.getClaimInfo(id), HandlerDef(this, "controllers.Claim", "getClaimInfo", Seq(classOf[String]))) } @@ -135,7 +151,15 @@ // @LINE:14 -case controllers_Claim_getClaimTree7(params) => { +case controllers_Claim_getClaimTree8(params) => { + call(params.fromPath[String]("id", None)) { (id) => + invokeHandler(_root_.controllers.Claim.getClaimTree(id), HandlerDef(this, "controllers.Claim", "getClaimTree", Seq(classOf[String]))) + } +} + + +// @LINE:15 +case controllers_Claim_getClaimTree9(params) => { call(params.fromPath[String]("id", None)) { (id) => invokeHandler(_root_.controllers.Claim.getClaimTree(id), HandlerDef(this, "controllers.Claim", "getClaimTree", Seq(classOf[String]))) } @@ -143,55 +167,55 @@ // @LINE:16 -case controllers_Claim_crateClaim8(params) => { +case controllers_Claim_getUserConsensusStatus10(params) => { + call(params.fromPath[String]("id", None), params.fromPath[String]("name", None)) { (id, name) => + invokeHandler(_root_.controllers.Claim.getUserConsensusStatus(id, name), HandlerDef(this, "controllers.Claim", "getUserConsensusStatus", Seq(classOf[String], classOf[String]))) + } +} + + +// @LINE:19 +case controllers_Claim_crateClaim11(params) => { call { invokeHandler(_root_.controllers.Claim.crateClaim(), HandlerDef(this, "controllers.Claim", "crateClaim", Nil)) } } -// @LINE:17 -case controllers_Claim_createMention9(params) => { +// @LINE:20 +case controllers_Claim_createMention12(params) => { call(params.fromPath[String]("mentionType", None), params.fromPath[String]("id", None)) { (mentionType, id) => invokeHandler(_root_.controllers.Claim.createMention(mentionType, id), HandlerDef(this, "controllers.Claim", "createMention", Seq(classOf[String], classOf[String]))) } } -// @LINE:18 -case controllers_Claim_editClaim10(params) => { +// @LINE:21 +case controllers_Claim_editClaim13(params) => { call(params.fromPath[String]("id", None)) { (id) => invokeHandler(_root_.controllers.Claim.editClaim(id), HandlerDef(this, "controllers.Claim", "editClaim", Seq(classOf[String]))) } } -// @LINE:19 -case controllers_Claim_getClaimTree11(params) => { - call(params.fromPath[String]("id", None)) { (id) => - invokeHandler(_root_.controllers.Claim.getClaimTree(id), HandlerDef(this, "controllers.Claim", "getClaimTree", Seq(classOf[String]))) - } -} - - -// @LINE:23 -case controllers_Application_hello12(params) => { +// @LINE:25 +case controllers_Application_hello14(params) => { call { invokeHandler(_root_.controllers.Application.hello(), HandlerDef(this, "controllers.Application", "hello", Nil)) } } -// @LINE:24 -case controllers_Application_test13(params) => { +// @LINE:26 +case controllers_Application_test15(params) => { call { invokeHandler(_root_.controllers.Application.test(), HandlerDef(this, "controllers.Application", "test", Nil)) } } -// @LINE:28 -case controllers_Assets_at14(params) => { +// @LINE:30 +case controllers_Assets_at16(params) => { call(Param[String]("path", Right("/public")), params.fromPath[String]("file", None)) { (path, file) => invokeHandler(_root_.controllers.Assets.at(path, file), HandlerDef(this, "controllers.Assets", "at", Seq(classOf[String], classOf[String]))) }