Many javadoc fixes thanks to Celtic Minstrel

By: Dinnerbone <dinnerbone@dinnerbone.com>
This commit is contained in:
Bukkit/Spigot
2011-09-25 02:56:40 +01:00
parent 1968b78a12
commit a8e72bdb91
78 changed files with 380 additions and 335 deletions

View File

@@ -4,10 +4,9 @@ public class AuthorNagException extends RuntimeException {
private final String message;
/**
* Constructs a new UnknownDependencyException based on the given Exception
* Constructs a new AuthorNagException based on the given Exception
*
* @param message Brief message explaining the cause of the exception
* @param throwable Exception that triggered this Exception
*/
public AuthorNagException(final String message) {
this.message = message;

View File

@@ -16,7 +16,7 @@ public interface Plugin extends CommandExecutor {
* Returns the folder that the plugin data's files are located in. The
* folder may not yet exist.
*
* @return
* @return The folder
*/
public File getDataFolder();
@@ -30,7 +30,7 @@ public interface Plugin extends CommandExecutor {
/**
* Returns the main configuration file. It should be loaded.
*
* @return
* @return The configuration
*/
public Configuration getConfiguration();

View File

@@ -41,7 +41,8 @@ public final class PluginDescriptionFile {
/**
* Loads a PluginDescriptionFile from the specified reader
* @param reader
* @param reader The reader
* @throws InvalidDescriptionException If the PluginDescriptionFile is invalid
*/
@SuppressWarnings("unchecked")
public PluginDescriptionFile(final Reader reader) throws InvalidDescriptionException {
@@ -52,6 +53,7 @@ public final class PluginDescriptionFile {
* Creates a new PluginDescriptionFile with the given detailed
*
* @param pluginName Name of this plugin
* @param pluginVersion Version of this plugin
* @param mainClass Full location of the main class of this plugin
*/
public PluginDescriptionFile(final String pluginName, final String pluginVersion, final String mainClass) {
@@ -124,7 +126,7 @@ public final class PluginDescriptionFile {
/**
* Gets the description of this plugin
*
* return Description of this plugin
* @return Description of this plugin
*/
public String getDescription() {
return description;

View File

@@ -19,6 +19,8 @@ public interface PluginLoader {
* @return Plugin that was contained in the specified file, or null if
* unsuccessful
* @throws InvalidPluginException Thrown when the specified file is not a plugin
* @throws InvalidDescriptionException If the plugin description file was invalid
* @throws UnknownDependencyException If a required dependency could not be found
*/
public Plugin loadPlugin(File file) throws InvalidPluginException, InvalidDescriptionException, UnknownDependencyException;
@@ -30,11 +32,14 @@ public interface PluginLoader {
* @return Plugin that was contained in the specified file, or null if
* unsuccessful
* @throws InvalidPluginException Thrown when the specified file is not a plugin
* @throws InvalidDescriptionException If the plugin description file was invalid
* @throws UnknownDependencyException If a required dependency could not be found
*/
public Plugin loadPlugin(File file, boolean ignoreSoftDependencies) throws InvalidPluginException, InvalidDescriptionException, UnknownDependencyException;
/**
* Returns a list of all filename filters expected by this PluginLoader
* @return The filters
*/
public Pattern[] getPluginFileFilters();
@@ -43,6 +48,7 @@ public interface PluginLoader {
*
* @param type Type of the event executor to create
* @param listener the object that will handle the eventual call back
* @return The new executor
*/
public EventExecutor createExecutor(Event.Type type, Listener listener);

View File

@@ -66,6 +66,7 @@ public interface PluginManager {
* @return The Plugin loaded, or null if it was invalid
* @throws InvalidPluginException Thrown when the specified file is not a valid plugin
* @throws InvalidDescriptionException Thrown when the specified file contains an invalid description
* @throws UnknownDependencyException If a required dependency could not be resolved
*/
public Plugin loadPlugin(File file) throws InvalidPluginException, InvalidDescriptionException, UnknownDependencyException;
@@ -88,9 +89,8 @@ public interface PluginManager {
public void clearPlugins();
/**
* Calls a player related event with the given details
* Calls an event with the given details
*
* @param type Type of player related event to call
* @param event Event details
*/
public void callEvent(Event event);
@@ -179,6 +179,7 @@ public interface PluginManager {
* Gets the default permissions for the given op status
*
* @param op Which set of default permissions to get
* @return The default permissions
*/
public Set<Permission> getDefaultPermissions(boolean op);

View File

@@ -52,7 +52,7 @@ public class RegisteredListener {
/**
* Calls the event executor
* @return Registered Priority
* @param event The event
*/
public void callEvent(Event event) {
executor.execute(listener, event);

View File

@@ -30,22 +30,22 @@ public interface ServicesManager {
/**
* Unregister all the providers registered by a particular plugin.
*
* @param plugin
* @param plugin The plugin
*/
public void unregisterAll(Plugin plugin);
/**
* Unregister a particular provider for a particular service.
*
* @param service
* @param provider
* @param service The service interface
* @param provider The service provider implementation
*/
public void unregister(Class<?> service, Object provider);
/**
* Unregister a particular provider.
*
* @param provider
* @param provider The service provider implementation
*/
public void unregister(Object provider);
@@ -53,8 +53,8 @@ public interface ServicesManager {
* Queries for a provider. This may return if no provider has been
* registered for a service. The highest priority provider is returned.
*
* @param <T>
* @param service
* @param <T> The service interface
* @param service The service interface
* @return provider or null
*/
public <T> T load(Class<T> service);
@@ -63,8 +63,8 @@ public interface ServicesManager {
* Queries for a provider registration. This may return if no provider
* has been registered for a service.
*
* @param <T>
* @param service
* @param <T> The service interface
* @param service The service interface
* @return provider registration or null
*/
public <T> RegisteredServiceProvider<T> getRegistration(Class<T> service);
@@ -72,7 +72,7 @@ public interface ServicesManager {
/**
* Get registrations of providers for a plugin.
*
* @param plugin
* @param plugin The plugin
* @return provider registration or null
*/
public List<RegisteredServiceProvider<?>> getRegistrations(Plugin plugin);
@@ -81,8 +81,8 @@ public interface ServicesManager {
* Get registrations of providers for a service. The returned list is
* unmodifiable.
*
* @param <T>
* @param service
* @param <T> The service interface
* @param service The service interface
* @return list of registrations
*/
public <T> Collection<RegisteredServiceProvider<T>> getRegistrations(

View File

@@ -175,6 +175,7 @@ public final class SimplePluginManager implements PluginManager {
* @return The Plugin loaded, or null if it was invalid
* @throws InvalidPluginException Thrown when the specified file is not a valid plugin
* @throws InvalidDescriptionException Thrown when the specified file contains an invalid description
* @throws UnknownDependencyException If a required dependency could not be found
*/
public synchronized Plugin loadPlugin(File file) throws InvalidPluginException, InvalidDescriptionException, UnknownDependencyException {
return loadPlugin(file, true);
@@ -190,6 +191,7 @@ public final class SimplePluginManager implements PluginManager {
* @return The Plugin loaded, or null if it was invalid
* @throws InvalidPluginException Thrown when the specified file is not a valid plugin
* @throws InvalidDescriptionException Thrown when the specified file contains an invalid description
* @throws UnknownDependencyException If a required dependency could not be found
*/
public synchronized Plugin loadPlugin(File file, boolean ignoreSoftDependencies) throws InvalidPluginException, InvalidDescriptionException, UnknownDependencyException {
File updateFile = null;
@@ -324,9 +326,8 @@ public final class SimplePluginManager implements PluginManager {
}
/**
* Calls a player related event with the given details
* Calls an event with the given details
*
* @param type Type of player related event to call
* @param event Event details
*/
public synchronized void callEvent(Event event) {

View File

@@ -52,7 +52,7 @@ public class SimpleServicesManager implements ServicesManager {
/**
* Unregister all the providers registered by a particular plugin.
*
* @param plugin
* @param plugin The plugin
*/
public void unregisterAll(Plugin plugin) {
synchronized (providers) {
@@ -86,8 +86,8 @@ public class SimpleServicesManager implements ServicesManager {
/**
* Unregister a particular provider for a particular service.
*
* @param service
* @param provider
* @param service The service interface
* @param provider The service provider implementation
*/
public void unregister(Class<?> service, Object provider) {
synchronized (providers) {
@@ -127,7 +127,7 @@ public class SimpleServicesManager implements ServicesManager {
/**
* Unregister a particular provider.
*
* @param provider
* @param provider The service provider implementation
*/
public void unregister(Object provider) {
synchronized (providers) {
@@ -162,8 +162,8 @@ public class SimpleServicesManager implements ServicesManager {
* Queries for a provider. This may return if no provider has been
* registered for a service. The highest priority provider is returned.
*
* @param <T>
* @param service
* @param <T> The service interface
* @param service The service interface
* @return provider or null
*/
@SuppressWarnings("unchecked")
@@ -184,8 +184,8 @@ public class SimpleServicesManager implements ServicesManager {
* Queries for a provider registration. This may return if no provider
* has been registered for a service.
*
* @param <T>
* @param service
* @param <T> The service interface
* @param service The service interface
* @return provider registration or null
*/
@SuppressWarnings("unchecked")
@@ -205,7 +205,7 @@ public class SimpleServicesManager implements ServicesManager {
/**
* Get registrations of providers for a plugin.
*
* @param plugin
* @param plugin The plugin
* @return provider registration or null
*/
public List<RegisteredServiceProvider<?>> getRegistrations(Plugin plugin) {
@@ -228,8 +228,8 @@ public class SimpleServicesManager implements ServicesManager {
* Get registrations of providers for a service. The returned list is
* unmodifiable.
*
* @param <T>
* @param service
* @param <T> The service interface
* @param service The service interface
* @return list of registrations
*/
@SuppressWarnings("unchecked")

View File

@@ -41,7 +41,7 @@ public abstract class JavaPlugin implements Plugin {
* Returns the folder that the plugin data's files are located in. The
* folder may not yet exist.
*
* @return
* @return The folder.
*/
public File getDataFolder() {
return dataFolder;
@@ -98,7 +98,7 @@ public abstract class JavaPlugin implements Plugin {
* does not exist and it cannot be loaded, no error will be emitted and
* the configuration file will have no values.
*
* @return
* @return The configuration.
*/
public Configuration getConfiguration() {
return config;

View File

@@ -177,9 +177,9 @@ public class JavaPluginLoader implements PluginLoader {
throw new InvalidPluginException(ex);
}
loaders.put(description.getName(), (PluginClassLoader) loader);
loaders.put(description.getName(), loader);
return (Plugin) result;
return result;
}
protected File getDataFolder(File file) {