From d9a3eb2fef55d273e8b5bb3c28b598a82b59ac8b Mon Sep 17 00:00:00 2001 From: Sebastian Sdorra Date: Sun, 3 Jul 2011 20:14:24 +0200 Subject: [PATCH] improve javadoc --- .../java/sonia/scm/ConfigChangedListener.java | 2 +- .../src/main/java/sonia/scm/Initable.java | 2 +- .../main/java/sonia/scm/ListenerSupport.java | 2 +- scm-core/src/main/java/sonia/scm/Manager.java | 25 ++++----- .../src/main/java/sonia/scm/Platform.java | 55 +++++++++---------- .../src/main/java/sonia/scm/ScmState.java | 19 +++---- 6 files changed, 51 insertions(+), 54 deletions(-) diff --git a/scm-core/src/main/java/sonia/scm/ConfigChangedListener.java b/scm-core/src/main/java/sonia/scm/ConfigChangedListener.java index f29e151559..a0b04943cd 100644 --- a/scm-core/src/main/java/sonia/scm/ConfigChangedListener.java +++ b/scm-core/src/main/java/sonia/scm/ConfigChangedListener.java @@ -46,7 +46,7 @@ public interface ConfigChangedListener * * * - * @param config + * @param config - the changed configuration object */ public void configChanged(Object config); } diff --git a/scm-core/src/main/java/sonia/scm/Initable.java b/scm-core/src/main/java/sonia/scm/Initable.java index ac4bc3dcd6..526faabaab 100644 --- a/scm-core/src/main/java/sonia/scm/Initable.java +++ b/scm-core/src/main/java/sonia/scm/Initable.java @@ -46,7 +46,7 @@ public interface Initable * * * - * @param context + * @param context - the context provider of the SCM-Manager */ public void init(SCMContextProvider context); } diff --git a/scm-core/src/main/java/sonia/scm/ListenerSupport.java b/scm-core/src/main/java/sonia/scm/ListenerSupport.java index e4c6eb9ee7..fcaf3628c5 100644 --- a/scm-core/src/main/java/sonia/scm/ListenerSupport.java +++ b/scm-core/src/main/java/sonia/scm/ListenerSupport.java @@ -59,7 +59,7 @@ public interface ListenerSupport * Register a {@link java.util.Collection} of listeners. * * - * @param listeners + * @param listeners to register */ public void addListeners(Collection listeners); diff --git a/scm-core/src/main/java/sonia/scm/Manager.java b/scm-core/src/main/java/sonia/scm/Manager.java index 18fba1e1b6..600ab268ca 100644 --- a/scm-core/src/main/java/sonia/scm/Manager.java +++ b/scm-core/src/main/java/sonia/scm/Manager.java @@ -56,7 +56,7 @@ public interface Manager * Reloads a object from store and overwrites all changes. * * - * @param object + * @param object to refresh * * @throws E * @throws IOException @@ -94,33 +94,32 @@ public interface Manager public Collection getAll(Comparator comparator); /** - * Returns all objects from the store which are between the given start and - * end parameter. + * Returns objects from the store which are starts at the given start + * parameter. The objects returned are limited by the limit parameter. * * * @param start parameter - * @param limit + * @param limit parameter * * @since 1.4 - * @returnall objects from the store which are between the given start and - * end parameter - * - * @return + * @return objects from the store which are starts at the given + * start parameter */ public Collection getAll(int start, int limit); /** - * Returns all objects from the store which are between the given start and - * end parameter sorted by the given comparator. + * Returns objects from the store which are starts at the given start + * parameter sorted by the given {@link java.util.Comparator}. + * The objects returned are limited by the limit parameter. * * * @param comparator to sort the returned objects * @param start parameter - * @param limit + * @param limit parameter * * @since 1.4 - * @return all objects from the store which are between the given start and - * end parameter sorted by the given comparator + * @return objects from the store which are starts at the given + * start parameter */ public Collection getAll(Comparator comparator, int start, int limit); } diff --git a/scm-core/src/main/java/sonia/scm/Platform.java b/scm-core/src/main/java/sonia/scm/Platform.java index 854f797fc0..bb62025872 100644 --- a/scm-core/src/main/java/sonia/scm/Platform.java +++ b/scm-core/src/main/java/sonia/scm/Platform.java @@ -51,8 +51,7 @@ public class Platform * * @param osName - name of the operation system * @param archModel - name of the host architecture model - * @param archModel - name of the operation system architecture - * @param osArch + * @param osArch - name of the operation system architecture */ public Platform(String osName, String archModel, String osArch) { @@ -76,10 +75,10 @@ public class Platform //~--- methods -------------------------------------------------------------- /** - * Returns true if the operating system is 32 bit operating system. + * Returns true if the operating system is a 32 bit operating system. * * - * @return true if the operating system is 32 bit operating system + * @return true if the operating system is a 32 bit operating system */ public boolean is32Bit() { @@ -87,10 +86,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a 64 a bit operating system. * * - * @return + * @return true if the operating system is a 64 a bit operating system */ public boolean is64Bit() { @@ -100,10 +99,10 @@ public class Platform //~--- get methods ---------------------------------------------------------- /** - * Method description + * Returns the architecture of the platform. * * - * @return + * @return the architecture of the platform */ public String getArch() { @@ -111,10 +110,10 @@ public class Platform } /** - * Method description + * Returns the name of the platform. * * - * @return + * @return name of the platform */ public String getName() { @@ -122,10 +121,10 @@ public class Platform } /** - * Method description + * Returns the type of the platform. * * - * @return + * @return type of the platform */ public PlatformType getType() { @@ -133,10 +132,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a FreeBSD. * * - * @return + * @return true if the operating system is a FreeBSD */ public boolean isFreeBSD() { @@ -144,10 +143,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a Linux. * * - * @return + * @return true if the operating system is a Linux */ public boolean isLinux() { @@ -155,10 +154,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a Mac OS. * * - * @return + * @return true if the operating system is a Mac OS */ public boolean isMac() { @@ -166,10 +165,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a OpenBSD. * * - * @return + * @return true if the operating system is a OpenBSD */ public boolean isOpenBSD() { @@ -177,10 +176,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system has posix support. * * - * @return + * @return true if the operating system has posix support */ public boolean isPosix() { @@ -188,10 +187,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a Solaris. * * - * @return + * @return true if the operating system is a Solaris */ public boolean isSolaris() { @@ -199,10 +198,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a Unix system. * * - * @return + * @return true if the operating system is a Unix system */ public boolean isUnix() { @@ -210,10 +209,10 @@ public class Platform } /** - * Method description + * Returns true if the operating system is a Windows. * * - * @return + * @return true if the operating system is a Windows */ public boolean isWindows() { diff --git a/scm-core/src/main/java/sonia/scm/ScmState.java b/scm-core/src/main/java/sonia/scm/ScmState.java index a0a6a297e9..bb838c4dd2 100644 --- a/scm-core/src/main/java/sonia/scm/ScmState.java +++ b/scm-core/src/main/java/sonia/scm/ScmState.java @@ -68,10 +68,10 @@ public class ScmState * Constructs {@link ScmState} object. * * - * @param provider - * @param securityContext - * @param repositoryTypes - * @param clientConfig + * @param provider - context provider + * @param securityContext - security context of the current user + * @param repositoryTypes - available repository types + * @param clientConfig - client configuration */ public ScmState(SCMContextProvider provider, WebSecurityContext securityContext, @@ -161,7 +161,7 @@ public class ScmState * * * - * @param clientConfig + * @param clientConfig - client configuration */ public void setClientConfig(ScmClientConfig clientConfig) { @@ -173,7 +173,7 @@ public class ScmState * * * - * @param groups + * @param groups - collection of group names */ public void setGroups(Collection groups) { @@ -185,7 +185,7 @@ public class ScmState * * * - * @param repositoryTypes + * @param repositoryTypes - collection of available repository types */ public void setRepositoryTypes(Collection repositoryTypes) { @@ -208,7 +208,7 @@ public class ScmState * * * - * @param user + * @param user - the current user */ public void setUser(User user) { @@ -219,8 +219,7 @@ public class ScmState * Setter for the SCM-Manager version. * * - * - * @param version + * @param version - SCM-Manager version */ public void setVersion(String version) {