Return-Path: Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: (qmail 13373 invoked from network); 2 Apr 2011 22:02:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 2 Apr 2011 22:02:37 -0000 Received: (qmail 52421 invoked by uid 500); 2 Apr 2011 22:02:37 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 52355 invoked by uid 500); 2 Apr 2011 22:02:37 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 52348 invoked by uid 99); 2 Apr 2011 22:02:37 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 02 Apr 2011 22:02:37 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 02 Apr 2011 22:02:35 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 77FA523889ED; Sat, 2 Apr 2011 22:02:15 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1088153 - /commons/proper/discovery/trunk/src/java/org/apache/commons/discovery/tools/SPInterface.java Date: Sat, 02 Apr 2011 22:02:15 -0000 To: commits@commons.apache.org From: simonetripodi@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20110402220215.77FA523889ED@eris.apache.org> Author: simonetripodi Date: Sat Apr 2 22:02:15 2011 New Revision: 1088153 URL: http://svn.apache.org/viewvc?rev=1088153&view=rev Log: removed trailing spaces Modified: commons/proper/discovery/trunk/src/java/org/apache/commons/discovery/tools/SPInterface.java Modified: commons/proper/discovery/trunk/src/java/org/apache/commons/discovery/tools/SPInterface.java URL: http://svn.apache.org/viewvc/commons/proper/discovery/trunk/src/java/org/apache/commons/discovery/tools/SPInterface.java?rev=1088153&r1=1088152&r2=1088153&view=diff ============================================================================== --- commons/proper/discovery/trunk/src/java/org/apache/commons/discovery/tools/SPInterface.java (original) +++ commons/proper/discovery/trunk/src/java/org/apache/commons/discovery/tools/SPInterface.java Sat Apr 2 22:02:15 2011 @@ -26,12 +26,12 @@ import org.apache.commons.discovery.Disc * - SPI's name * - SPI's (provider) class * - SPI's (alternate) override property name - * + * * In addition, while there are many cases where this is NOT * usefull, for those in which it is: - * + * * - expected constructor argument types and parameters values. - * + * * @author Richard A. Sitze */ public class SPInterface { @@ -39,34 +39,34 @@ public class SPInterface { * The service programming interface: intended to be * an interface or abstract class, but not limited * to those two. - */ + */ private final Class spi; - + /** * The property name to be used for finding the name of * the SPI implementation class. */ private final String propertyName; - - + + private Class paramClasses[] = null; private Object params[] = null; /** * Construct object representing Class provider. - * + * * @param provider The SPI class */ public SPInterface(Class provider) { this(provider, provider.getName()); } - + /** * Construct object representing Class provider. - * + * * @param spi The SPI class - * + * * @param propertyName when looking for the name of a class implementing * the provider class, a discovery strategy may involve looking for * (system or other) properties having either the name of the class @@ -79,12 +79,12 @@ public class SPInterface { /** * Construct object representing Class provider. - * + * * @param provider The SPI class - * + * * @param constructorParamClasses classes representing the * constructor argument types. - * + * * @param constructorParams objects representing the * constructor arguments. */ @@ -97,20 +97,20 @@ public class SPInterface { constructorParamClasses, constructorParams); } - + /** * Construct object representing Class provider. - * + * * @param spi The SPI class - * + * * @param propertyName when looking for the name of a class implementing * the provider class, a discovery strategy may involve looking for * (system or other) properties having either the name of the class * (provider) or the propertyName. - * + * * @param constructorParamClasses classes representing the * constructor argument types. - * + * * @param constructorParams objects representing the * constructor arguments. */ @@ -132,14 +132,14 @@ public class SPInterface { public Class getSPClass() { return spi; } - + public String getPropertyName() { return propertyName; } /** * Instantiate a new - */ + */ public S newInstance(Class impl) throws DiscoveryException, InstantiationException, @@ -148,10 +148,10 @@ public class SPInterface { InvocationTargetException { verifyAncestory(impl); - + return ClassUtils.newInstance(impl, paramClasses, params); } - + public void verifyAncestory(Class impl) { ClassUtils.verifyAncestory(spi, impl); }