Examples of sendPresence()


Examples of chatroom.server.dataclass.User.sendPresence()

                User user = server.getUserByConnection(connection);
                int ret = user.joinRoomWithNickname(room, jid.getName());
                if (ret == 1) {
                    for (String other : room.getUserList()) {
                        if (!other.equals(jid.getName())) {
                            user.sendPresence(room, jid.getName(), other, null);
                        }
                    }
                    room.broadcastPresence(jid.getName(), null);
                } else if (ret == 0) {
                    // The nick already existed, send a conflict.
View Full Code Here

Examples of com.google.appengine.api.xmpp.XMPPService.sendPresence()

            datastore.put(userEntity);

        } else if (presence.getPresenceType() == PresenceType.PROBE) {
            // Respond to the probe by sending the app's presence.
            Entity statusEntity = MainPageServlet.getStatusEntity();
            xmpp.sendPresence(userJID,
                              ((Boolean)statusEntity.getProperty("presence_available")) ?
                              PresenceType.AVAILABLE : PresenceType.UNAVAILABLE,
                              PresenceShow.valueOf(((String)statusEntity.getProperty("presence_show")).toUpperCase()),
                              (String)statusEntity.getProperty("status_message"));
        }
View Full Code Here

Examples of com.google.appengine.api.xmpp.XMPPService.sendPresence()

        } else if (jid != null && command.equals("invite")) {
            xmpp.sendInvitation(jid);
            adminMessage = "Chat message sent to JID " + jidStr + ".";

        } else if (jid != null && command.equals("probe")) {
            xmpp.sendPresence(jid, PresenceType.PROBE, null, null);
            adminMessage = "A presence probe has been sent to JID " + jidStr + ".";

        } else if (command.equals("presence")) {
            // Store the app's presence.
            Entity statusEntity = MainPageServlet.getStatusEntity();
View Full Code Here

Examples of com.google.appengine.api.xmpp.XMPPService.sendPresence()

                                                      true);
            PreparedQuery pq = datastore.prepare(q);
            for (Entity e : pq.asIterable()) {
                String recipJidStr = (String)(e.getProperty("jid"));
                JID recipJid = new JID(recipJidStr);
                xmpp.sendPresence(recipJid,
                                  ((Boolean)statusEntity.getProperty("presence_available")) ?
                                  PresenceType.AVAILABLE : PresenceType.UNAVAILABLE,
                                  PresenceShow.valueOf(((String)statusEntity.getProperty("presence_show")).toUpperCase()),
                                  (String)statusEntity.getProperty("status_message"));
            }
View Full Code Here

Examples of nu.fw.jeti.plugins.Avatars.sendPresence()

   
    backend.send(new InfoQuery("set",new VCard(tempPersonal,tempBusiness,null,null)));
    if(PluginsInfo.isPluginLoaded("ichatavatars"))
    {
      Avatars a = (Avatars)PluginsInfo.getPluginInstance("ichatavatars");
      a.sendPresence();
    }
    dispose();
  }
 
  private String encode(File file)
View Full Code Here

Examples of org.olat.instantMessaging.InstantMessagingClient.sendPresence()

               * last access was more than five minutes ago
               * so set instant messaging presence to away
               */
              if ((client != null && client.isConnected())
                  && (client.getPresenceMode() == Presence.Mode.away || client.getPresenceMode() == Presence.Mode.xa)) {
                client.sendPresence(Presence.Type.available, null, 0, Presence.Mode.valueOf(client.getRecentPresenceStatusMode()));
                // inform the GUI
                InstantMessagingModule.getAdapter().getClientManager().sendPresenceEvent(Presence.Type.available, username);
                if (log.isDebug()) {
                  log.debug("change presence for user " + client.getUsername() + " back to recent presence.");
                }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.