Klasse DUUIComponentRequestHandler
java.lang.Object
org.texttechnologylab.duui.api.routes.components.DUUIComponentRequestHandler
A class that is responsible for handling incoming requests to the /components path group.
- Autor:
- Cedric Borkowksi
- 
FeldübersichtFelder
- 
KonstruktorübersichtKonstruktoren
- 
MethodenübersichtModifizierer und TypMethodeBeschreibungstatic StringdeleteOne(spark.Request request, spark.Response response) Attemps to delete a component given its id.static StringfindMany(spark.Request request, spark.Response response) Finds many components by its userID extracted from the request and components that are marked as templates by not having a user_id field set.static StringfindOne(spark.Request request, spark.Response response) Finds one component by its id extracted from the request url.static StringinsertOne(spark.Request request, spark.Response response) Inserts a new Component into the Database.static StringupdateOne(spark.Request request, spark.Response response) Updates one component by its id extracted from the url.
- 
Felddetails- 
DRIVERSA set of all available drivers.
 
- 
- 
Konstruktordetails- 
DUUIComponentRequestHandlerpublic DUUIComponentRequestHandler()
 
- 
- 
Methodendetails- 
insertOneInserts a new Component into the Database. If no user_id or no pipeline_id is specified, the component is inserted as a template. SeeDUUIComponentController.insertOne(Document)- Parameter:
- request- Request object
- response- Response object
- Gibt zurück:
- Response message
 
- 
findOneFinds one component by its id extracted from the request url. SeeDUUIComponentController.findOneById(String)- Gibt zurück:
- A Json String containing the component or a not found message.
 
- 
findManyFinds many components by its userID extracted from the request and components that are marked as templates by not having a user_id field set. SeeDUUIComponentController.findMany(MongoDBFilters)- Gibt zurück:
- A Json String containing the components or a not found message.
 
- 
updateOneUpdates one component by its id extracted from the url. The updates to be performed are provided in the request body in the Json format. SeeDUUIComponentController.updateOne(String, Document)- Gibt zurück:
- A Json String containing the updated component or a not found message.
 
- 
deleteOneAttemps to delete a component given its id. SeeDUUIComponentController.deleteOne(String)- Gibt zurück:
- Confirmation of deletion or a not found message.
 
 
-