//A Java Bean
public class Man {
private String name;
private int age;
public int getAge() {
return age;
}
public void setAge(int age) {
this.age = age;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
}
A:call directly container
//invocation code with container
import org.jmin.ioc.BeanContainer;
import org.jmin.ioc.BeanElementFactory;
import org.jmin.ioc.BeanParameter;
import org.jmin.ioc.BeanParameterFactory;
import org.jmin.ioc.element.InjectionProperty;
import org.jmin.ioc.impl.BeanContainerImpl;... read more
1 Introduction
minbox is a java micro-container, which can manage bean definition and supply bean instance for outside caller, then the developers needn't create object instance with 'new' keyword. The container is very easy to study, and fast development in java application.
2 Bean elements
Before creation, bean definition must be existed in container. Some descript object are used to define bean part definition and work as instruction to container, we call them as elements. Some elements are listed below... read more