mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-11 01:59:38 +02:00
add generics
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@11422 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
0b7421eae3
commit
06805b248d
9 changed files with 52 additions and 51 deletions
|
@ -47,17 +47,17 @@ public class AgentStatusRequest extends IQ {
|
|||
*/
|
||||
public static final String NAMESPACE = "http://jabber.org/protocol/workgroup";
|
||||
|
||||
private Set agents;
|
||||
private Set<Item> agents;
|
||||
|
||||
public AgentStatusRequest() {
|
||||
agents = new HashSet();
|
||||
agents = new HashSet<Item>();
|
||||
}
|
||||
|
||||
public int getAgentCount() {
|
||||
return agents.size();
|
||||
}
|
||||
|
||||
public Set getAgents() {
|
||||
public Set<Item> getAgents() {
|
||||
return Collections.unmodifiableSet(agents);
|
||||
}
|
||||
|
||||
|
@ -73,7 +73,7 @@ public class AgentStatusRequest extends IQ {
|
|||
StringBuilder buf = new StringBuilder();
|
||||
buf.append("<").append(ELEMENT_NAME).append(" xmlns=\"").append(NAMESPACE).append("\">");
|
||||
synchronized (agents) {
|
||||
for (Iterator i=agents.iterator(); i.hasNext(); ) {
|
||||
for (Iterator<Item> i=agents.iterator(); i.hasNext(); ) {
|
||||
Item item = (Item) i.next();
|
||||
buf.append("<agent jid=\"").append(item.getJID()).append("\">");
|
||||
if (item.getName() != null) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue