| org.apache.tapestry.ioc.ServiceBinder
All known Subclasses: org.apache.tapestry.ioc.internal.ServiceBinderImpl,
ServiceBinder | public interface ServiceBinder (Code) | | Allows a module to bind service interfaces to service implementation classes in support of
autobuilding services. A ServiceBinder is passed to to a method with the following signature:
public static void bind(ServiceBinder binder) . This is an adaptation of ideas
from Guice.
|
bind | ServiceBindingOptions bind(Class<T> implementationClass)(Code) | | Defines a service in terms of an implementation class, without a service interface. In this
case, the service will not be proxiable (proxying requires a service interface) and
ServiceDef.getServiceInterface will return the implementation class. In this
situation, the service will not be proxied; it will be instantiated fully on first reference
(ignoring its scope, if any) and will not be decorated.
< Parameters: T - > Parameters: implementationClass - |
bind | ServiceBindingOptions bind(Class<T> serviceInterface, Class<? extends T> serviceImplementation)(Code) | | Binds the service interface to a service implementation class. The default service name is
the unqualified name of the service interface. The default service scope is "singleton",
unless the service implementation class includes the
Scope annotation.
< Parameters: T - > Parameters: serviceInterface - service interface (used when locating services, and when building proxies) Parameters: serviceImplementation - implementation class that implements the service interface binding options, used to specify additional details about the service. |
|
|