Is there an equivalent of @Startup annotation in Seam which I could use in components.xml?
+2
A:
Per http://www.jboss.com/products/seam/components-2.2.xsd you can use startup=true|false
<xs:attribute name="startup" default="false" type="components:boolean">
<xs:annotation>
<xs:documentation>
Indicates that an instance of the component should be created when the
the component's controlling scope starts. This is only used for application and
session scope.
</xs:documentation>
</xs:annotation>
</xs:attribute>
shipmaster
2010-06-29 16:37:54
Duh. My tireness spoke when I was writing the question. The question was meant to ask about the @Create annotation. How about that?
Markos Fragkakis
2010-06-29 16:44:44
The closest I think to that is to define a factory and call your initialization from the factory method e.g. <factory name="contact" method="#{contactManager.loadContact}" scope="CONVERSATION"/>
shipmaster
2010-06-29 17:02:14
Cheers, that will work for me. (+1)
Markos Fragkakis
2010-06-30 07:42:21