KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > exoplatform > portal > session > PopupMessageInfo


1 /***************************************************************************
2  * Copyright 2001-2003 The eXo Platform SARL All rights reserved. *
3  * Please look at license.txt in info directory for more license detail. *
4  **************************************************************************/

5 package org.exoplatform.portal.session;
6 /**
7  * @author Tuan Nguyen (tuan08@users.sourceforge.net)
8  * @since Jan 8, 2005
9  * @version $Id$
10  */

11 public class PopupMessageInfo {
12   private StringBuffer JavaDoc buf_ ;
13   
14   public void addMessage(String JavaDoc message) {
15     if(buf_ == null) buf_ = new StringBuffer JavaDoc() ;
16     else buf_.append("\n") ;
17     buf_.append(message) ;
18   }
19   
20   public String JavaDoc getPupupMessage() {
21     if(buf_ == null) return null ;
22     String JavaDoc s = buf_.toString() ;
23     buf_ = null ;
24     return s ;
25   }
26 }
27
Popular Tags