KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > quikj > application > web > talk > plugin > EndPointInfo


1 package com.quikj.application.web.talk.plugin;
2
3 import com.quikj.server.web.*;
4
5 public class EndPointInfo
6 {
7     public EndPointInfo()
8     {
9     }
10     
11     public EndPointInterface getEndPoint()
12     {
13         return endpoint;
14     }
15     
16     public void setEndPoint(EndPointInterface endpoint)
17     {
18         this.endpoint = endpoint;
19     }
20     
21     /** Getter for property callCount.
22      * @return Value of property callCount.
23      */

24     public int getCallCount()
25     {
26         return callCount;
27     }
28     
29     /** Setter for property callCount.
30      * @param callCount New value of property callCount.
31      */

32     public void setCallCount(int callCount)
33     {
34         this.callCount = callCount;
35     }
36     
37     public int incrementCallCount()
38     // returns active call count, after incrementing
39
{
40         //System.out.println ("Incrementing call count for user " + userData.getName());
41
return ++callCount;
42     }
43     
44     public int decrementCallCount()
45     // returns active call count, after decrementing
46
{
47         //System.out.println ("Decrementing call count for user " + userData.getName());
48
return --callCount;
49     }
50     
51     /** Getter for property userData.
52      * @return Value of property userData.
53      */

54     public UserElement getUserData()
55     {
56         return userData;
57     }
58     
59     /** Setter for property userData.
60      * @param userData New value of property userData.
61      */

62     public void setUserData(UserElement userData)
63     {
64         this.userData = userData;
65     }
66     
67     public String JavaDoc getName()
68     {
69         if (userData == null)
70         {
71             return "Nulldata";
72         }
73         
74         return userData.getName();
75     }
76
77     /**
78      * @return Returns the dnd.
79      */

80     public boolean isDnd()
81     {
82         return dnd;
83     }
84     /**
85      * @param dnd The dnd to set.
86      */

87     public void setDnd(boolean dnd)
88     {
89         this.dnd = dnd;
90     }
91     
92     private EndPointInterface endpoint = null;
93     
94     private int callCount = 0;
95     
96     private UserElement userData = null;
97     
98     private boolean dnd = false;
99
100 }
101
102
Popular Tags