Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members  

JID.hh

00001 // JID.hh
00002 // Jabber client library
00003 //
00004 // Original Code Copyright (C) 1999-2001 Dave Smith (dave@jabber.org)
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License, or (at your option) any later version.
00010 // 
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 // 
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00019 //
00020 // Contributor(s): Julian Missig
00021 //
00022 // This Original Code has been modified by IBM Corporation. Modifications 
00023 // made by IBM described herein are Copyright (c) International Business 
00024 // Machines Corporation, 2002.
00025 //
00026 // Date             Modified by     Description of modification
00027 // 01/20/2002       IBM Corp.       Updated to libjudo 1.1.1
00028 // 2002-03-05       IBM Corp.       Updated to libjudo 1.1.5
00029 // 2002-07-09       IBM Corp.       Added Roster::getSession()
00030 //
00031 // =====================================================================================
00032 
00033 #ifndef JID_HH
00034 #define JID_HH
00035 
00036 #include <string>
00037 
00038 namespace jabberoo
00039 {
00045      class JID 
00046           {
00047           public:
00052                static std::string getResource(const std::string& jid);
00057                static std::string getUserHost(const std::string& jid);      
00062                static std::string getHost(const std::string& jid);
00067                static std::string getUser(const std::string& jid);
00072                static bool isValidUser(const std::string& user);
00077                static bool isValidHost(const std::string& host);
00084                static int compare(const std::string& ljid, const std::string& rjid);
00085 
00090                struct Compare {
00095                     bool operator()(const std::string& lhs, const std::string& rhs) const;
00096                };
00097           };
00098 }  // namespace jabberoo
00099 #endif // #ifndef JID_HH

Generated on Thu Jul 24 13:31:51 2003 for jabberoo by doxygen1.3-rc3