Java 类org.jivesoftware.smackx.RemoteRosterEntry 实例源码

项目:EIM    文件:RosterExchange.java   
/**
   * Adds a roster entry to the packet.
   *
   * @param rosterEntry a roster entry to add.
   */
  public void addRosterEntry(RosterEntry rosterEntry) {
// Obtain a String[] from the roster entry groups name 
List<String> groupNamesList = new ArrayList<String>();
String[] groupNames;
for (RosterGroup group : rosterEntry.getGroups()) {
    groupNamesList.add(group.getName());
}
groupNames = groupNamesList.toArray(new String[groupNamesList.size()]);

      // Create a new Entry based on the rosterEntry and add it to the packet
      RemoteRosterEntry remoteRosterEntry = new RemoteRosterEntry(rosterEntry.getUser(),
              rosterEntry.getName(), groupNames);

      addRosterEntry(remoteRosterEntry);
  }
项目:androidPN-client.    文件:RosterExchange.java   
/**
   * Adds a roster entry to the packet.
   *
   * @param rosterEntry a roster entry to add.
   */
  public void addRosterEntry(RosterEntry rosterEntry) {
// Obtain a String[] from the roster entry groups name 
List<String> groupNamesList = new ArrayList<String>();
String[] groupNames;
for (RosterGroup group : rosterEntry.getGroups()) {
    groupNamesList.add(group.getName());
}
groupNames = groupNamesList.toArray(new String[groupNamesList.size()]);

      // Create a new Entry based on the rosterEntry and add it to the packet
      RemoteRosterEntry remoteRosterEntry = new RemoteRosterEntry(rosterEntry.getUser(),
              rosterEntry.getName(), groupNames);

      addRosterEntry(remoteRosterEntry);
  }
项目:xmppsupport_v2    文件:RosterExchange.java   
/**
 * Adds a roster entry to the packet.
 * 
 * @param rosterEntry
 *            a roster entry to add.
 */
public void addRosterEntry(RosterEntry rosterEntry) {
    // Obtain a String[] from the roster entry groups name
    List<String> groupNamesList = new ArrayList<String>();
    String[] groupNames;
    for (RosterGroup group : rosterEntry.getGroups()) {
        groupNamesList.add(group.getName());
    }
    groupNames = groupNamesList.toArray(new String[groupNamesList.size()]);

    // Create a new Entry based on the rosterEntry and add it to the packet
    RemoteRosterEntry remoteRosterEntry = new RemoteRosterEntry(
            rosterEntry.getUser(), rosterEntry.getName(), groupNames);

    addRosterEntry(remoteRosterEntry);
}
项目:java-bells    文件:RosterExchange.java   
/**
   * Adds a roster entry to the packet.
   *
   * @param rosterEntry a roster entry to add.
   */
  public void addRosterEntry(RosterEntry rosterEntry) {
// Obtain a String[] from the roster entry groups name 
List<String> groupNamesList = new ArrayList<String>();
String[] groupNames;
for (RosterGroup group : rosterEntry.getGroups()) {
    groupNamesList.add(group.getName());
}
groupNames = groupNamesList.toArray(new String[groupNamesList.size()]);

      // Create a new Entry based on the rosterEntry and add it to the packet
      RemoteRosterEntry remoteRosterEntry = new RemoteRosterEntry(rosterEntry.getUser(),
              rosterEntry.getName(), groupNames);

      addRosterEntry(remoteRosterEntry);
  }
项目:telegraph    文件:RosterExchange.java   
/**
   * Adds a roster entry to the packet.
   *
   * @param rosterEntry a roster entry to add.
   */
  public void addRosterEntry(RosterEntry rosterEntry) {
// Obtain a String[] from the roster entry groups name 
List<String> groupNamesList = new ArrayList<String>();
String[] groupNames;
for (RosterGroup group : rosterEntry.getGroups()) {
    groupNamesList.add(group.getName());
}
groupNames = groupNamesList.toArray(new String[groupNamesList.size()]);

      // Create a new Entry based on the rosterEntry and add it to the packet
      RemoteRosterEntry remoteRosterEntry = new RemoteRosterEntry(rosterEntry.getUser(),
              rosterEntry.getName(), groupNames);

      addRosterEntry(remoteRosterEntry);
  }
项目:NewCommunication-Android    文件:RosterExchange.java   
/**
   * Adds a roster entry to the packet.
   *
   * @param rosterEntry a roster entry to add.
   */
  public void addRosterEntry(RosterEntry rosterEntry) {
// Obtain a String[] from the roster entry groups name 
List<String> groupNamesList = new ArrayList<String>();
String[] groupNames;
for (RosterGroup group : rosterEntry.getGroups()) {
    groupNamesList.add(group.getName());
}
groupNames = groupNamesList.toArray(new String[groupNamesList.size()]);

      // Create a new Entry based on the rosterEntry and add it to the packet
      RemoteRosterEntry remoteRosterEntry = new RemoteRosterEntry(rosterEntry.getUser(),
              rosterEntry.getName(), groupNames);

      addRosterEntry(remoteRosterEntry);
  }
项目:androidPN-client.    文件:RosterExchange.java   
/**
 * Returns an Iterator for the roster entries in the packet.
 *
 * @return an Iterator for the roster entries in the packet.
 */
public Iterator<RemoteRosterEntry> getRosterEntries() {
    synchronized (remoteRosterEntries) {
        List<RemoteRosterEntry> entries = Collections.unmodifiableList(new ArrayList<RemoteRosterEntry>(remoteRosterEntries));
        return entries.iterator();
    }
}
项目:java-bells    文件:RosterExchange.java   
/**
 * Returns an Iterator for the roster entries in the packet.
 *
 * @return an Iterator for the roster entries in the packet.
 */
public Iterator<RemoteRosterEntry> getRosterEntries() {
    synchronized (remoteRosterEntries) {
        List<RemoteRosterEntry> entries = Collections.unmodifiableList(new ArrayList<RemoteRosterEntry>(remoteRosterEntries));
        return entries.iterator();
    }
}
项目:EIM    文件:RosterExchange.java   
/**
 * Adds a remote roster entry to the packet.
 *
 * @param remoteRosterEntry a remote roster entry to add.
 */
public void addRosterEntry(RemoteRosterEntry remoteRosterEntry) {
    synchronized (remoteRosterEntries) {
        remoteRosterEntries.add(remoteRosterEntry);
    }
}
项目:androidPN-client.    文件:RosterExchange.java   
/**
 * Adds a remote roster entry to the packet.
 *
 * @param remoteRosterEntry a remote roster entry to add.
 */
public void addRosterEntry(RemoteRosterEntry remoteRosterEntry) {
    synchronized (remoteRosterEntries) {
        remoteRosterEntries.add(remoteRosterEntry);
    }
}
项目:java-bells    文件:RosterExchange.java   
/**
 * Adds a remote roster entry to the packet.
 *
 * @param remoteRosterEntry a remote roster entry to add.
 */
public void addRosterEntry(RemoteRosterEntry remoteRosterEntry) {
    synchronized (remoteRosterEntries) {
        remoteRosterEntries.add(remoteRosterEntry);
    }
}
项目:telegraph    文件:RosterExchange.java   
/**
 * Adds a remote roster entry to the packet.
 *
 * @param remoteRosterEntry a remote roster entry to add.
 */
public void addRosterEntry(RemoteRosterEntry remoteRosterEntry) {
    synchronized (remoteRosterEntries) {
        remoteRosterEntries.add(remoteRosterEntry);
    }
}
项目:NewCommunication-Android    文件:RosterExchange.java   
/**
 * Adds a remote roster entry to the packet.
 *
 * @param remoteRosterEntry a remote roster entry to add.
 */
public void addRosterEntry(RemoteRosterEntry remoteRosterEntry) {
    synchronized (remoteRosterEntries) {
        remoteRosterEntries.add(remoteRosterEntry);
    }
}
项目:xmppsupport_v2    文件:RosterExchange.java   
/**
 * Adds a remote roster entry to the packet.
 * 
 * @param remoteRosterEntry
 *            a remote roster entry to add.
 */
public void addRosterEntry(RemoteRosterEntry remoteRosterEntry) {
    synchronized (remoteRosterEntries) {
        remoteRosterEntries.add(remoteRosterEntry);
    }
}