View Javadoc
1   //////////////////////////////////////////////////////////////////////////////
2   // dexterIM - Instant Messaging Framework
3   // Copyright (C) 2003  Christoph Walcher
4   //
5   // This program is free software; you can redistribute it and/or modify
6   // it under the terms of the GNU General Public License as published by
7   // the Free Software Foundation; either version 2 of the License, or
8   // (at your option) any later version.
9   //
10  // This program is distributed in the hope that it will be useful,
11  // but WITHOUT ANY WARRANTY; without even the implied warranty of
12  // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  // GNU General Public License for more details.
14  //
15  // You should have received a copy of the GNU General Public License
16  // along with this program; if not, write to the Free Software
17  // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
18  //////////////////////////////////////////////////////////////////////////////
19  package net.sf.dexterim.msn.message;
20  
21  
22  import java.util.StringTokenizer;
23  
24  import net.sf.dexterim.msn.MsnConnection;
25  
26  /***
27   *  Description of the Class
28   *
29   *@author     christoph
30   */
31  public class OfflineMessage extends SingleLineMessage {
32    private String status;
33    private String account;
34  
35    /***
36     *  Constructor for the OfflineMessage object
37     */
38    public OfflineMessage() {
39    }
40  
41    /***
42     *  Gets the messageCommand attribute of the OfflineMessage object
43     *
44     *@return    The messageCommand value
45     */
46    public String getMessageCommand() {
47      return MsnMessageFactory.CMD_OFFLINE;
48    }
49  
50    /***
51     *  Getter for property status.
52     *
53     *@return    Value of property status.
54     */
55    public java.lang.String getStatus() {
56      return status;
57    }
58  
59    /***
60     *  Getter for property account.
61     *
62     *@return    Value of property account.
63     */
64    public java.lang.String getAccount() {
65      return account;
66    }
67  
68    /***
69     *  Adds a feature to the Line attribute of the OfflineMessage object
70     *
71     *@param  line  The feature to be added to the Line attribute
72     *@return       Description of the Return Value
73     */
74    public MsnMessage addLine(String line) {
75      StringTokenizer st = new StringTokenizer(line);
76  
77      status = st.nextToken();
78  
79      account = st.nextToken();
80  
81      return this;
82    }
83  
84    /* (non-Javadoc)
85     * @see net.sf.dexterim.msn.message.MsnMessage#process(net.sf.dexterim.msn.MsnConnection)
86     */
87    public void process(MsnConnection connection) {
88      // TODO Auto-generated method stub
89      
90    }
91  }