/** * Generated by API Builder - https://www.apibuilder.io * Service version: 1.0.1 * User agent: apibuilder app.apibuilder.io/catalystsquad/catalyst-squad-hello-world-example-api/1.0.1/play_2_6 */ package com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models package object bodyparsers { private def bodyParser[A](parser: _root_.play.api.mvc.BodyParser[_root_.play.api.libs.json.JsValue])( implicit ec: _root_.scala.concurrent.ExecutionContext, rds: _root_.play.api.libs.json.Reads[A] ): _root_.play.api.mvc.BodyParser[A] = parser.validate( _.validate[A].asEither.left.map(e => _root_.play.api.mvc.Results.BadRequest(_root_.play.api.libs.json.JsError.toJson(e)) ) ) def bodyParserHello(parser: _root_.play.api.mvc.BodyParser[_root_.play.api.libs.json.JsValue])( implicit ec: _root_.scala.concurrent.ExecutionContext, rds: _root_.play.api.libs.json.Reads[com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models.Hello] ): _root_.play.api.mvc.BodyParser[com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models.Hello] = bodyParser[com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models.Hello](parser) def bodyParserNewhello(parser: _root_.play.api.mvc.BodyParser[_root_.play.api.libs.json.JsValue])( implicit ec: _root_.scala.concurrent.ExecutionContext, rds: _root_.play.api.libs.json.Reads[com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models.Newhello] ): _root_.play.api.mvc.BodyParser[com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models.Newhello] = bodyParser[com.catalystsquad.catalyst.squad.hello.world.example.api.v1.models.Newhello](parser) }