[cl-xmpp-cvs] CVS cl-xmpp
jstecklina
jstecklina at common-lisp.net
Mon Aug 28 21:17:11 UTC 2006
Update of /project/cl-xmpp/cvsroot/cl-xmpp
In directory clnet:/tmp/cvs-serv20851
Modified Files:
cl-xmpp.lisp
Log Message:
Added status messages and priority to PRESENCE.
--- /project/cl-xmpp/cvsroot/cl-xmpp/cl-xmpp.lisp 2006/05/12 17:45:49 1.27
+++ /project/cl-xmpp/cvsroot/cl-xmpp/cl-xmpp.lisp 2006/08/28 21:17:08 1.28
@@ -1,4 +1,4 @@
-;;;; $Id: cl-xmpp.lisp,v 1.27 2006/05/12 17:45:49 eenge Exp $
+;;;; $Id: cl-xmpp.lisp,v 1.28 2006/08/28 21:17:08 jstecklina Exp $
;;;; $Source: /project/cl-xmpp/cvsroot/cl-xmpp/cl-xmpp.lisp,v $
;;;; See the LICENSE file for licensing information.
@@ -487,13 +487,22 @@
(add-auth-method :digest-md5 '%digest-md5-auth%)
-(defmethod presence ((connection connection) &key type to)
+(defmethod presence ((connection connection) &key type to status show priority)
(with-xml-output (connection)
(cxml:with-element "presence"
(when type
(cxml:attribute "type" type))
(when to
- (cxml:attribute "to" to)))))
+ (cxml:attribute "to" to))
+ (when status
+ (cxml:with-element "status"
+ (cxml:text status)))
+ (when show
+ (cxml:with-element "show"
+ (cxml:text show)))
+ (when priority
+ (cxml:with-element "priority"
+ (cxml:text (format nil "~A" priority)))))))
(defmethod message ((connection connection) to body &key id (type :chat))
(with-xml-output (connection)
More information about the Cl-xmpp-cvs
mailing list