Adds a field in the annotated type for each given class. Both the declared classes and the using class have to be registered
in the Spring context, as the fields are autowired by Spring.
For further information about Xtend's extension mechanism consult consult
Xtend's
documentation.
Usage example:
@UseBean(MyBean)
class MyType {
static class MyBean {
def void someBeanMethod() {
}
}
}
Leads to:
public class MyType {
public static class MyBean {
public void someBeanMethod() {
}
}
@Autowired
private MyType.MyBean myBean;
}