00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef REMOTE_ROSTER_H
00029 #define REMOTE_ROSTER_H
00030
00031 #include <RMessageBuild.h>
00032
00033 #include <Archivable.h>
00034 #include <Messenger.h>
00035 #include <NetAddress.h>
00036 #include <OS.h>
00037
00038 struct app_info;
00039 class BList;
00040 class RemoteRosterImpl;
00041
00042 class _IMPEXP_RMESSAGE RemoteRoster {
00043 public:
00044 RemoteRoster(const BNetAddress* address = NULL);
00045 RemoteRoster(const char* host);
00046 ~RemoteRoster();
00047
00048 status_t SetTo(const BNetAddress* address);
00049 status_t SetTo(const char* host);
00050 void Unset();
00051 status_t InitCheck() const;
00052
00053 status_t GetAppList(BList* teams) const;
00054 status_t GetAppList(const char* signature,
00055 BList* teams) const;
00056 team_id TeamFor(const char* signature) const;
00057 status_t GetRunningAppInfo(const char* signature,
00058 app_info* info) const;
00059 status_t GetRunningAppInfo(team_id team,
00060 app_info* info) const;
00061 status_t GetActiveAppInfo(app_info* info) const;
00062
00063 status_t GetMessenger(const char* signature,
00064 BMessenger* messenger,
00065 bool byName = false) const;
00066 status_t GetMessenger(team_id team,
00067 BMessenger* messenger) const;
00068
00069 private:
00070 status_t fInitStatus;
00071 BNetAddress* fAddress;
00072 RemoteRosterImpl* fImpl;
00073 };
00074
00075 #endif // REMOTE_ROSTER_H