public class PicoContainerWrapper extends Object implements ContainerWrapper, Serializable
| 限定符和类型 | 字段和说明 |
|---|---|
static String |
module |
OrignalKey| 构造器和说明 |
|---|
PicoContainerWrapper(ConfigInfo configInfo)
construct a picocontainer without cache.
|
| 限定符和类型 | 方法和说明 |
|---|---|
List |
getAllInstances()
return all instances
|
Class |
getComponentClass(String name)
return a component class from container
|
List |
getComponentInstancesOfType(Class componentType)
get all instances of a class type
|
Object |
getComponentNewInstance(String name)
This method will usually create a new instance each time it is called
|
RegistryDirectory |
getRegistryDirectory()
return all registered components's class/name in container.
|
boolean |
isStart() |
Object |
lookup(String name)
return singleton component instance from container every times it return
same a instance
|
Object |
lookupOriginal(String name)
return singleton component instance without proxy.
|
void |
register(String name)
register a component, its class value is its name value
|
void |
register(String name,
Class className)
register a component class
|
void |
register(String name,
Class className,
String[] constructors)
register a component class with constructors of String type
|
void |
register(String name,
Object instance)
register a component instance
|
void |
registerContainerCallback() |
void |
setStart(boolean start) |
void |
start()
start the container this method will active all components's startup
methods in container,
|
void |
stop()
stop the container this method will active all components's stop methods
in container.
|
public static final String module
public PicoContainerWrapper(ConfigInfo configInfo)
public void registerContainerCallback()
public void register(String name, Class className)
ContainerWrapperregister 在接口中 ContainerWrappername - component nameclassName - component classpublic void register(String name)
ContainerWrapperregister 在接口中 ContainerWrappername - the name must be a class stringpublic void register(String name, Class className, String[] constructors)
ContainerWrapperregister 在接口中 ContainerWrappername - component nameclassName - component classconstructors - component constructor parameterspublic void register(String name, Object instance)
ContainerWrapperregister 在接口中 ContainerWrappername - component nameinstance - component instancepublic void start()
ContainerWrapperstart 在接口中 ContainerWrapperpublic void stop()
ContainerWrapperstop 在接口中 ContainerWrapperpublic boolean isStart()
isStart 在接口中 ContainerWrapperpublic void setStart(boolean start)
setStart 在接口中 ContainerWrapperpublic List getAllInstances()
ContainerWrappergetAllInstances 在接口中 ContainerWrapperpublic Object lookup(String name)
ContainerWrapperlookup 在接口中 ContainerWrappername - component namepublic Object lookupOriginal(String name)
ContainerWrapperlookupOriginal 在接口中 ContainerWrapperpublic Object getComponentNewInstance(String name)
getComponentNewInstance 在接口中 ContainerWrappername - component namepublic Class getComponentClass(String name)
ContainerWrappergetComponentClass 在接口中 ContainerWrapperpublic List getComponentInstancesOfType(Class componentType)
ContainerWrappergetComponentInstancesOfType 在接口中 ContainerWrapperpublic RegistryDirectory getRegistryDirectory()
ContainerWrappergetRegistryDirectory 在接口中 ContainerWrapperCopyright © 2018. All rights reserved.