|
|||||||||||||||||||
30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover | |||||||||||||||||||
Source file | Conditionals | Statements | Methods | TOTAL | |||||||||||||||
Parameter.java | - | - | - | - |
|
1 |
/*****************************************************************************
|
|
2 |
* Copyright (c) PicoContainer Organization. All rights reserved. *
|
|
3 |
* ------------------------------------------------------------------------- *
|
|
4 |
* The software in this package is published under the terms of the BSD *
|
|
5 |
* style license a copy of which has been included with this distribution in *
|
|
6 |
* the LICENSE.txt file. *
|
|
7 |
* *
|
|
8 |
* Idea by Rachel Davies, Original code by Jon Tirsen *
|
|
9 |
*****************************************************************************/
|
|
10 |
|
|
11 |
package org.picocontainer;
|
|
12 |
|
|
13 |
/**
|
|
14 |
* This class provides control over the arguments that will be passed to a constructor. It can be used for finer control
|
|
15 |
* over what arguments are passed to a particular constructor.
|
|
16 |
*
|
|
17 |
* @author Jon Tirsén
|
|
18 |
* @author Aslak Hellesøy
|
|
19 |
* @version $Revision: 1.16 $
|
|
20 |
* @see MutablePicoContainer#registerComponentImplementation(Object,Class,Parameter[]) registerComponentImplementation
|
|
21 |
* @see org.picocontainer.defaults.ComponentParameter
|
|
22 |
* @see org.picocontainer.defaults.ConstantParameter
|
|
23 |
* @since 1.0
|
|
24 |
*/
|
|
25 |
public interface Parameter { |
|
26 |
/**
|
|
27 |
* Retrieve the component adapter that should be used to find the instance to be passed in for this parameter.
|
|
28 |
*
|
|
29 |
* @param picoContainer the container from which dependencies are resolved.
|
|
30 |
* @param expectedType the type that the returned adapter needs to provide.
|
|
31 |
* @return the component adapter that should be used to find the instance to be passed in for this parameter. Should
|
|
32 |
* return <code>null</code> if not suitable adapter can be found.
|
|
33 |
*/
|
|
34 |
ComponentAdapter resolveAdapter(PicoContainer picoContainer, Class expectedType); |
|
35 |
} |
|
36 |
|
|