2014-01-24 118 views
0

我用post構造方法(使用@PostContruct)編寫了一個託管bean,但該方法沒有被調用。我使用了帶有Jboss 7.1.1和Icefaces 3.0的liferay liferay-portal-6.1.2-ce-ga3。有人能幫我解決這個問題嗎?Post Construct不叫



    @SessionScoped 
    @ManagedBean 
    public class DetalleVaPortletBean extends BackingPortletUI {
private static final long serialVersionUID = -7127465434575796794L;
public DetalleVaPortletBean() { try { System.out.println(this); } catch (Exception e) { error(e); } } @PostConstruct public void postConstruct(){ adicionarPortletPrincipal(); } }
+0

這是一個Spring配置,我沒有使用Spring – gu3rr3ro

回答

0

首先,enshure您DetalleVaPortletBean對象確實是由考試系統控制檯輸出構造和 System.out.println(this);

找到輸出可能是helpul在構造函數中,例如一些打印System.out.println("DetalleVaPortletBean CTOR");