forked from loafle/openapi-generator-original
* First commit of the Java Play Framework server generator. It is highly based on Spring so there might me a couple of things that don't make sense (like options or parameters) for the Play Framework. * Fix suggestions in the PR discussion + add .bat and .sh file as requested. * Updated Readme.md file * Remove unused mustache file + fix baseName vs paramName in all the mustache files. * Add an CLI option to generate interface. These interfaces are implemented by the controllerImp and help to generate the code with an IDE like IntelliJ because on updates of the code the controllerImp must follow the contract of the interface. If it don't, IDE will provide support to generate missing functions or parameters. I also did some cleanup of options we don't use in Play Framework. * Fix the compilation error when we have a body which is a list or map. Doesn't fix the problem with the annotation itself. * Fix the problem with the Http.MultipartFormData.FilePart * Small fixes * Remove everything related to swagger-play. No need for annotation anymore because we export the swagger.json directly and show the documentation using swagger-ui with the direct path. Also added the sample. * Remove/Rename paramsX mustache because there is no more documentation. Remove unused file. updated sample * Fix the problem with default values that was not set correctly. * Small fix related to bad merging * Add handleException CLI options * Fix default values once and for all! * Update sample files + fix bug * Fix bug with body that is required and have a list as a parameter + add bean import for interface to prevent compilation error
35 lines
2.3 KiB
Plaintext
35 lines
2.3 KiB
Plaintext
# Routes
|
|
# This file defines all application routes (Higher priority routes first)
|
|
# ~~~~
|
|
|
|
GET /api controllers.ApiDocController.api
|
|
|
|
|
|
#Functions for Pet API
|
|
POST /v2/pet controllers.PetApiController.addPet()
|
|
DELETE /v2/pet/:petId controllers.PetApiController.deletePet(petId: Long)
|
|
GET /v2/pet/findByStatus controllers.PetApiController.findPetsByStatus()
|
|
GET /v2/pet/findByTags controllers.PetApiController.findPetsByTags()
|
|
GET /v2/pet/:petId controllers.PetApiController.getPetById(petId: Long)
|
|
PUT /v2/pet controllers.PetApiController.updatePet()
|
|
POST /v2/pet/:petId controllers.PetApiController.updatePetWithForm(petId: String)
|
|
POST /v2/pet/:petId/uploadImage controllers.PetApiController.uploadFile(petId: Long)
|
|
|
|
#Functions for Store API
|
|
DELETE /v2/store/order/:orderId controllers.StoreApiController.deleteOrder(orderId: String)
|
|
GET /v2/store/inventory controllers.StoreApiController.getInventory()
|
|
GET /v2/store/order/:orderId controllers.StoreApiController.getOrderById(orderId: String)
|
|
POST /v2/store/order controllers.StoreApiController.placeOrder()
|
|
|
|
#Functions for User API
|
|
POST /v2/user controllers.UserApiController.createUser()
|
|
POST /v2/user/createWithArray controllers.UserApiController.createUsersWithArrayInput()
|
|
POST /v2/user/createWithList controllers.UserApiController.createUsersWithListInput()
|
|
DELETE /v2/user/:username controllers.UserApiController.deleteUser(username: String)
|
|
GET /v2/user/:username controllers.UserApiController.getUserByName(username: String)
|
|
GET /v2/user/login controllers.UserApiController.loginUser()
|
|
GET /v2/user/logout controllers.UserApiController.logoutUser()
|
|
PUT /v2/user/:username controllers.UserApiController.updateUser(username: String)
|
|
|
|
# Map static resources from the /public folder to the /assets URL path
|
|
GET /assets/*file controllers.Assets.versioned(path="/public", file: Asset) |