All Downloads are FREE. Search and download functionalities are using the official Maven repository.

atlassian.connect.Routes.scala Maven / Gradle / Ivy

The newest version!
// @GENERATOR:play-routes-compiler
// @SOURCE:modules/core/conf/atlassian.connect.routes

package atlassian.connect

import play.core.routing._
import play.core.routing.HandlerInvokerFactory._

import play.api.mvc._

import _root_.controllers.Assets.Asset

class Routes(
  override val errorHandler: play.api.http.HttpErrorHandler, 
  // @LINE:2
  LifecycleController_0: io.toolsplus.atlassian.connect.play.controllers.LifecycleController,
  val prefix: String
) extends GeneratedRouter {

  @javax.inject.Inject()
  def this(errorHandler: play.api.http.HttpErrorHandler,
    // @LINE:2
    LifecycleController_0: io.toolsplus.atlassian.connect.play.controllers.LifecycleController
  ) = this(errorHandler, LifecycleController_0, "/")

  def withPrefix(addPrefix: String): Routes = {
    val prefix = play.api.routing.Router.concatPrefix(addPrefix, this.prefix)
    atlassian.connect.RoutesPrefix.setPrefix(prefix)
    new Routes(errorHandler, LifecycleController_0, prefix)
  }

  private val defaultPrefix: String = {
    if (this.prefix.endsWith("/")) "" else "/"
  }

  def documentation = List(
    ("""POST""", this.prefix + (if(this.prefix.endsWith("/")) "" else "/") + """installed""", """io.toolsplus.atlassian.connect.play.controllers.LifecycleController.installed"""),
    ("""POST""", this.prefix + (if(this.prefix.endsWith("/")) "" else "/") + """uninstalled""", """io.toolsplus.atlassian.connect.play.controllers.LifecycleController.uninstalled"""),
    Nil
  ).foldLeft(Seq.empty[(String, String, String)]) { (s,e) => e.asInstanceOf[Any] match {
    case r @ (_,_,_) => s :+ r.asInstanceOf[(String, String, String)]
    case l => s ++ l.asInstanceOf[List[(String, String, String)]]
  }}


  // @LINE:2
  private lazy val io_toolsplus_atlassian_connect_play_controllers_LifecycleController_installed0_route = Route("POST",
    PathPattern(List(StaticPart(this.prefix), StaticPart(this.defaultPrefix), StaticPart("installed")))
  )
  private lazy val io_toolsplus_atlassian_connect_play_controllers_LifecycleController_installed0_invoker = createInvoker(
    LifecycleController_0.installed,
    play.api.routing.HandlerDef(this.getClass.getClassLoader,
      "atlassian.connect",
      "io.toolsplus.atlassian.connect.play.controllers.LifecycleController",
      "installed",
      Nil,
      "POST",
      this.prefix + """installed""",
      """Lifecycle events""",
      Seq()
    )
  )

  // @LINE:3
  private lazy val io_toolsplus_atlassian_connect_play_controllers_LifecycleController_uninstalled1_route = Route("POST",
    PathPattern(List(StaticPart(this.prefix), StaticPart(this.defaultPrefix), StaticPart("uninstalled")))
  )
  private lazy val io_toolsplus_atlassian_connect_play_controllers_LifecycleController_uninstalled1_invoker = createInvoker(
    LifecycleController_0.uninstalled,
    play.api.routing.HandlerDef(this.getClass.getClassLoader,
      "atlassian.connect",
      "io.toolsplus.atlassian.connect.play.controllers.LifecycleController",
      "uninstalled",
      Nil,
      "POST",
      this.prefix + """uninstalled""",
      """""",
      Seq()
    )
  )


  def routes: PartialFunction[RequestHeader, Handler] = {
  
    // @LINE:2
    case io_toolsplus_atlassian_connect_play_controllers_LifecycleController_installed0_route(params@_) =>
      call { 
        io_toolsplus_atlassian_connect_play_controllers_LifecycleController_installed0_invoker.call(LifecycleController_0.installed)
      }
  
    // @LINE:3
    case io_toolsplus_atlassian_connect_play_controllers_LifecycleController_uninstalled1_route(params@_) =>
      call { 
        io_toolsplus_atlassian_connect_play_controllers_LifecycleController_uninstalled1_invoker.call(LifecycleController_0.uninstalled)
      }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy