Created
June 11, 2018 15:05
-
-
Save juancho088/a91fb5de41816eb5ba2934a2265f1ee8 to your computer and use it in GitHub Desktop.
Movie Controller Without Factory
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.myblockbuster.movies.controllers | |
import com.myblockbuster.core.Request | |
import com.myblockbuster.core.User | |
import com.myblockbuster.core.controllers.Controller | |
import com.myblockbuster.core.services.Service | |
import com.myblockbuster.movies.Movie | |
import com.myblockbuster.movies.services.MovieService | |
class MovieController: Controller<Movie> { | |
fun movie(request: Request?) : Any { | |
val service: Service<Movie, User> = MovieService() | |
return defaultRouting(Movie::class.java, request!!, service) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment