lltransfermanager.h 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677
  1. /**
  2. * @file lltransfermanager.h
  3. * @brief Improved transfer mechanism for moving data through the
  4. * message system.
  5. *
  6. * $LicenseInfo:firstyear=2006&license=viewergpl$
  7. *
  8. * Copyright (c) 2006-2009, Linden Research, Inc.
  9. *
  10. * Second Life Viewer Source Code
  11. * The source code in this file ("Source Code") is provided by Linden Lab
  12. * to you under the terms of the GNU General Public License, version 2.0
  13. * ("GPL"), unless you have obtained a separate licensing agreement
  14. * ("Other License"), formally executed by you and Linden Lab. Terms of
  15. * the GPL can be found in doc/GPL-license.txt in this distribution, or
  16. * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
  17. *
  18. * There are special exceptions to the terms and conditions of the GPL as
  19. * it is applied to this Source Code. View the full text of the exception
  20. * in the file doc/FLOSS-exception.txt in this software distribution, or
  21. * online at
  22. * http://secondlifegrid.net/programs/open_source/licensing/flossexception
  23. *
  24. * By copying, modifying or distributing this software, you acknowledge
  25. * that you have read and understood your obligations described above,
  26. * and agree to abide by those obligations.
  27. *
  28. * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
  29. * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
  30. * COMPLETENESS OR PERFORMANCE.
  31. * $/LicenseInfo$
  32. */
  33. #ifndef LL_LLTRANSFERMANAGER_H
  34. #define LL_LLTRANSFERMANAGER_H
  35. #include <list>
  36. #include <map>
  37. #include "llassettype.h"
  38. #include "llhost.h"
  39. #include "lluuid.h"
  40. class LLDataPacker;
  41. class LLMessageSystem;
  42. class LLTransferConnection;
  43. class LLTransferSourceChannel;
  44. class LLTransferSourceParams;
  45. class LLTransferTargetChannel;
  46. class LLTransferTargetParams;
  47. class LLTransferSource;
  48. class LLTransferTarget;
  49. ///////////////////////////////////////////////////////////////////////////////
  50. // Priority queue map. This used to be in llcommon/llpriqueuemap.h, but was
  51. // only included from this header and is only used by LLTransferManager, so I
  52. // moved it here, where it belongs. HB
  53. ///////////////////////////////////////////////////////////////////////////////
  54. // Priority queue, implemented under the hood as a map. Needs to be done this
  55. // way because none of the standard STL containers provide a representation
  56. // where it is easy to reprioritize.
  57. template <class DATA>
  58. class LLPQMKey
  59. {
  60. public:
  61. LL_INLINE LLPQMKey(F32 priority, DATA data)
  62. : mPriority(priority),
  63. mData(data)
  64. {
  65. }
  66. LL_INLINE bool operator<(const LLPQMKey& b) const
  67. {
  68. if (mPriority > b.mPriority)
  69. {
  70. return true;
  71. }
  72. if (mPriority < b.mPriority)
  73. {
  74. return false;
  75. }
  76. if (mData > b.mData)
  77. {
  78. return true;
  79. }
  80. return false;
  81. }
  82. public:
  83. DATA mData;
  84. F32 mPriority;
  85. };
  86. template <class DATA_TYPE>
  87. class LLPriQueueMap
  88. {
  89. protected:
  90. LOG_CLASS(LLPriQueueMap);
  91. public:
  92. typedef typename std::map<LLPQMKey<DATA_TYPE>, DATA_TYPE>::iterator pqm_iter;
  93. typedef void (*set_pri_fn)(DATA_TYPE& data, F32 priority);
  94. typedef F32 (*get_pri_fn)(DATA_TYPE& data);
  95. LLPriQueueMap(set_pri_fn set_pri, get_pri_fn get_pri)
  96. : mSetPriority(set_pri),
  97. mGetPriority(get_pri)
  98. {
  99. }
  100. void push(F32 priority, DATA_TYPE data)
  101. {
  102. #if LL_DEBUG
  103. pqm_iter iter = mMap.find(LLPQMKey<DATA_TYPE>(priority, data));
  104. if (iter != mMap.end())
  105. {
  106. llerrs << "Pushing already existing data onto queue !" << llendl;
  107. }
  108. #endif
  109. mMap.emplace(LLPQMKey<DATA_TYPE>(priority, data), data);
  110. }
  111. bool pop(DATA_TYPE* datap)
  112. {
  113. pqm_iter iter;
  114. iter = mMap.begin();
  115. if (iter == mMap.end())
  116. {
  117. return false;
  118. }
  119. *datap = iter->second;
  120. mMap.erase(iter);
  121. return true;
  122. }
  123. void reprioritize(F32 new_priority, DATA_TYPE data)
  124. {
  125. pqm_iter iter;
  126. F32 cur_priority = mGetPriority(data);
  127. LLPQMKey<DATA_TYPE> cur_key(cur_priority, data);
  128. iter = mMap.find(cur_key);
  129. if (iter == mMap.end())
  130. {
  131. llwarns << "Data not on priority queue !" << llendl;
  132. // OK, try iterating through all of the data and seeing if we just
  133. // screwed up the priority somehow.
  134. for (iter = mMap.begin(); iter != mMap.end(); ++iter)
  135. {
  136. if (iter->second == data)
  137. {
  138. llerrs << "Data on priority queue but priority not matched !"
  139. << llendl;
  140. }
  141. }
  142. return;
  143. }
  144. mMap.erase(iter);
  145. mSetPriority(data, new_priority);
  146. push(new_priority, data);
  147. }
  148. LL_INLINE S32 getLength() const { return (S32)mMap.size(); }
  149. public:
  150. // *HACK: public for use by the transfer manager, ugh.
  151. std::map<LLPQMKey<DATA_TYPE>, DATA_TYPE> mMap;
  152. protected:
  153. void (*mSetPriority)(DATA_TYPE &data, F32 priority);
  154. F32 (*mGetPriority)(DATA_TYPE &data);
  155. };
  156. ///////////////////////////////////////////////////////////////////////////////
  157. // LLTransferManager
  158. ///////////////////////////////////////////////////////////////////////////////
  159. //
  160. // Definition of the manager class for the new LLXfer replacement.
  161. // Provides prioritized, bandwidth-throttled transport of arbitrary
  162. // binary data between host/circuit combos
  163. //
  164. typedef enum e_transfer_channel_type
  165. {
  166. LLTCT_UNKNOWN = 0,
  167. LLTCT_MISC,
  168. LLTCT_ASSET,
  169. LLTCT_NUM_TYPES
  170. } LLTransferChannelType;
  171. typedef enum e_transfer_source_type
  172. {
  173. LLTST_UNKNOWN = 0,
  174. LLTST_FILE,
  175. LLTST_ASSET,
  176. LLTST_SIM_INV_ITEM, // Simulator specific, may not be handled
  177. LLTST_SIM_ESTATE, // Simulator specific, may not be handled
  178. LLTST_NUM_TYPES
  179. } LLTransferSourceType;
  180. typedef enum e_transfer_target_type
  181. {
  182. LLTTT_UNKNOWN = 0,
  183. LLTTT_FILE,
  184. LLTTT_VFILE,
  185. LLTTT_NUM_TYPES
  186. } LLTransferTargetType;
  187. // Errors are negative, expected values are positive.
  188. typedef enum e_status_codes
  189. {
  190. LLTS_OK = 0,
  191. LLTS_DONE = 1,
  192. LLTS_SKIP = 2,
  193. LLTS_ABORT = 3,
  194. LLTS_ERROR = -1,
  195. LLTS_UNKNOWN_SOURCE = -2, // Equivalent of a 404
  196. LLTS_INSUFFICIENT_PERMISSIONS = -3 // Not enough permissions
  197. } LLTSCode;
  198. // Types of requests for estate wide information
  199. typedef enum e_estate_type
  200. {
  201. ET_Covenant = 0,
  202. ET_NONE = -1
  203. } EstateAssetType;
  204. class LLTransferManager
  205. {
  206. protected:
  207. LOG_CLASS(LLTransferManager);
  208. public:
  209. LLTransferManager();
  210. virtual ~LLTransferManager();
  211. void init();
  212. void cleanup();
  213. // Called per frame to push packets out on the various different channels.
  214. void updateTransfers();
  215. void cleanupConnection(const LLHost& host);
  216. LLTransferSourceChannel* getSourceChannel(const LLHost& host,
  217. LLTransferChannelType stype);
  218. LLTransferTargetChannel* getTargetChannel(const LLHost& host,
  219. LLTransferChannelType stype);
  220. LLTransferSource* findTransferSource(const LLUUID& transfer_id);
  221. LL_INLINE bool isValid() const { return mValid; }
  222. static void processTransferRequest(LLMessageSystem* mesgsys, void**);
  223. static void processTransferInfo(LLMessageSystem* mesgsys, void**);
  224. static void processTransferPacket(LLMessageSystem* mesgsys, void**);
  225. static void processTransferAbort(LLMessageSystem* mesgsys, void**);
  226. static void reliablePacketCallback(void**, S32 result);
  227. LL_INLINE S32 getTransferBitsIn(LLTransferChannelType tctype) const
  228. {
  229. return mTransferBitsIn[tctype];
  230. }
  231. LL_INLINE S32 getTransferBitsOut(LLTransferChannelType tctype) const
  232. {
  233. return mTransferBitsOut[tctype];
  234. }
  235. LL_INLINE void resetTransferBitsIn(LLTransferChannelType tctype)
  236. {
  237. mTransferBitsIn[tctype] = 0;
  238. }
  239. LL_INLINE void resetTransferBitsOut(LLTransferChannelType tctype)
  240. {
  241. mTransferBitsOut[tctype] = 0;
  242. }
  243. LL_INLINE void addTransferBitsIn(LLTransferChannelType tctype, S32 bits)
  244. {
  245. mTransferBitsIn[tctype] += bits;
  246. }
  247. LL_INLINE void addTransferBitsOut(LLTransferChannelType tctype, S32 bits)
  248. {
  249. mTransferBitsOut[tctype] += bits;
  250. }
  251. protected:
  252. LLTransferConnection* getTransferConnection(const LLHost& host);
  253. protected:
  254. // Convenient typedefs
  255. typedef std::map<LLHost, LLTransferConnection*> host_tc_map;
  256. // We keep a map between each host and LLTransferConnection.
  257. host_tc_map mTransferConnections;
  258. LLHost mHost;
  259. S32 mTransferBitsIn[LLTTT_NUM_TYPES];
  260. S32 mTransferBitsOut[LLTTT_NUM_TYPES];
  261. bool mValid;
  262. };
  263. //
  264. // Keeps tracks of all channels to/from a particular host.
  265. //
  266. class LLTransferConnection
  267. {
  268. friend class LLTransferManager;
  269. protected:
  270. LOG_CLASS(LLTransferConnection);
  271. public:
  272. LLTransferConnection(const LLHost& host);
  273. virtual ~LLTransferConnection();
  274. void updateTransfers();
  275. LLTransferSourceChannel* getSourceChannel(LLTransferChannelType type);
  276. LLTransferTargetChannel* getTargetChannel(LLTransferChannelType type);
  277. // Convenient typedefs
  278. typedef std::list<LLTransferSourceChannel*>::iterator tsc_iter;
  279. typedef std::list<LLTransferTargetChannel*>::iterator ttc_iter;
  280. protected:
  281. std::list<LLTransferSourceChannel*> mTransferSourceChannels;
  282. std::list<LLTransferTargetChannel*> mTransferTargetChannels;
  283. LLHost mHost;
  284. };
  285. //
  286. // A channel which is pushing data out.
  287. //
  288. class LLTransferSourceChannel
  289. {
  290. protected:
  291. LOG_CLASS(LLTransferSourceChannel);
  292. typedef std::list<LLTransferSource*>::iterator ts_iter;
  293. public:
  294. LLTransferSourceChannel(LLTransferChannelType type, const LLHost& host);
  295. virtual ~LLTransferSourceChannel();
  296. void updateTransfers();
  297. void updatePriority(LLTransferSource* tsp, F32 priority);
  298. void addTransferSource(LLTransferSource* sourcep);
  299. LLTransferSource* findTransferSource(const LLUUID& transfer_id);
  300. void deleteTransfer(LLTransferSource* tsp);
  301. LL_INLINE void setThrottleID(S32 throttle_id) { mThrottleID = throttle_id; }
  302. LL_INLINE LLTransferChannelType getChannelType() const { return mChannelType; }
  303. LL_INLINE LLHost getHost() const { return mHost; }
  304. protected:
  305. LLPriQueueMap<LLTransferSource*> mTransferSources;
  306. LLHost mHost;
  307. LLTransferChannelType mChannelType;
  308. // The throttle that this source channel should use
  309. S32 mThrottleID;
  310. };
  311. //
  312. // A channel receiving data from a source.
  313. //
  314. class LLTransferTargetChannel
  315. {
  316. friend class LLTransferTarget;
  317. friend class LLTransferManager;
  318. protected:
  319. LOG_CLASS(LLTransferTargetChannel);
  320. public:
  321. LLTransferTargetChannel(LLTransferChannelType type, const LLHost& host);
  322. virtual ~LLTransferTargetChannel();
  323. void requestTransfer(const LLTransferSourceParams& source_params,
  324. const LLTransferTargetParams& target_params,
  325. F32 priority);
  326. LLTransferTarget* findTransferTarget(const LLUUID& transfer_id);
  327. void deleteTransfer(LLTransferTarget* ttp);
  328. LL_INLINE LLTransferChannelType getChannelType() const { return mChannelType; }
  329. LL_INLINE LLHost getHost() const { return mHost; }
  330. protected:
  331. void sendTransferRequest(LLTransferTarget* targetp,
  332. const LLTransferSourceParams& params,
  333. F32 priority);
  334. void addTransferTarget(LLTransferTarget* targetp);
  335. protected:
  336. typedef std::list<LLTransferTarget*>::iterator tt_iter;
  337. std::list<LLTransferTarget*> mTransferTargets;
  338. LLHost mHost;
  339. LLTransferChannelType mChannelType;
  340. };
  341. class LLTransferSourceParams
  342. {
  343. protected:
  344. LOG_CLASS(LLTransferSourceParams);
  345. public:
  346. LLTransferSourceParams(LLTransferSourceType type)
  347. : mType(type)
  348. {
  349. }
  350. virtual ~LLTransferSourceParams() = default;
  351. virtual void packParams(LLDataPacker& dp) const = 0;
  352. virtual bool unpackParams(LLDataPacker& dp) = 0;
  353. LL_INLINE LLTransferSourceType getType() const { return mType; }
  354. protected:
  355. LLTransferSourceType mType;
  356. };
  357. //
  358. // LLTransferSource is an interface, all transfer sources should be derived
  359. // from it.
  360. //
  361. typedef LLTransferSource* (*LLTransferSourceCreateFunc)(const LLUUID& id,
  362. F32 priority);
  363. class LLTransferSource
  364. {
  365. protected:
  366. LOG_CLASS(LLTransferSource);
  367. public:
  368. LL_INLINE LLUUID getID() { return mID; }
  369. friend class LLTransferManager;
  370. friend class LLTransferSourceChannel;
  371. protected:
  372. LLTransferSource(LLTransferSourceType source_type,
  373. const LLUUID& request_id, F32 priority);
  374. virtual ~LLTransferSource() = default;
  375. // When you have figured out your transfer status, do this
  376. void sendTransferStatus(LLTSCode status);
  377. virtual void initTransfer() = 0;
  378. virtual F32 updatePriority() = 0;
  379. virtual LLTSCode dataCallback(S32 packet_id, S32 max_bytes,
  380. U8** datap, S32& returned_bytes,
  381. bool& delete_returned) = 0;
  382. // The completionCallback is GUARANTEED to be called before the destructor.
  383. virtual void completionCallback(LLTSCode status) = 0;
  384. virtual void packParams(LLDataPacker& dp) const = 0;
  385. virtual bool unpackParams(LLDataPacker& dp) = 0;
  386. LL_INLINE virtual S32 getNextPacketID() { return mLastPacketID + 1; }
  387. LL_INLINE virtual void setLastPacketID(S32 id) { mLastPacketID = id; }
  388. // For now, no self-induced priority changes
  389. LL_INLINE F32 getPriority() { return mPriority; }
  390. LL_INLINE void setPriority(F32 pri) { mPriority = pri; }
  391. // DON'T USE THIS ONE, used internally by LLTransferManager
  392. virtual void abortTransfer();
  393. static LLTransferSource* createSource(LLTransferSourceType stype,
  394. const LLUUID& request_id,
  395. F32 priority);
  396. static void registerSourceType(LLTransferSourceType stype,
  397. LLTransferSourceCreateFunc);
  398. static void sSetPriority(LLTransferSource*& tsp, F32 priority);
  399. static F32 sGetPriority(LLTransferSource*& tsp);
  400. protected:
  401. LLUUID mID;
  402. LLTransferSourceChannel* mChannelp;
  403. LLTransferSourceType mType;
  404. F32 mPriority;
  405. S32 mSize;
  406. S32 mLastPacketID;
  407. typedef std::map<LLTransferSourceType,
  408. LLTransferSourceCreateFunc> stype_scfunc_map;
  409. static stype_scfunc_map sSourceCreateMap;
  410. };
  411. class LLTransferTargetParams
  412. {
  413. protected:
  414. LOG_CLASS(LLTransferTargetParams);
  415. public:
  416. LLTransferTargetParams(LLTransferTargetType type)
  417. : mType(type)
  418. {
  419. }
  420. LL_INLINE LLTransferTargetType getType() const { return mType; }
  421. protected:
  422. LLTransferTargetType mType;
  423. };
  424. class LLTransferPacket
  425. {
  426. // Used for storing a packet that's being delivered later because it's out
  427. // of order. ONLY should be accessed by the following two classes, for now.
  428. friend class LLTransferTarget;
  429. friend class LLTransferManager;
  430. protected:
  431. LLTransferPacket(S32 packet_id, LLTSCode status, const U8* data, S32 size);
  432. virtual ~LLTransferPacket();
  433. protected:
  434. U8* mDatap;
  435. S32 mSize;
  436. S32 mPacketID;
  437. LLTSCode mStatus;
  438. };
  439. class LLTransferTarget
  440. {
  441. friend class LLTransferManager;
  442. friend class LLTransferTargetChannel;
  443. protected:
  444. LOG_CLASS(LLTransferTarget);
  445. public:
  446. LLTransferTarget(LLTransferTargetType target_type,
  447. const LLUUID& transfer_id,
  448. LLTransferSourceType source_type);
  449. virtual ~LLTransferTarget();
  450. // Accessors
  451. LL_INLINE LLUUID getID() const { return mID; }
  452. LL_INLINE LLTransferTargetType getType() const { return mType; }
  453. LL_INLINE LLTransferTargetChannel* getChannel() const { return mChannelp; }
  454. LL_INLINE LLTransferSourceType getSourceType() const { return mSourceType; }
  455. // Static functionality
  456. static LLTransferTarget* createTarget(LLTransferTargetType target_type,
  457. const LLUUID& request_id,
  458. LLTransferSourceType source_type);
  459. protected:
  460. // Implementation
  461. virtual bool unpackParams(LLDataPacker& dp) = 0;
  462. virtual void applyParams(const LLTransferTargetParams& params) = 0;
  463. virtual LLTSCode dataCallback(S32 packet_id, U8* in_datap,
  464. S32 in_size) = 0;
  465. // The completionCallback is GUARANTEED to be called before the destructor,
  466. // so all handling of errors/aborts should be done here.
  467. virtual void completionCallback(LLTSCode status) = 0;
  468. void abortTransfer();
  469. LL_INLINE virtual S32 getNextPacketID() { return mLastPacketID + 1; }
  470. LL_INLINE virtual void setLastPacketID(S32 id) { mLastPacketID =id; }
  471. LL_INLINE void setSize(S32 size) { mSize = size; }
  472. LL_INLINE void setGotInfo(bool got_info) { mGotInfo = got_info; }
  473. LL_INLINE bool gotInfo() const { return mGotInfo; }
  474. bool addDelayedPacket(S32 packet_id, LLTSCode status, U8* datap, S32 size);
  475. protected:
  476. typedef std::map<S32, LLTransferPacket*> transfer_packet_map;
  477. typedef std::map<S32, LLTransferPacket*>::iterator tpm_iter;
  478. LLTransferTargetType mType;
  479. LLTransferSourceType mSourceType;
  480. LLUUID mID;
  481. LLTransferTargetChannel* mChannelp;
  482. S32 mSize;
  483. S32 mLastPacketID;
  484. bool mGotInfo;
  485. // Packets that are waiting because of missing/out of order issues
  486. transfer_packet_map mDelayedPacketMap;
  487. };
  488. // Hack, here so it's publicly available even though LLTransferSourceInvItem is
  489. // only available on the simulator
  490. class LLTransferSourceParamsInvItem: public LLTransferSourceParams
  491. {
  492. protected:
  493. LOG_CLASS(LLTransferSourceParamsInvItem);
  494. public:
  495. LLTransferSourceParamsInvItem();
  496. void packParams(LLDataPacker& dp) const override;
  497. bool unpackParams(LLDataPacker& dp) override;
  498. void setAgentSession(const LLUUID& agent_id, const LLUUID& session_id);
  499. void setInvItem(const LLUUID& owner_id, const LLUUID& task_id,
  500. const LLUUID& item_id);
  501. void setAsset(const LLUUID& asset_id, LLAssetType::EType at);
  502. LL_INLINE LLUUID getAgentID() const { return mAgentID; }
  503. LL_INLINE LLUUID getSessionID() const { return mSessionID; }
  504. LL_INLINE LLUUID getOwnerID() const { return mOwnerID; }
  505. LL_INLINE LLUUID getTaskID() const { return mTaskID; }
  506. LL_INLINE LLUUID getItemID() const { return mItemID; }
  507. LL_INLINE LLUUID getAssetID() const { return mAssetID; }
  508. LL_INLINE LLAssetType::EType getAssetType() const { return mAssetType; }
  509. protected:
  510. LLUUID mAgentID;
  511. LLUUID mSessionID;
  512. LLUUID mOwnerID;
  513. LLUUID mTaskID;
  514. LLUUID mItemID;
  515. LLUUID mAssetID;
  516. LLAssetType::EType mAssetType;
  517. };
  518. // Hack, here so it is publicly available even though LLTransferSourceEstate is
  519. // only available on the simulator
  520. class LLTransferSourceParamsEstate: public LLTransferSourceParams
  521. {
  522. protected:
  523. LOG_CLASS(LLTransferSourceParamsEstate);
  524. public:
  525. LLTransferSourceParamsEstate();
  526. void packParams(LLDataPacker& dp) const override;
  527. bool unpackParams(LLDataPacker& dp) override;
  528. void setAgentSession(const LLUUID& agent_id, const LLUUID& session_id);
  529. void setEstateAssetType(EstateAssetType etype);
  530. void setAsset(const LLUUID& asset_id, LLAssetType::EType at);
  531. LL_INLINE LLUUID getAgentID() const { return mAgentID; }
  532. LL_INLINE LLUUID getSessionID() const { return mSessionID; }
  533. LL_INLINE EstateAssetType getEstateAssetType() const { return mEstateAssetType; }
  534. LL_INLINE LLUUID getAssetID() const { return mAssetID; }
  535. LL_INLINE LLAssetType::EType getAssetType() const { return mAssetType; }
  536. protected:
  537. LLUUID mAgentID;
  538. LLUUID mSessionID;
  539. // these are set on the sim based on estateinfotype
  540. LLUUID mAssetID;
  541. LLAssetType::EType mAssetType;
  542. EstateAssetType mEstateAssetType;
  543. };
  544. extern LLTransferManager gTransferManager;
  545. #endif//LL_LLTRANSFERMANAGER_H