package binding

type handlerBase struct{ service Service }

type CollectionHandler struct{ handlerBase }
type DetailHandler struct{ handlerBase }
type RevisionHandler struct{ handlerBase }
type ValidationHandler struct{ handlerBase }

type routeHandlers struct {
	collection *CollectionHandler
	detail     *DetailHandler
	revisions  *RevisionHandler
	validation *ValidationHandler
}

func newRouteHandlers(service Service) routeHandlers {
	base := handlerBase{service: service}
	return routeHandlers{
		collection: &CollectionHandler{handlerBase: base},
		detail:     &DetailHandler{handlerBase: base},
		revisions:  &RevisionHandler{handlerBase: base},
		validation: &ValidationHandler{handlerBase: base},
	}
}
