tapestry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hls...@apache.org
Subject svn commit: r711752 [1/2] - in /tapestry/tapestry5/trunk: src/site/apt/ tapestry-core/src/main/java/org/apache/tapestry5/annotations/ tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ tapestry-core/src/main/java/org/apache/tapestry5/s...
Date Thu, 06 Nov 2008 01:44:02 GMT
Author: hlship
Date: Wed Nov  5 17:44:01 2008
New Revision: 711752

URL: http://svn.apache.org/viewvc?rev=711752&view=rev
Log:
TAP5-332: Service interfaces should identify the service name and the type of service configuration (if applicable)

Added:
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesConfiguration.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesMappedConfiguration.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesOrderedConfiguration.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/site/apt/injection.apt
Modified:
    tapestry/tapestry5/trunk/src/site/apt/index.apt
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/annotations/ApplicationState.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/BeanModelSourceImpl.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/PersistentFieldManager.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/TemplateParser.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AliasManager.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationInitializer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStateManager.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStatePersistenceStrategySource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AssetSource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockOverrideSource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockSource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BindingSource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ClasspathAssetAliasManager.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventRequestHandler.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventResultProcessor.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/DataTypeAnalyzer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Dispatcher.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/FieldValidatorSource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HiddenFieldLocationRules.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HttpServletRequestHandler.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/MarkupRenderer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/NullFieldStrategySource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ObjectRenderer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PageRenderRequestHandler.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PartialMarkupRenderer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Request.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/RequestHandler.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ResourceDigestGenerator.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Response.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ServletApplicationInitializer.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TranslatorSource.java
    tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ValidationConstraintGenerator.java
    tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateEntityPackageManager.java
    tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateSessionSource.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/ServiceDecoratorImpl.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/MasterObjectProvider.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/ServiceLifecycleSource.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolProvider.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolSource.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TapestryIOCModule.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TypeCoercer.java
    tapestry/tapestry5/trunk/tapestry-ioc/src/site/site.xml
    tapestry/tapestry5/trunk/tapestry-upload/src/main/java/org/apache/tapestry5/upload/services/UploadModule.java

Modified: tapestry/tapestry5/trunk/src/site/apt/index.apt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/src/site/apt/index.apt?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/src/site/apt/index.apt (original)
+++ tapestry/tapestry5/trunk/src/site/apt/index.apt Wed Nov  5 17:44:01 2008
@@ -68,6 +68,8 @@
 
 New And Of Note
 
+  * A {{{tapestry-ioc/injection.html}detailed guide to Injection}} has been added.
+
   * You can now configure Tapestry to move \<script\> links to the top of the page.
 
   * Event handler methods for Ajax requests may now return a page name, page class or page instance to force

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/annotations/ApplicationState.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/annotations/ApplicationState.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/annotations/ApplicationState.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/annotations/ApplicationState.java Wed Nov  5 17:44:01 2008
@@ -22,7 +22,10 @@
 
 /**
  * Marker annotation for a field that is an <em>application state object</em> as controlled by the {@link
- * org.apache.tapestry5.services.ApplicationStateManager}.
+ * org.apache.tapestry5.services.ApplicationStateManager}.  <em>Application</em> is something of a misnomer, as it
+ * implies that the object is stored as global, application-wide state (i.e., in the {@link
+ * javax.servlet.ServletContext}). In fact, the built-in strategies for ASO management are <em>very</em> user specific,
+ * ultimately storing data in the {@link org.apache.tapestry5.services.Session}.
  * <p/>
  * An ASO file may have a companion field, of type boolean, used to see if the ASO has been created yet. If another
  * field exists with the same name, suffixed with "Exists" (i.e., "aso" for the ASO field, and "asoExists" for the

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/BeanModelSourceImpl.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/BeanModelSourceImpl.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/BeanModelSourceImpl.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/BeanModelSourceImpl.java Wed Nov  5 17:44:01 2008
@@ -20,7 +20,6 @@
 import org.apache.tapestry5.internal.beaneditor.BeanModelImpl;
 import org.apache.tapestry5.internal.beaneditor.BeanModelUtils;
 import org.apache.tapestry5.ioc.Location;
-import org.apache.tapestry5.ioc.LoggerSource;
 import org.apache.tapestry5.ioc.Messages;
 import org.apache.tapestry5.ioc.ObjectLocator;
 import org.apache.tapestry5.ioc.annotations.Primary;
@@ -38,8 +37,6 @@
 
 public class BeanModelSourceImpl implements BeanModelSource
 {
-    private final LoggerSource loggerSource;
-
     private final TypeCoercer typeCoercer;
 
     private final PropertyAccess propertyAccess;
@@ -91,7 +88,6 @@
         for (String name : propertyNames)
         {
             PropertyAdapter pa = classAdapter.getPropertyAdapter(name);
-            List<String> propertyConstraints = CollectionFactory.newList();
 
             Method readMethod = pa.getReadMethod();
 
@@ -126,11 +122,10 @@
         return depth;
     }
 
-    public BeanModelSourceImpl(LoggerSource loggerSource, TypeCoercer typeCoercer, PropertyAccess propertyAccess,
+    public BeanModelSourceImpl(TypeCoercer typeCoercer, PropertyAccess propertyAccess,
                                PropertyConduitSource propertyConduitSource, @ComponentLayer ClassFactory classFactory,
                                @Primary DataTypeAnalyzer dataTypeAnalyzer, ObjectLocator locator)
     {
-        this.loggerSource = loggerSource;
         this.typeCoercer = typeCoercer;
         this.propertyAccess = propertyAccess;
         this.propertyConduitSource = propertyConduitSource;

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/PersistentFieldManager.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/PersistentFieldManager.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/PersistentFieldManager.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/PersistentFieldManager.java Wed Nov  5 17:44:01 2008
@@ -15,15 +15,15 @@
 package org.apache.tapestry5.internal.services;
 
 import org.apache.tapestry5.ComponentResources;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 import org.apache.tapestry5.services.PersistentFieldBundle;
+import org.apache.tapestry5.services.PersistentFieldStrategy;
 
 /**
  * Handle persistent property changes. Primarily, delegates to a number of {@link org.apache.tapestry5.services.PersistentFieldStrategy}
  * instances.
- *
- * @see org.apache.tapestry5.services.TapestryModule#contributePersistentFieldManager(org.apache.tapestry5.ioc.MappedConfiguration,
- *      org.apache.tapestry5.services.Request , org.apache.tapestry5.services.PersistentFieldStrategy)
  */
+@UsesMappedConfiguration(PersistentFieldStrategy.class)
 public interface PersistentFieldManager
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,14 +15,17 @@
 package org.apache.tapestry5.internal.services;
 
 import org.apache.tapestry5.ioc.Resource;
-import org.apache.tapestry5.ioc.internal.util.ClasspathResource;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 import java.io.IOException;
 
 /**
- * Responsible for streaming the contents of a resource to the client. The {@link Resource} to stream is almost always a
- * {@link ClasspathResource}.
+ * Responsible for streaming the contents of a resource to the client. The {@link org.apache.tapestry5.ioc.Resource} to
+ * stream is almost always a {@link org.apache.tapestry5.ioc.internal.util.ClasspathResource}.
+ * <p/>
+ * The service's configuration is used to map file extensions to content types.
  */
+@UsesMappedConfiguration(String.class)
 public interface ResourceStreamer
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/TemplateParser.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/TemplateParser.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/TemplateParser.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/TemplateParser.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -16,12 +16,17 @@
 
 import org.apache.tapestry5.internal.parser.ComponentTemplate;
 import org.apache.tapestry5.ioc.Resource;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+
+import java.net.URL;
 
 /**
- * Parses a resource into a {@link org.apache.tapestry5.internal.parser.ComponentTemplate}.
+ * Parses a resource into a {@link org.apache.tapestry5.internal.parser.ComponentTemplate}. The service's configuration
+ * is used to map common document types to internal copies of the corresponding DTD.
  *
- * @see PageLoader
+ * @see org.apache.tapestry5.internal.services.PageLoader
  */
+@UsesMappedConfiguration(URL.class)
 public interface TemplateParser
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AliasManager.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AliasManager.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AliasManager.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AliasManager.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006, 2007 The Apache Software Foundation
+// Copyright 2006, 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,11 +14,16 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
+
 import java.util.Map;
 
 /**
- * A thin wrapper around a set of {@link org.apache.tapestry5.services.AliasContribution}s.
+ * A thin wrapper around a set of {@link org.apache.tapestry5.services.AliasContribution}s. An {@link
+ * org.apache.tapestry5.ioc.ObjectProvider} is contributed to the {@link org.apache.tapestry5.ioc.services.MasterObjectProvider}
+ * service, to allow contributed objects to replace other objects (typically, built in services).
  */
+@UsesConfiguration(AliasContribution.class)
 public interface AliasManager
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationInitializer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationInitializer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationInitializer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationInitializer.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,13 +14,14 @@
 
 package org.apache.tapestry5.services;
 
-import org.apache.tapestry5.services.Context;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 
 /**
- * Service interface for initializing Tapestry for the application.
- *
- * @see ApplicationInitializerFilter
+ * Service interface for initializing Tapestry for the application.  The service is a {@linkplain
+ * org.apache.tapestry5.ioc.services.PipelineBuilder pipeline}, into which {@linkplain
+ * org.apache.tapestry5.services.ApplicationInitializerFilter filters} may be contributed.
  */
+@UsesOrderedConfiguration(ApplicationInitializerFilter.class)
 public interface ApplicationInitializer
 {
     void initializeApplication(Context context);

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStateManager.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStateManager.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStateManager.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStateManager.java Wed Nov  5 17:44:01 2008
@@ -14,11 +14,24 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+
 /**
  * Responsible for managing <em>application state objects</em>, objects which persist between requests, but are not tied
  * to any individual page or component. ASOs are also created on demand. ASOs are typically stored in the session, so
  * that they are specific to a particular client.
+ * <p/>
+ * <em>Application</em> is a bit of a misnomer here, as it implies global state shared by all users of the application.
+ * Although that is a possibility, the supported ASO strategies are user-specific, usually storing data in the {@link
+ * org.apache.tapestry5.services.Session}.
+ * <p/>
+ * Tapestry has a built-in default strategy for storing ASOs (in the session) and instantiating them. If desired,
+ * contributions to the service configuration can override the default behavior, either specifying an alternate storage
+ * strategy, or an alternate {@linkplain org.apache.tapestry5.services.ApplicationStateCreator creation strategy}.
+ *
+ * @see org.apache.tapestry5.annotations.ApplicationState
  */
+@UsesMappedConfiguration(key = Class.class, value = ApplicationStateContribution.class)
 public interface ApplicationStateManager
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStatePersistenceStrategySource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStatePersistenceStrategySource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStatePersistenceStrategySource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ApplicationStatePersistenceStrategySource.java Wed Nov  5 17:44:01 2008
@@ -14,12 +14,13 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+
 /**
- * Used to provide access to stategies via a logical name for the stategy, such as "session".
- *
- * @see org.apache.tapestry5.services.TapestryModule#contributeApplicationStatePersistenceStrategySource(org.apache.tapestry5.ioc.MappedConfiguration,
- *      Request)
+ * Used to provide access to {@link org.apache.tapestry5.services.ApplicationStatePersistenceStrategySource} instances
+ * via a logical name for the stategy, such as "session".
  */
+@UsesMappedConfiguration(ApplicationStatePersistenceStrategy.class)
 public interface ApplicationStatePersistenceStrategySource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AssetSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AssetSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AssetSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/AssetSource.java Wed Nov  5 17:44:01 2008
@@ -16,20 +16,19 @@
 
 import org.apache.tapestry5.Asset;
 import org.apache.tapestry5.ioc.Resource;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 import org.apache.tapestry5.ioc.services.ThreadLocale;
 
 import java.util.Locale;
 
 /**
- * Used to find or create an {@link Asset} with a given path.
+ * Used to find or create an {@link org.apache.tapestry5.Asset} with a given path.
  * <p/>
  * Assets are defined with a domain, and the domain is indicated by a prefix.  The two builtin domains are "context:"
  * (for files inside the web application context) and "classpath:" for files stored on the classpath (typically, inside
  * a JAR, such as a component library).
- *
- * @see org.apache.tapestry5.services.TapestryModule#contributeAssetSource(org.apache.tapestry5.ioc.MappedConfiguration,
- *      AssetFactory, AssetFactory)
  */
+@UsesMappedConfiguration(AssetFactory.class)
 public interface AssetSource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockOverrideSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockOverrideSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockOverrideSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockOverrideSource.java Wed Nov  5 17:44:01 2008
@@ -15,12 +15,14 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.Block;
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
 
 /**
  * Used to override the default {@link org.apache.tapestry5.services.BeanBlockSource} for a particular data type.  The
  * service accepts the same configuration of {@link org.apache.tapestry5.services.BeanBlockContribution}s as the main
  * service.
  */
+@UsesConfiguration(BeanBlockContribution.class)
 public interface BeanBlockOverrideSource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BeanBlockSource.java Wed Nov  5 17:44:01 2008
@@ -15,6 +15,7 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.Block;
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
 
 /**
  * A source of {@link Block}s used to display the properties of a bean (used by the {@link
@@ -31,6 +32,7 @@
  * @see org.apache.tapestry5.services.DataTypeAnalyzer
  * @see org.apache.tapestry5.services.TapestryModule#contributeBeanBlockSource(org.apache.tapestry5.ioc.Configuration)
  */
+@UsesConfiguration(BeanBlockContribution.class)
 public interface BeanBlockSource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BindingSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BindingSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BindingSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/BindingSource.java Wed Nov  5 17:44:01 2008
@@ -17,14 +17,13 @@
 import org.apache.tapestry5.Binding;
 import org.apache.tapestry5.ComponentResources;
 import org.apache.tapestry5.ioc.Location;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 /**
  * Used to acquire bindings for component parameters. The BindingSource service strips off the binding prefix to locate
  * a {@link org.apache.tapestry5.services.BindingFactory}.
- *
- * @see org.apache.tapestry5.services.TapestryModule#contributeBindingSource(org.apache.tapestry5.ioc.MappedConfiguration,
- *      AssetSource, BindingFactory, FieldValidatorSource, TranslatorSource, org.apache.tapestry5.ioc.ObjectLocator)
  */
+@UsesMappedConfiguration(BindingFactory.class)
 public interface BindingSource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ClasspathAssetAliasManager.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ClasspathAssetAliasManager.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ClasspathAssetAliasManager.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ClasspathAssetAliasManager.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,6 +14,17 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+
+/**
+ * Used as part of the support for classpath {@link org.apache.tapestry5.Asset}s, to convert the Asset's {@link
+ * org.apache.tapestry5.ioc.Resource} to a URL that can be accessed by the client.    The asset path, within the
+ * classpath, is converted into a shorter virtual path (one that, typically, includes some kind of version number).
+ * <p/>
+ * Service configuration is a map from aliases (short names) to complete names. Names should not start or end end with a
+ * slash.
+ */
+@UsesMappedConfiguration(String.class)
 public interface ClasspathAssetAliasManager
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventRequestHandler.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventRequestHandler.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventRequestHandler.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventRequestHandler.java Wed Nov  5 17:44:01 2008
@@ -14,20 +14,26 @@
 
 package org.apache.tapestry5.services;
 
-import org.apache.tapestry5.corelib.components.ActionLink;
-import org.apache.tapestry5.corelib.components.Form;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 
 import java.io.IOException;
 
 /**
- * Handler interface for action requests. Action requests <em>do things</em> such as process a form submission or
- * otherwise change state. In the majority of cases, after the action, a redirect response is sent to the client which,
- * in turn, causes a page render.
+ * Handler interface for component event requests. Component event requests <em>do things</em> such as process a form
+ * submission or otherwise change state. In the majority of cases, after the component event, a redirect response is
+ * sent to the client which, in turn, causes a page render.
+ * <p/>
+ * The ComponentEventRequestHandler service is a pipeline, allowing extensibility via contributed {@linkplain
+ * org.apache.tapestry5.services.ComponentEventRequestFilter filters}.    It may be distinguished by the @{@link
+ * org.apache.tapestry5.services.Traditional} marker annotation.
+ * <p/>
+ * A second service, AjaxComponentEventRequestHandler is also a pipeline and may be distinguished by the @{@link
+ * org.apache.tapestry5.services.Ajax} marker annotation.
  *
- * @see ActionLink
- * @see Form
- * @see ComponentEventRequestFilter
+ * @see org.apache.tapestry5.corelib.components.ActionLink
+ * @see org.apache.tapestry5.corelib.components.Form
  */
+@UsesOrderedConfiguration(ComponentEventRequestFilter.class)
 public interface ComponentEventRequestHandler
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventResultProcessor.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventResultProcessor.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventResultProcessor.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ComponentEventResultProcessor.java Wed Nov  5 17:44:01 2008
@@ -14,13 +14,22 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+
 import java.io.IOException;
 
 /**
  * Responsible for handling the return value provided by a component event handler method.
+ * <p/>
+ * There are two services built into Tapestry that implement this interface: ComponentEventResultProcessor (used for
+ * ordinary page-oriented requests, and distinguished by the @{@link org.apache.tapestry5.services.Traditional}  and/or
  *
+ * @{@link org.apache.tapestry5.ioc.annotations.Primary} marker annotations) and AjaxComponentEventResultProcessor, used
+ * for Ajax requests (which typically return a partially rendered page), distinguished by the @{@link
+ * org.apache.tapestry5.services.Ajax} marker annotation.
  * @param <T>
  */
+@UsesMappedConfiguration(key = Class.class, value = ComponentEventResultProcessor.class)
 public interface ComponentEventResultProcessor<T>
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/DataTypeAnalyzer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/DataTypeAnalyzer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/DataTypeAnalyzer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/DataTypeAnalyzer.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,8 +14,8 @@
 
 package org.apache.tapestry5.services;
 
-import org.apache.tapestry5.corelib.components.BeanEditForm;
-import org.apache.tapestry5.corelib.components.Grid;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 import org.apache.tapestry5.ioc.services.PropertyAdapter;
 
 /**
@@ -26,13 +26,19 @@
  * <p/>
  * <p>Different strategies for identifying the data type are encapsulated in the DataTypeAnalyzer service, forming a
  * chain of command.
+ * <p/>
+ * The DefaultDataTypeAnalyzer service maps property types to data type names.
+ * <p/>
+ * The DataTypeAnalyzer service is an extensible {@linkplain org.apache.tapestry5.ioc.services.ChainBuilder chain of
+ * command), that (by default) includes {@link org.apache.tapestry5.internal.services.AnnotationDataTypeAnalyzer} and
+ * the DefaultDataTypeAnalyzer service (ordered last).   It uses an ordered configuration.
  *
  * @see Grid
  * @see BeanEditForm
  * @see BeanBlockSource
- * @see org.apache.tapestry5.services.TapestryModule#contributeDataTypeAnalyzer(org.apache.tapestry5.ioc.OrderedConfiguration,
- *      DataTypeAnalyzer)
  */
+@UsesOrderedConfiguration(DataTypeAnalyzer.class)
+@UsesMappedConfiguration(key = Class.class, value = String.class)
 public interface DataTypeAnalyzer
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Dispatcher.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Dispatcher.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Dispatcher.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Dispatcher.java Wed Nov  5 17:44:01 2008
@@ -14,6 +14,8 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
+
 import java.io.IOException;
 
 /**
@@ -21,10 +23,8 @@
  * each dispatcher responsible for recognizing requests that it can process.  This is the interface for the
  * MasterDispatcher service, which takes an ordered configuration of Dispatchers (that is, the chain of command
  * pattern). If no dispatcher processes the request, it will utltimately be passed off to the servlet container.
- *
- * @see org.apache.tapestry5.services.TapestryModule#contributeMasterDispatcher(org.apache.tapestry5.ioc.OrderedConfiguration,
- *      org.apache.tapestry5.ioc.ObjectLocator)
  */
+@UsesOrderedConfiguration(Dispatcher.class)
 public interface Dispatcher
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/FieldValidatorSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/FieldValidatorSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/FieldValidatorSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/FieldValidatorSource.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -19,12 +19,15 @@
 import org.apache.tapestry5.Validator;
 import org.apache.tapestry5.corelib.components.BeanEditForm;
 import org.apache.tapestry5.ioc.Messages;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 import java.util.Locale;
 
 /**
- * Used to create {@link FieldValidator}s for a particular {@link Field} component.
+ * Used to create {@link org.apache.tapestry5.FieldValidator}s for a particular {@link org.apache.tapestry5.Field}
+ * component.
  */
+@UsesMappedConfiguration(Validator.class)
 public interface FieldValidatorSource
 {
     /**
@@ -35,7 +38,8 @@
      * you to override the message for a particular validation of a particular field.
      *
      * @param field           the field for which a validator is to be created
-     * @param validatorType   used to select the {@link Validator} that forms the core of the {@link FieldValidator}
+     * @param validatorType   used to select the {@link org.apache.tapestry5.Validator} that forms the core of the
+     *                        {@link org.apache.tapestry5.FieldValidator}
      * @param constraintValue a value used to configure the validator, or null if the validator is not configurarable
      * @return the field validator for the field
      */
@@ -47,14 +51,15 @@
      * to use when checking. The {@link BeanEditForm} is an example of this.
      *
      * @param field            the field for which a validator is to be created
-     * @param validatorType    used to select the {@link Validator} that forms the core of the {@link FieldValidator}
+     * @param validatorType    used to select the {@link org.apache.tapestry5.Validator} that forms the core of the
+     *                         {@link org.apache.tapestry5.FieldValidator}
      * @param constraintValue  a value used to configure the validator, or null if the validator is not configurable
      * @param overrideId       the base id used when searching for validator message overrides (this would normally be
      *                         the field component's simple id)
      * @param overrideMessages the message catalog to search for override messages (this would normally be the catalog
      *                         for the container of the field component)
      * @param locale           locale used when retrieving default validation messages from the {@link
-     *                         ValidationMessagesSource}
+     *                         org.apache.tapestry5.services.ValidationMessagesSource}
      * @return the field validator for the field
      */
     FieldValidator createValidator(Field field, String validatorType, String constraintValue,

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HiddenFieldLocationRules.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HiddenFieldLocationRules.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HiddenFieldLocationRules.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HiddenFieldLocationRules.java Wed Nov  5 17:44:01 2008
@@ -15,6 +15,7 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.dom.Element;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 /**
  * Provides some assistance in determining <em>where</em> to place a hidden field based on standard (X)HTML elements.
@@ -22,6 +23,7 @@
  * The service works based on a mapped service contribution; keys are the element names, values area {@link
  * org.apache.tapestry5.services.RelativeElementPosition}.
  */
+@UsesMappedConfiguration(RelativeElementPosition.class)
 public interface HiddenFieldLocationRules
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HttpServletRequestHandler.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HttpServletRequestHandler.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HttpServletRequestHandler.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/HttpServletRequestHandler.java Wed Nov  5 17:44:01 2008
@@ -1,28 +1,31 @@
-// Copyright 2006 The Apache Software Foundation
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
+// Copyright 2006, 2008 The Apache Software Foundation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
+
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import java.io.IOException;
 
 /**
- * Service interface for the HttpServletRequestHandler pipeline service.
- *
- * @see org.apache.tapestry5.services.HttpServletRequestFilter
+ * The first step in handing an incoming request to the {@linkplain org.apache.tapestry5.TapestryFilter servlet filter},
+ * this constructed as a {@linkplain org.apache.tapestry5.ioc.services.PipelineBuilder pipeline}.  The main
+ * implementation hands off to the {@link org.apache.tapestry5.services.RequestHandler} service.
  */
+@UsesOrderedConfiguration(HttpServletRequestFilter.class)
 public interface HttpServletRequestHandler
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/MarkupRenderer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/MarkupRenderer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/MarkupRenderer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/MarkupRenderer.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,6 +15,7 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.MarkupWriter;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 
 /**
  * An object which will perform rendering of a page (or portion of a page).  This interface exists to be filtered via
@@ -22,9 +23,11 @@
  * <p/>
  * The MarkupRenderer service takes an ordered configuration of {@link org.apache.tapestry5.services.MarkupRendererFilter}s,
  * which are used for ordinary page rendering (as opposed to {@linkplain org.apache.tapestry5.services.PartialMarkupRenderer
- * partial page rendering} for Ajax requests). The MarkupRenderer service may be selected using the {@link
- * org.apache.tapestry5.ioc.annotations.Primary} marker annotation.
+ * partial page rendering} for Ajax requests). The MarkupRenderer service may be selected using the
+ *
+ * @{@link org.apache.tapestry5.ioc.annotations.Primary} marker annotation.
  */
+@UsesOrderedConfiguration(MarkupRendererFilter.class)
 public interface MarkupRenderer
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/NullFieldStrategySource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/NullFieldStrategySource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/NullFieldStrategySource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/NullFieldStrategySource.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright  2008 The Apache Software Foundation
+// Copyright 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,12 +15,12 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.NullFieldStrategy;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 /**
  * A source for {@link org.apache.tapestry5.NullFieldStrategy} instances based on a logical name.
- *
- * @see TapestryModule#contributeNullFieldStrategySource(org.apache.tapestry5.ioc.MappedConfiguration)
  */
+@UsesMappedConfiguration(NullFieldStrategy.class)
 public interface NullFieldStrategySource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ObjectRenderer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ObjectRenderer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ObjectRenderer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ObjectRenderer.java Wed Nov  5 17:44:01 2008
@@ -15,11 +15,17 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.MarkupWriter;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 /**
  * A strategy interface used for converting an object into markup that describes that object. This is primarily used in
  * terms of an {@link org.apache.tapestry5.services.ExceptionReporter} page.
+ * <p/>
+ * The ObjectRenderer service (distinguished by the @{@link org.apache.tapestry5.ioc.annotations.Primary} marker
+ * annotation) uses {@linkplain org.apache.tapestry5.ioc.services.StrategyBuilder type-based matching} to find a
+ * specific ObjectRenderer for any given type.
  */
+@UsesMappedConfiguration(key = Class.class, value = ObjectRenderer.class)
 public interface ObjectRenderer<T>
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PageRenderRequestHandler.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PageRenderRequestHandler.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PageRenderRequestHandler.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PageRenderRequestHandler.java Wed Nov  5 17:44:01 2008
@@ -14,13 +14,17 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
+
 import java.io.IOException;
 
 /**
  * Handles a invocation related to rendering out a pages complete content.
- *
- * @see PageRenderRequestFilter
+ * <p/>
+ * The PageRenderRequestHandler service is an extensible {@linkplain org.apache.tapestry5.ioc.services.PipelineBuilder
+ * pipeline}.
  */
+@UsesOrderedConfiguration(PageRenderRequestFilter.class)
 public interface PageRenderRequestHandler
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PartialMarkupRenderer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PartialMarkupRenderer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PartialMarkupRenderer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/PartialMarkupRenderer.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,6 +15,7 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.MarkupWriter;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 import org.apache.tapestry5.json.JSONObject;
 
 /**
@@ -26,6 +27,7 @@
  * The PartialMarkupRenderer service takes an ordered configuration of {@link PartialMarkupRendererFilter}s.  It can be
  * selected using the {@link org.apache.tapestry5.ioc.annotations.Primary} marker annotation.
  */
+@UsesOrderedConfiguration(PartialMarkupRendererFilter.class)
 public interface PartialMarkupRenderer
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Request.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Request.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Request.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Request.java Wed Nov  5 17:44:01 2008
@@ -20,6 +20,10 @@
 /**
  * Generic version of {@link javax.servlet.http.HttpServletRequest}, used to encapsulate the Servlet API version, and to
  * help bridge the differences between Servlet API and Porlet API.
+ * <p/>
+ * <p/>
+ * The Request service is a {@linkplain org.apache.tapestry5.ioc.services.PropertyShadowBuilder shadow} of the current
+ * thread's request.
  */
 public interface Request
 {

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/RequestHandler.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/RequestHandler.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/RequestHandler.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/RequestHandler.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006, 2007 The Apache Software Foundation
+// Copyright 2006, 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,15 +14,16 @@
 
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
+
 import java.io.IOException;
 
 /**
- * Service interface for the RequestHandler pipeline service. An ordered configuration of filters may be contributed to
- * the service.
- *
- * @see org.apache.tapestry5.services.RequestFilter
+ * Service interface for the RequestHandler {@linkplain org.apache.tapestry5.ioc.services.PipelineBuilder pipeline}
+ * service. At the end of the pipeline, the service hands off to the {@linkplain org.apache.tapestry5.services.Dispatcher
+ * master dispatcher service}.
  */
-
+@UsesOrderedConfiguration(RequestFilter.class)
 public interface RequestHandler
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ResourceDigestGenerator.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ResourceDigestGenerator.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ResourceDigestGenerator.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ResourceDigestGenerator.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,24 +14,26 @@
 
 package org.apache.tapestry5.services;
 
-import org.apache.tapestry5.internal.services.ClasspathAssetFactory;
-import org.apache.tapestry5.ioc.Resource;
-import org.apache.tapestry5.ioc.internal.util.ClasspathResource;
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
 
 import java.net.URL;
 
 /**
  * Responsible for determining which classpath resources require checksums, and for generating checksums for such
  * resources.
+ * <p/>
+ * The service's configuration identifies which file extensions will be secured using an checksum. The default list is
+ * "class" and "tml".
  *
- * @see ClasspathResource
- * @see ClasspathAssetFactory
+ * @see org.apache.tapestry5.ioc.internal.util.ClasspathResource
+ * @see org.apache.tapestry5.internal.services.ClasspathAssetFactory
  */
+@UsesConfiguration(String.class)
 public interface ResourceDigestGenerator
 {
     /**
      * Examines the path (typically, the file name extension at the end of the path) to determine if a checksum is
-     * required for the path. The path is {@link Resource} style, without a leading slash.
+     * required for the path. The path is {@link org.apache.tapestry5.ioc.Resource} style, without a leading slash.
      */
     boolean requiresDigest(String path);
 

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Response.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Response.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Response.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/Response.java Wed Nov  5 17:44:01 2008
@@ -22,6 +22,10 @@
 
 /**
  * API agnostic wrapper for generating a response. Bridges the gaps between the Servlet API and the Portlet API.
+ * <p/>
+ * <p/>
+ * The Response service is a {@linkplain org.apache.tapestry5.ioc.services.PropertyShadowBuilder shadow} of the current
+ * thread's response object.
  */
 public interface Response
 {

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ServletApplicationInitializer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ServletApplicationInitializer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ServletApplicationInitializer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ServletApplicationInitializer.java Wed Nov  5 17:44:01 2008
@@ -1,24 +1,28 @@
-// Copyright 2006 The Apache Software Foundation
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
+// Copyright 2006, 2008 The Apache Software Foundation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
 package org.apache.tapestry5.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
+
 import javax.servlet.ServletContext;
 
 /**
- * Service interface for initializing a servlet application.
+ * Service interface for initializing a servlet application, as a {@linkplain org.apache.tapestry5.ioc.services.PipelineBuilder
+ * pipeline}. The terminator hands off to the {@link org.apache.tapestry5.services.ApplicationInitializer} service.
  */
+@UsesOrderedConfiguration(ServletApplicationInitializerFilter.class)
 public interface ServletApplicationInitializer
 {
     void initializeApplication(ServletContext context);

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java Wed Nov  5 17:44:01 2008
@@ -959,7 +959,7 @@
 
 
     /**
-     * Initializes the application.
+     * Initializes the application, using a pipeline of {@link org.apache.tapestry5.services.ApplicationInitializer}s.
      */
     @Marker(Primary.class)
     public ApplicationInitializer buildApplicationInitializer(Logger logger,
@@ -1189,9 +1189,6 @@
      * @param logger          used to log errors building the pipeline
      * @param configuration   filters on this service
      * @return the service
-     * @see #contributeMarkupRenderer(org.apache.tapestry5.ioc.OrderedConfiguration, org.apache.tapestry5.Asset,
-     *      org.apache.tapestry5.Asset, ValidationMessagesSource, org.apache.tapestry5.ioc.services.SymbolSource,
-     *      AssetSource)
      */
     public MarkupRenderer buildMarkupRenderer(final PageRenderQueue pageRenderQueue, Logger logger,
                                               List<MarkupRendererFilter> configuration)
@@ -1259,8 +1256,9 @@
     }
 
     /**
-     * Builds the action request handler for Ajax requests, based on {@link org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler}.
-     * Filters on the request handler are supported here as well.
+     * Builds the action request handler for Ajax requests, based on a {@linkplain org.apache.tapestry5.ioc.services.PipelineBuilder
+     * pipeline} around {@link org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler}. Filters on the
+     * request handler are supported here as well.
      */
     @Marker(Ajax.class)
     public ComponentEventRequestHandler buildAjaxComponentEventRequestHandler(
@@ -1793,7 +1791,7 @@
         // Java class files always require a digest.
         configuration.add("class");
 
-// Likewise, we don't want people fishing for templates.
+        // Likewise, we don't want people fishing for templates.
         configuration.add(InternalConstants.TEMPLATE_EXTENSION);
     }
 
@@ -1896,7 +1894,6 @@
      * Adds content types for "css" and "js" file extensions. <dl> <dt>css</dt> <dd>test/css</dd> <dt>js</dt>
      * <dd>text/javascript</dd> </dl>
      */
-    @SuppressWarnings({"JavaDoc"})
     public void contributeResourceStreamer(MappedConfiguration<String, String> configuration)
     {
         configuration.add("css", "text/css");

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TranslatorSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TranslatorSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TranslatorSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TranslatorSource.java Wed Nov  5 17:44:01 2008
@@ -15,12 +15,15 @@
 package org.apache.tapestry5.services;
 
 import org.apache.tapestry5.Translator;
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
 
 /**
- * A source for {@link Translator}s, either by name or by property type.
+ * A source for {@link org.apache.tapestry5.Translator}s, either by name or by property type.
  * <p/>
- * The configuration for the service is an unordered collection of {@link org.apache.tapestry5.Translator}.
+ * The configuration includes all the translators; each contributed translator must have a unique {@linkplain
+ * org.apache.tapestry5.Translator#getName() name}.
  */
+@UsesConfiguration(Translator.class)
 public interface TranslatorSource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ValidationConstraintGenerator.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ValidationConstraintGenerator.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ValidationConstraintGenerator.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/ValidationConstraintGenerator.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -16,6 +16,7 @@
 
 import org.apache.tapestry5.FieldValidator;
 import org.apache.tapestry5.ioc.AnnotationProvider;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 
 import java.util.List;
 
@@ -25,14 +26,15 @@
  * ultimately handed to {@link FieldValidatorSource#createValidator(org.apache.tapestry5.Field, String, String, String,
  * org.apache.tapestry5.ioc.Messages, java.util.Locale)}.
  */
+@UsesOrderedConfiguration(ValidationConstraintGenerator.class)
 public interface ValidationConstraintGenerator
 {
     /**
      * For a given property, identify all the approprite validation constraints. Each returned value is the name of a
      * validator (i.e., "required") or a validator name and configuration (i.e., "minlength=5"). These contraints are
-     * exactly the individual terms in a {@link FieldValidatorSource#createValidators(org.apache.tapestry5.Field, String)
-     * validate specification}. These will ultimately be used to create {@link FieldValidator}s for the field that edits
-     * the property.
+     * exactly the individual terms in a {@link FieldValidatorSource#createValidators(org.apache.tapestry5.Field,
+     * String) validate specification}. These will ultimately be used to create {@link FieldValidator}s for the field
+     * that edits the property.
      *
      * @param propertyType       the type of the property for which constraints are needed
      * @param annotationProvider provides access to any annotations concerning the property (for implementations that

Modified: tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateEntityPackageManager.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateEntityPackageManager.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateEntityPackageManager.java (original)
+++ tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateEntityPackageManager.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,11 +14,16 @@
 
 package org.apache.tapestry5.hibernate;
 
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
+
 import java.util.Collection;
 
 /**
  * Contains a set of contributed package names from which to load entities.
+ * <p/>
+ * The service's configuration is the names of Java packages to search for Hibernate entities.
  */
+@UsesConfiguration(String.class)
 public interface HibernateEntityPackageManager
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateSessionSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateSessionSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateSessionSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-hibernate/src/main/java/org/apache/tapestry5/hibernate/HibernateSessionSource.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,6 +14,7 @@
 
 package org.apache.tapestry5.hibernate;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 import org.hibernate.Session;
 import org.hibernate.SessionFactory;
 import org.hibernate.cfg.Configuration;
@@ -21,7 +22,11 @@
 /**
  * Responsible for creating a Hibernate session as needed. Internally, is responsible for Hibernate {@link
  * Configuration}, resulting in a {@link SessionFactory}.
+ * <p/>
+ * The service's configuration is a {@linkplain org.apache.tapestry5.ioc.services.ChainBuilder chain of command} of
+ * configurator objects.
  */
+@UsesOrderedConfiguration(HibernateConfigurer.class)
 public interface HibernateSessionSource
 {
     /**

Added: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesConfiguration.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesConfiguration.java?rev=711752&view=auto
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesConfiguration.java (added)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesConfiguration.java Wed Nov  5 17:44:01 2008
@@ -0,0 +1,33 @@
+//  Copyright 2008 The Apache Software Foundation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package org.apache.tapestry5.ioc.annotations;
+
+import java.lang.annotation.*;
+
+
+/**
+ * A documentation-only interface placed on service interfaces for services which have an {@linkplain
+ * org.apache.tapestry5.ioc.Configuration unordered configuration}, to identify the type of contribution.
+ */
+@Target(ElementType.TYPE)
+@Retention(RetentionPolicy.CLASS)
+@Documented
+public @interface UsesConfiguration
+{
+    /**
+     * The type of object which may be contributed into the service's configuration.
+     */
+    Class value();
+}

Added: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesMappedConfiguration.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesMappedConfiguration.java?rev=711752&view=auto
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesMappedConfiguration.java (added)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesMappedConfiguration.java Wed Nov  5 17:44:01 2008
@@ -0,0 +1,40 @@
+//  Copyright 2008 The Apache Software Foundation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package org.apache.tapestry5.ioc.annotations;
+
+import java.lang.annotation.*;
+
+/**
+ * A documentation-only interface placed on service interfaces for services which have a {@linkplain
+ * org.apache.tapestry5.ioc.MappedConfiguration mapped configuration}, to identify the type of key (often, a String),
+ * and type ofcontribution.
+ * <p/>
+ * Remember that when the key type is String, the map will be case-insensitive.
+ */
+@Target(ElementType.TYPE)
+@Retention(RetentionPolicy.CLASS)
+@Documented
+public @interface UsesMappedConfiguration
+{
+    /**
+     * The type of key used to identify contribution values.
+     */
+    Class key() default String.class;
+
+    /**
+     * The type of object which may be contributed into the service's configuration.
+     */
+    Class value();
+}

Added: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesOrderedConfiguration.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesOrderedConfiguration.java?rev=711752&view=auto
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesOrderedConfiguration.java (added)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/annotations/UsesOrderedConfiguration.java Wed Nov  5 17:44:01 2008
@@ -0,0 +1,32 @@
+//  Copyright 2008 The Apache Software Foundation
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package org.apache.tapestry5.ioc.annotations;
+
+import java.lang.annotation.*;
+
+/**
+ * A documentation-only interface placed on service interfaces for services which have an {@linkplain
+ * org.apache.tapestry5.ioc.OrderedConfiguration ordered configuration}, to identify the type of contribution.
+ */
+@Target(ElementType.TYPE)
+@Retention(RetentionPolicy.CLASS)
+@Documented
+public @interface UsesOrderedConfiguration
+{
+    /**
+     * The type of object which may be contributed into the service's configuration.
+     */
+    Class value();
+}

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/ServiceDecoratorImpl.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/ServiceDecoratorImpl.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/ServiceDecoratorImpl.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/ServiceDecoratorImpl.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006, 2007 The Apache Software Foundation
+// Copyright 2006, 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,6 +15,7 @@
 package org.apache.tapestry5.ioc.internal;
 
 import org.apache.tapestry5.ioc.ModuleBuilderSource;
+import org.apache.tapestry5.ioc.ObjectLocator;
 import org.apache.tapestry5.ioc.ServiceDecorator;
 import org.apache.tapestry5.ioc.ServiceResources;
 import static org.apache.tapestry5.ioc.internal.util.CollectionFactory.newMap;
@@ -59,6 +60,7 @@
         this.classFactory = classFactory;
 
         parameterDefaults.put(String.class, serviceId);
+        parameterDefaults.put(ObjectLocator.class, resources);
         parameterDefaults.put(ServiceResources.class, resources);
         parameterDefaults.put(Logger.class, logger);
         parameterDefaults.put(Class.class, serviceInterface);

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/MasterObjectProvider.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/MasterObjectProvider.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/MasterObjectProvider.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/MasterObjectProvider.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2007 The Apache Software Foundation
+// Copyright 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -17,11 +17,17 @@
 import org.apache.tapestry5.ioc.AnnotationProvider;
 import org.apache.tapestry5.ioc.ObjectLocator;
 import org.apache.tapestry5.ioc.ObjectProvider;
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 
 /**
- * Rolls up a number of {@link org.apache.tapestry5.ioc.ObjectProvider}, but allows for the case where no object may be
- * provided.
+ * A service that acts as a chain-of-command over a number of {@link org.apache.tapestry5.ioc.ObjectProvider}, but
+ * allows for the case where no object may be provided.
+ * <p/>
+ * This service is itself a key part of Tapestry's general injection mechanism; it is used when instantiating a service
+ * implementation instance, invoking module methods (service builder, decorator, or contribution methods), when
+ * {@linkplain ObjectLocator#autobuild(Class) autobuilding} objects of any type.
  */
+@UsesOrderedConfiguration(ObjectProvider.class)
 public interface MasterObjectProvider
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/ServiceLifecycleSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/ServiceLifecycleSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/ServiceLifecycleSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/ServiceLifecycleSource.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,18 +15,23 @@
 package org.apache.tapestry5.ioc.services;
 
 import org.apache.tapestry5.ioc.ServiceLifecycle;
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
 
 /**
  * Provides access to user defined lifecycles (beyond the two built-in lifecycles: "singleton" and "primitive"). The
  * user defined lifecycles are contributed into the service's configuration.
+ * <p/>
+ * Note that the scope {@linkplain org.apache.tapestry5.ioc.ScopeConstants#DEFAULT default} is special and not a
+ * contribution.
  */
+@UsesMappedConfiguration(ServiceLifecycle.class)
 public interface ServiceLifecycleSource
 {
     /**
      * Used to locate a configuration lifecycle, by name.
      *
-     * @param lifecycleName
+     * @param scope
      * @return the named lifecycle, or null if the name is not found
      */
-    ServiceLifecycle get(String lifecycleName);
+    ServiceLifecycle get(String scope);
 }

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolProvider.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolProvider.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolProvider.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolProvider.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006 The Apache Software Foundation
+// Copyright 2006, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,9 +14,15 @@
 
 package org.apache.tapestry5.ioc.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesMappedConfiguration;
+
 /**
- * A provider of values for symbols.
+ * A provider of values for symbols, used by the {@link org.apache.tapestry5.ioc.services.SymbolSource} service.
+ * <p/>
+ * This is the service interface for the FactoryDefaults and ApplicationDefaults services; each of these takes a
+ * configuration mapping symbols to their values.
  */
+@UsesMappedConfiguration(String.class)
 public interface SymbolProvider
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolSource.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolSource.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolSource.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/SymbolSource.java Wed Nov  5 17:44:01 2008
@@ -1,4 +1,4 @@
-// Copyright 2006, 2007 The Apache Software Foundation
+// Copyright 2006, 2007, 2008 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -14,13 +14,18 @@
 
 package org.apache.tapestry5.ioc.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesOrderedConfiguration;
 import org.apache.tapestry5.ioc.annotations.Value;
 
 /**
  * Used to manage <em>symbols</em>, configuration properties whose value is evaluated at runtime. Symbols use the Ant
  * syntax: <code>${foo.bar.baz}</code> where <code>foo.bar.baz</code> is the name of the symbol. The symbol may appear
- * inside annotation, such as {@link Value}. Values for symbols are provided by {@link SymbolProvider}.
+ * inside annotation, such as {@link Value}.
+ * <p/>
+ * The SymbolSource service configuration is an ordered list of {@link org.apache.tapestry5.ioc.services.SymbolProvider}s.
+ * Two key SymbolProvider services are FactoryDefaults and ApplicationDefaults.
  */
+@UsesOrderedConfiguration(SymbolProvider.class)
 public interface SymbolSource
 {
     /**

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TapestryIOCModule.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TapestryIOCModule.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TapestryIOCModule.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TapestryIOCModule.java Wed Nov  5 17:44:01 2008
@@ -65,9 +65,9 @@
     {
         return new ServiceLifecycleSource()
         {
-            public ServiceLifecycle get(String lifecycleName)
+            public ServiceLifecycle get(String scope)
             {
-                return configuration.get(lifecycleName);
+                return configuration.get(scope);
             }
         };
     }

Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TypeCoercer.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TypeCoercer.java?rev=711752&r1=711751&r2=711752&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TypeCoercer.java (original)
+++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/services/TypeCoercer.java Wed Nov  5 17:44:01 2008
@@ -14,11 +14,14 @@
 
 package org.apache.tapestry5.ioc.services;
 
+import org.apache.tapestry5.ioc.annotations.UsesConfiguration;
+
 /**
- * Makes use of {@link Coercion}s (via {@link CoercionTuple}s) to convert between an input value (of some specific type)
- * and a desired output type. Smart about coercing, even if it requires multiple coercing steps (i.e., via an
+ * Makes use of {@link org.apache.tapestry5.ioc.services.Coercion}s  to convert between an input value (of some specific
+ * type) and a desired output type. Smart about coercing, even if it requires multiple coercion steps (i.e., via an
  * intermediate type, such as String).
  */
+@UsesConfiguration(CoercionTuple.class)
 public interface TypeCoercer
 {
     /**



Mime
View raw message