# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

login_client.h

Go to the documentation of this file.
00001 
00009 /* Copyright, 2000 Nevrax Ltd.
00010  *
00011  * This file is part of NEVRAX NEL.
00012  * NEVRAX NEL is free software; you can redistribute it and/or modify
00013  * it under the terms of the GNU General Public License as published by
00014  * the Free Software Foundation; either version 2, or (at your option)
00015  * any later version.
00016 
00017  * NEVRAX NEL is distributed in the hope that it will be useful, but
00018  * WITHOUT ANY WARRANTY; without even the implied warranty of
00019  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
00020  * General Public License for more details.
00021 
00022  * You should have received a copy of the GNU General Public License
00023  * along with NEVRAX NEL; see the file COPYING. If not, write to the
00024  * Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
00025  * MA 02111-1307, USA.
00026  */
00027 
00028 #ifndef NL_LOGIN_CLIENT_H
00029 #define NL_LOGIN_CLIENT_H
00030 
00031 #include "nel/misc/types_nl.h"
00032 
00033 #include <string>
00034 #include <vector>
00035 
00036 #include "nel/net/callback_client.h"
00037 
00038 namespace NLNET
00039 {
00040 
00041 class CLoginCookie;
00042 class CUdpSock;
00043 class IDisplayer;
00044 
00059 class CLoginClient {
00060 public:
00061 
00062         struct CShardEntry
00063         {
00064                 std::string ShardName;
00065                 std::string WSAddr;
00066         };
00067 
00068         typedef std::vector<CShardEntry> TShardList;
00069 
00070 
00074         static void setInformations (std::string gfxInfos) { _GfxInfos = gfxInfos; }
00075 
00076 
00083         static std::string authenticate (const std::string &loginServiceAddr, const std::string &login, const std::string &password, uint32 clientVersion);
00084 
00085 
00088         static std::string connectToShard (uint32 shardListIndex, CCallbackClient &cnx);
00089 
00092         static std::string connectToShard (uint32 shardListIndex, CUdpSock &cnx, CLoginCookie &cookie);
00093 
00094         static TShardList ShardList;
00095 
00096 private:
00097 
00098         static std::string confirmConnection (uint32 shardListIndex);
00099 
00100         static std::string _GfxInfos;
00101 
00102         static CCallbackClient *_CallbackClient;
00103 
00104 };
00105 
00106 
00107 } // NLNET
00108 
00109 #endif // NL_LOGIN_CLIENT_H
00110 
00111 /* End of login_client.h */