From 53fb8c894e12607f6c2552af182ee23f1db8e9a2 Mon Sep 17 00:00:00 2001
From: Kai Reinhard <K.Reinhard@micromata.de>
Date: Fri, 18 Jan 2019 06:28:05 +0000
Subject: [PATCH] JavaDoc fixed.

---
 borgbutler-server/src/main/java/de/micromata/borgbutler/server/rest/ReposRest.java |   30 ++++++++++++++++++++++--------
 1 files changed, 22 insertions(+), 8 deletions(-)

diff --git a/borgbutler-server/src/main/java/de/micromata/borgbutler/server/rest/ReposRest.java b/borgbutler-server/src/main/java/de/micromata/borgbutler/server/rest/ReposRest.java
index 3152f1c..a7673f7 100644
--- a/borgbutler-server/src/main/java/de/micromata/borgbutler/server/rest/ReposRest.java
+++ b/borgbutler-server/src/main/java/de/micromata/borgbutler/server/rest/ReposRest.java
@@ -19,15 +19,15 @@
 public class ReposRest {
     private static Logger log = LoggerFactory.getLogger(ReposRest.class);
 
-    @GET
-    @Path("list")
-    @Produces(MediaType.APPLICATION_JSON)
     /**
      *
      * @param prettyPrinter If true then the json output will be in pretty format.
      * @return A list of repositories of type {@link BorgRepository}.
      * @see JsonUtils#toJson(Object, boolean)
      */
+    @GET
+    @Path("list")
+    @Produces(MediaType.APPLICATION_JSON)
     public String getList(@QueryParam("prettyPrinter") boolean prettyPrinter) {
         List<Repository> repositories = ButlerCache.getInstance().getAllRepositories();
         if (CollectionUtils.isEmpty(repositories)) {
@@ -36,25 +36,36 @@
         return JsonUtils.toJson(repositories, prettyPrinter);
     }
 
-    @GET
-    @Path("repo")
-    @Produces(MediaType.APPLICATION_JSON)
     /**
      *
      * @param id id or name of repo.
-     * @param force If true, a reload of all repositories is forced.
      * @param prettyPrinter If true then the json output will be in pretty format.
      * @return Repository (without list of archives) as json string.
      * @see JsonUtils#toJson(Object, boolean)
      */
+    @GET
+    @Path("repo")
+    @Produces(MediaType.APPLICATION_JSON)
     public String getRepo(@QueryParam("id") String id, @QueryParam("prettyPrinter") boolean prettyPrinter) {
         Repository repository = ButlerCache.getInstance().getRepository(id);
         return JsonUtils.toJson(repository, prettyPrinter);
     }
 
+    /**
+     *
+     * @param id id or name of repo.
+     * @param prettyPrinter If true then the json output will be in pretty format.
+     * @return BorgRepoConf as json string.
+     * @see JsonUtils#toJson(Object, boolean)
+     */
     @GET
-    @Path("repoArchiveList")
+    @Path("repo-config")
     @Produces(MediaType.APPLICATION_JSON)
+    public String getRepoConfig(@QueryParam("id") String id, @QueryParam("prettyPrinter") boolean prettyPrinter) {
+        Repository repository = ButlerCache.getInstance().getRepository(id);
+        return JsonUtils.toJson(repository, prettyPrinter);
+    }
+
     /**
      *
      * @param id id or name of repo.
@@ -62,6 +73,9 @@
      * @return Repository (including list of archives) as json string.
      * @see JsonUtils#toJson(Object, boolean)
      */
+    @GET
+    @Path("repoArchiveList")
+    @Produces(MediaType.APPLICATION_JSON)
     public String getRepoArchiveList(@QueryParam("id") String id, @QueryParam("force") boolean force,
                                      @QueryParam("prettyPrinter") boolean prettyPrinter) {
         if (force) {

--
Gitblit v1.10.0