Merge pull request #3030 from jowadmax/master
[vuplus_xbmc] / xbmc / FileItem.h
1 /*!
2  \file FileItem.h
3  \brief
4  */
5 #pragma once
6
7 /*
8  *      Copyright (C) 2005-2013 Team XBMC
9  *      http://xbmc.org
10  *
11  *  This Program is free software; you can redistribute it and/or modify
12  *  it under the terms of the GNU General Public License as published by
13  *  the Free Software Foundation; either version 2, or (at your option)
14  *  any later version.
15  *
16  *  This Program is distributed in the hope that it will be useful,
17  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
18  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19  *  GNU General Public License for more details.
20  *
21  *  You should have received a copy of the GNU General Public License
22  *  along with XBMC; see the file COPYING.  If not, see
23  *  <http://www.gnu.org/licenses/>.
24  *
25  */
26
27 #include "guilib/GUIListItem.h"
28 #include "utils/Archive.h"
29 #include "utils/ISerializable.h"
30 #include "utils/ISortable.h"
31 #include "XBDateTime.h"
32 #include "utils/SortUtils.h"
33 #include "utils/LabelFormatter.h"
34 #include "GUIPassword.h"
35 #include "threads/CriticalSection.h"
36
37 #include <vector>
38 #include "boost/shared_ptr.hpp"
39
40 namespace MUSIC_INFO
41 {
42   class CMusicInfoTag;
43 }
44 class CVideoInfoTag;
45 namespace EPG
46 {
47   class CEpgInfoTag;
48 }
49 namespace PVR
50 {
51   class CPVRChannel;
52   class CPVRRecording;
53   class CPVRTimerInfoTag;
54 }
55 class CPictureInfoTag;
56
57 class CAlbum;
58 class CArtist;
59 class CSong;
60 class CGenre;
61
62 class CURL;
63
64 /* special startoffset used to indicate that we wish to resume */
65 #define STARTOFFSET_RESUME (-1)
66
67 class CMediaSource;
68
69 enum EFileFolderType {
70   EFILEFOLDER_TYPE_ALWAYS     = 1<<0,
71   EFILEFOLDER_TYPE_ONCLICK    = 1<<1,
72   EFILEFOLDER_TYPE_ONBROWSE   = 1<<2,
73
74   EFILEFOLDER_MASK_ALL        = 0xff,
75   EFILEFOLDER_MASK_ONCLICK    = EFILEFOLDER_TYPE_ALWAYS
76                               | EFILEFOLDER_TYPE_ONCLICK,
77   EFILEFOLDER_MASK_ONBROWSE   = EFILEFOLDER_TYPE_ALWAYS
78                               | EFILEFOLDER_TYPE_ONCLICK
79                               | EFILEFOLDER_TYPE_ONBROWSE,
80 };
81
82 /*!
83   \brief Represents a file on a share
84   \sa CFileItemList
85   */
86 class CFileItem :
87   public CGUIListItem, public IArchivable, public ISerializable, public ISortable
88 {
89 public:
90   CFileItem(void);
91   CFileItem(const CFileItem& item);
92   CFileItem(const CGUIListItem& item);
93   CFileItem(const CStdString& strLabel);
94   CFileItem(const CStdString& strPath, bool bIsFolder);
95   CFileItem(const CSong& song);
96   CFileItem(const CStdString &path, const CAlbum& album);
97   CFileItem(const CArtist& artist);
98   CFileItem(const CGenre& genre);
99   CFileItem(const MUSIC_INFO::CMusicInfoTag& music);
100   CFileItem(const CVideoInfoTag& movie);
101   CFileItem(const EPG::CEpgInfoTag& tag);
102   CFileItem(const PVR::CPVRChannel& channel);
103   CFileItem(const PVR::CPVRRecording& record);
104   CFileItem(const PVR::CPVRTimerInfoTag& timer);
105   CFileItem(const CMediaSource& share);
106   virtual ~CFileItem(void);
107   virtual CGUIListItem *Clone() const { return new CFileItem(*this); };
108
109   const CStdString &GetPath() const { return m_strPath; };
110   void SetPath(const CStdString &path) { m_strPath = path; };
111
112   void Reset();
113   const CFileItem& operator=(const CFileItem& item);
114   virtual void Archive(CArchive& ar);
115   virtual void Serialize(CVariant& value) const;
116   virtual void ToSortable(SortItem &sortable);
117   virtual bool IsFileItem() const { return true; };
118
119   bool Exists(bool bUseCache = true) const;
120   
121   /*!
122    \brief Check whether an item is a video item. Note that this returns true for
123     anything with a video info tag, so that may include eg. folders.
124    \return true if item is video, false otherwise. 
125    */
126   bool IsVideo() const;
127
128   bool IsDiscStub() const;
129
130   /*!
131    \brief Check whether an item is a picture item. Note that this returns true for
132     anything with a picture info tag, so that may include eg. folders.
133    \return true if item is picture, false otherwise. 
134    */
135   bool IsPicture() const;
136   bool IsLyrics() const;
137
138   /*!
139    \brief Check whether an item is an audio item. Note that this returns true for
140     anything with a music info tag, so that may include eg. folders.
141    \return true if item is audio, false otherwise. 
142    */
143   bool IsAudio() const;
144
145   bool IsKaraoke() const;
146   bool IsCUESheet() const;
147   bool IsInternetStream(const bool bStrictCheck = false) const;
148   bool IsPlayList() const;
149   bool IsSmartPlayList() const;
150   bool IsPythonScript() const;
151   bool IsPlugin() const;
152   bool IsScript() const;
153   bool IsAddonsPath() const;
154   bool IsSourcesPath() const;
155   bool IsNFO() const;
156   bool IsDVDImage() const;
157   bool IsOpticalMediaFile() const;
158   bool IsDVDFile(bool bVobs = true, bool bIfos = true) const;
159   bool IsBDFile() const;
160   bool IsRAR() const;
161   bool IsAPK() const;
162   bool IsZIP() const;
163   bool IsCBZ() const;
164   bool IsCBR() const;
165   bool IsISO9660() const;
166   bool IsCDDA() const;
167   bool IsDVD() const;
168   bool IsOnDVD() const;
169   bool IsOnLAN() const;
170   bool IsHD() const;
171   bool IsNfs() const;  
172   bool IsAfp() const;    
173   bool IsRemote() const;
174   bool IsSmb() const;
175   bool IsURL() const;
176   bool IsDAAP() const;
177   bool IsStack() const;
178   bool IsMultiPath() const;
179   bool IsMusicDb() const;
180   bool IsVideoDb() const;
181   bool IsEPG() const;
182   bool IsPVRChannel() const;
183   bool IsPVRRecording() const;
184   bool IsPVRTimer() const;
185   bool IsType(const char *ext) const;
186   bool IsVirtualDirectoryRoot() const;
187   bool IsReadOnly() const;
188   bool CanQueue() const;
189   void SetCanQueue(bool bYesNo);
190   bool IsParentFolder() const;
191   bool IsFileFolder(EFileFolderType types = EFILEFOLDER_MASK_ALL) const;
192   bool IsRemovable() const;
193   bool IsTuxBox() const;
194   bool IsMythTV() const;
195   bool IsHDHomeRun() const;
196   bool IsSlingbox() const;
197   bool IsVTP() const;
198   bool IsPVR() const;
199   bool IsLiveTV() const;
200   bool IsRSS() const;
201   bool IsAndroidApp() const;
202
203   void RemoveExtension();
204   void CleanString();
205   void FillInDefaultIcon();
206   void SetFileSizeLabel();
207   virtual void SetLabel(const CStdString &strLabel);
208   CURL GetAsUrl() const;
209   int GetVideoContentType() const; /* return VIDEODB_CONTENT_TYPE, but don't want to include videodb in this header */
210   bool IsLabelPreformated() const { return m_bLabelPreformated; }
211   void SetLabelPreformated(bool bYesNo) { m_bLabelPreformated=bYesNo; }
212   bool SortsOnTop() const { return m_specialSort == SortSpecialOnTop; }
213   bool SortsOnBottom() const { return m_specialSort == SortSpecialOnBottom; }
214   void SetSpecialSort(SortSpecial sort) { m_specialSort = sort; }
215
216   inline bool HasMusicInfoTag() const
217   {
218     return m_musicInfoTag != NULL;
219   }
220
221   MUSIC_INFO::CMusicInfoTag* GetMusicInfoTag();
222
223   inline const MUSIC_INFO::CMusicInfoTag* GetMusicInfoTag() const
224   {
225     return m_musicInfoTag;
226   }
227
228   inline bool HasVideoInfoTag() const
229   {
230     return m_videoInfoTag != NULL;
231   }
232
233   CVideoInfoTag* GetVideoInfoTag();
234
235   inline const CVideoInfoTag* GetVideoInfoTag() const
236   {
237     return m_videoInfoTag;
238   }
239
240   inline bool HasEPGInfoTag() const
241   {
242     return m_epgInfoTag != NULL;
243   }
244
245   EPG::CEpgInfoTag* GetEPGInfoTag();
246
247   inline const EPG::CEpgInfoTag* GetEPGInfoTag() const
248   {
249     return m_epgInfoTag;
250   }
251
252   inline bool HasPVRChannelInfoTag() const
253   {
254     return m_pvrChannelInfoTag != NULL;
255   }
256
257   PVR::CPVRChannel* GetPVRChannelInfoTag();
258
259   inline const PVR::CPVRChannel* GetPVRChannelInfoTag() const
260   {
261     return m_pvrChannelInfoTag;
262   }
263
264   inline bool HasPVRRecordingInfoTag() const
265   {
266     return m_pvrRecordingInfoTag != NULL;
267   }
268
269   PVR::CPVRRecording* GetPVRRecordingInfoTag();
270
271   inline const PVR::CPVRRecording* GetPVRRecordingInfoTag() const
272   {
273     return m_pvrRecordingInfoTag;
274   }
275
276   inline bool HasPVRTimerInfoTag() const
277   {
278     return m_pvrTimerInfoTag != NULL;
279   }
280
281   PVR::CPVRTimerInfoTag* GetPVRTimerInfoTag();
282
283   inline const PVR::CPVRTimerInfoTag* GetPVRTimerInfoTag() const
284   {
285     return m_pvrTimerInfoTag;
286   }
287
288   inline bool HasPictureInfoTag() const
289   {
290     return m_pictureInfoTag != NULL;
291   }
292
293   inline const CPictureInfoTag* GetPictureInfoTag() const
294   {
295     return m_pictureInfoTag;
296   }
297
298   CPictureInfoTag* GetPictureInfoTag();
299
300   /*!
301    \brief Get the local fanart for this item if it exists
302    \return path to the local fanart for this item, or empty if none exists
303    \sa GetFolderThumb, GetTBNFile
304    */
305   CStdString GetLocalFanart() const;
306
307   /*! \brief Assemble the filename of a particular piece of local artwork for an item.
308              No file existence check is typically performed.
309    \param artFile the art file to search for.
310    \param useFolder whether to look in the folder for the art file. Defaults to false.
311    \return the path to the local artwork.
312    \sa FindLocalArt
313    */
314   CStdString GetLocalArt(const std::string &artFile, bool useFolder = false) const;
315
316   /*! \brief Assemble the filename of a particular piece of local artwork for an item,
317              and check for file existence.
318    \param artFile the art file to search for.
319    \param useFolder whether to look in the folder for the art file. Defaults to false.
320    \return the path to the local artwork if it exists, empty otherwise.
321    \sa GetLocalArt
322    */
323   CStdString FindLocalArt(const std::string &artFile, bool useFolder) const;
324
325   // Gets the .tbn file associated with this item
326   CStdString GetTBNFile() const;
327   // Gets the folder image associated with this item (defaults to folder.jpg)
328   CStdString GetFolderThumb(const CStdString &folderJPG = "folder.jpg") const;
329   // Gets the correct movie title
330   CStdString GetMovieName(bool bUseFolderNames = false) const;
331
332   /*! \brief Find the base movie path (i.e. the item the user expects us to use to lookup the movie)
333    For folder items, with "use foldernames for lookups" it returns the folder.
334    Regardless of settings, for VIDEO_TS/BDMV it returns the parent of the VIDEO_TS/BDMV folder (if present)
335
336    \param useFolderNames whether we're using foldernames for lookups
337    \return the base movie folder
338    */
339   CStdString GetBaseMoviePath(bool useFolderNames) const;
340
341   // Gets the user thumb, if it exists
342   CStdString GetUserMusicThumb(bool alwaysCheckRemote = false, bool fallbackToFolder = false) const;
343
344   /*! \brief Get the path where we expect local metadata to reside.
345    For a folder, this is just the existing path (eg tvshow folder)
346    For a file, this is the parent path, with exceptions made for VIDEO_TS and BDMV files
347
348    Three cases are handled:
349
350      /foo/bar/movie_name/file_name          -> /foo/bar/movie_name/
351      /foo/bar/movie_name/VIDEO_TS/file_name -> /foo/bar/movie_name/
352      /foo/bar/movie_name/BDMV/file_name     -> /foo/bar/movie_name/
353
354      \sa URIUtils::GetParentPath
355    */
356   CStdString GetLocalMetadataPath() const;
357
358   // finds a matching local trailer file
359   CStdString FindTrailer() const;
360
361   virtual bool LoadMusicTag();
362
363   /* Returns the content type of this item if known */
364   const CStdString& GetMimeType() const { return m_mimetype; }
365
366   /* sets the mime-type if known beforehand */
367   void SetMimeType(const CStdString& mimetype) { m_mimetype = mimetype; } ;
368
369   /*! \brief Resolve the MIME type based on file extension or a web lookup
370    If m_mimetype is already set (non-empty), this function has no effect. For
371    http:// and shout:// streams, this will query the stream (blocking operation).
372    Set lookup=false to skip any internet lookups and always return immediately.
373    */
374   void FillInMimeType(bool lookup = true);
375
376   /* general extra info about the contents of the item, not for display */
377   void SetExtraInfo(const CStdString& info) { m_extrainfo = info; };
378   const CStdString& GetExtraInfo() const { return m_extrainfo; };
379
380   /*! \brief Update an item with information from another item
381    We take metadata information from the given item and supplement the current item
382    with that info.  If tags exist in the new item we use the entire tag information.
383    Properties are appended, and labels, thumbnail and icon are updated if non-empty
384    in the given item.
385    \param item the item used to supplement information
386    \param replaceLabels whether to replace labels (defaults to true)
387    */
388   void UpdateInfo(const CFileItem &item, bool replaceLabels = true);
389
390   bool IsSamePath(const CFileItem *item) const;
391
392   bool IsAlbum() const;
393
394   /*! \brief Sets details using the information from the CVideoInfoTag object
395    Sets the videoinfotag and uses its information to set the label and path.
396    \param video video details to use and set
397    */
398   void SetFromVideoInfoTag(const CVideoInfoTag &video);
399   /*! \brief Sets details using the information from the CAlbum object
400    Sets the album in the music info tag and uses its information to set the
401    label and album-specific properties.
402    \param album album details to use and set
403    */
404   void SetFromAlbum(const CAlbum &album);
405   /*! \brief Sets details using the information from the CSong object
406    Sets the song in the music info tag and uses its information to set the
407    label, path, song-specific properties and artwork.
408    \param song song details to use and set
409    */
410   void SetFromSong(const CSong &song);
411
412   bool m_bIsShareOrDrive;    ///< is this a root share/drive
413   int m_iDriveType;     ///< If \e m_bIsShareOrDrive is \e true, use to get the share type. Types see: CMediaSource::m_iDriveType
414   CDateTime m_dateTime;             ///< file creation date & time
415   int64_t m_dwSize;             ///< file size (0 for folders)
416   CStdString m_strDVDLabel;
417   CStdString m_strTitle;
418   int m_iprogramCount;
419   int m_idepth;
420   int m_lStartOffset;
421   int m_lStartPartNumber;
422   int m_lEndOffset;
423   LockType m_iLockMode;
424   CStdString m_strLockCode;
425   int m_iHasLock; // 0 - no lock 1 - lock, but unlocked 2 - locked
426   int m_iBadPwdCount;
427
428 private:
429   CStdString m_strPath;            ///< complete path to item
430
431   SortSpecial m_specialSort;
432   bool m_bIsParentFolder;
433   bool m_bCanQueue;
434   bool m_bLabelPreformated;
435   CStdString m_mimetype;
436   CStdString m_extrainfo;
437   MUSIC_INFO::CMusicInfoTag* m_musicInfoTag;
438   CVideoInfoTag* m_videoInfoTag;
439   EPG::CEpgInfoTag* m_epgInfoTag;
440   PVR::CPVRChannel* m_pvrChannelInfoTag;
441   PVR::CPVRRecording* m_pvrRecordingInfoTag;
442   PVR::CPVRTimerInfoTag * m_pvrTimerInfoTag;
443   CPictureInfoTag* m_pictureInfoTag;
444   bool m_bIsAlbum;
445 };
446
447 /*!
448   \brief A shared pointer to CFileItem
449   \sa CFileItem
450   */
451 typedef boost::shared_ptr<CFileItem> CFileItemPtr;
452
453 /*!
454   \brief A vector of pointer to CFileItem
455   \sa CFileItem
456   */
457 typedef std::vector< CFileItemPtr > VECFILEITEMS;
458
459 /*!
460   \brief Iterator for VECFILEITEMS
461   \sa CFileItemList
462   */
463 typedef std::vector< CFileItemPtr >::iterator IVECFILEITEMS;
464
465 /*!
466   \brief A map of pointers to CFileItem
467   \sa CFileItem
468   */
469 typedef std::map<CStdString, CFileItemPtr > MAPFILEITEMS;
470
471 /*!
472   \brief Iterator for MAPFILEITEMS
473   \sa MAPFILEITEMS
474   */
475 typedef std::map<CStdString, CFileItemPtr >::iterator IMAPFILEITEMS;
476
477 /*!
478   \brief Pair for MAPFILEITEMS
479   \sa MAPFILEITEMS
480   */
481 typedef std::pair<CStdString, CFileItemPtr > MAPFILEITEMSPAIR;
482
483 typedef bool (*FILEITEMLISTCOMPARISONFUNC) (const CFileItemPtr &pItem1, const CFileItemPtr &pItem2);
484 typedef void (*FILEITEMFILLFUNC) (CFileItemPtr &item);
485
486 /*!
487   \brief Represents a list of files
488   \sa CFileItemList, CFileItem
489   */
490 class CFileItemList : public CFileItem
491 {
492 public:
493   enum CACHE_TYPE { CACHE_NEVER = 0, CACHE_IF_SLOW, CACHE_ALWAYS };
494
495   CFileItemList();
496   CFileItemList(const CStdString& strPath);
497   virtual ~CFileItemList();
498   virtual void Archive(CArchive& ar);
499   CFileItemPtr operator[] (int iItem);
500   const CFileItemPtr operator[] (int iItem) const;
501   CFileItemPtr operator[] (const CStdString& strPath);
502   const CFileItemPtr operator[] (const CStdString& strPath) const;
503   void Clear();
504   void ClearItems();
505   void Add(const CFileItemPtr &pItem);
506   void AddFront(const CFileItemPtr &pItem, int itemPosition);
507   void Remove(CFileItem* pItem);
508   void Remove(int iItem);
509   CFileItemPtr Get(int iItem);
510   const CFileItemPtr Get(int iItem) const;
511   const VECFILEITEMS GetList() const { return m_items; }
512   CFileItemPtr Get(const CStdString& strPath);
513   const CFileItemPtr Get(const CStdString& strPath) const;
514   int Size() const;
515   bool IsEmpty() const;
516   void Append(const CFileItemList& itemlist);
517   void Assign(const CFileItemList& itemlist, bool append = false);
518   bool Copy  (const CFileItemList& item, bool copyItems = true);
519   void Reserve(int iCount);
520   void Sort(SortBy sortBy, SortOrder sortOrder, SortAttribute sortAttributes = SortAttributeNone);
521   /* \brief Sorts the items based on the given sorting options
522
523   In contrast to Sort (see above) this does not change the internal
524   state by storing the sorting method and order used and therefore
525   will always execute the sorting even if the list of items has
526   already been sorted with the same options before.
527   */
528   void Sort(SortDescription sortDescription);
529   void Randomize();
530   void FillInDefaultIcons();
531   int GetFolderCount() const;
532   int GetFileCount() const;
533   int GetSelectedCount() const;
534   int GetObjectCount() const;
535   void FilterCueItems();
536   void RemoveExtensions();
537   void SetFastLookup(bool fastLookup);
538   bool Contains(const CStdString& fileName) const;
539   bool GetFastLookup() const { return m_fastLookup; };
540
541   /*! \brief stack a CFileItemList
542    By default we stack all items (files and folders) in a CFileItemList
543    \param stackFiles whether to stack all items or just collapse folders (defaults to true)
544    \sa StackFiles,StackFolders
545    */
546   void Stack(bool stackFiles = true);
547
548   SortOrder GetSortOrder() const { return m_sortDescription.sortOrder; }
549   SortBy GetSortMethod() const { return m_sortDescription.sortBy; }
550   /*! \brief load a CFileItemList out of the cache
551
552    The file list may be cached based on which window we're viewing in, as different
553    windows will be listing different portions of the same URL (eg viewing music files
554    versus viewing video files)
555    
556    \param windowID id of the window that's loading this list (defaults to 0)
557    \return true if we loaded from the cache, false otherwise.
558    \sa Save,RemoveDiscCache
559    */
560   bool Load(int windowID = 0);
561
562   /*! \brief save a CFileItemList to the cache
563    
564    The file list may be cached based on which window we're viewing in, as different
565    windows will be listing different portions of the same URL (eg viewing music files
566    versus viewing video files)
567    
568    \param windowID id of the window that's saving this list (defaults to 0)
569    \return true if successful, false otherwise.
570    \sa Load,RemoveDiscCache
571    */
572   bool Save(int windowID = 0);
573   void SetCacheToDisc(CACHE_TYPE cacheToDisc) { m_cacheToDisc = cacheToDisc; }
574   bool CacheToDiscAlways() const { return m_cacheToDisc == CACHE_ALWAYS; }
575   bool CacheToDiscIfSlow() const { return m_cacheToDisc == CACHE_IF_SLOW; }
576   /*! \brief remove a previously cached CFileItemList from the cache
577    
578    The file list may be cached based on which window we're viewing in, as different
579    windows will be listing different portions of the same URL (eg viewing music files
580    versus viewing video files)
581    
582    \param windowID id of the window whose cache we which to remove (defaults to 0)
583    \sa Save,Load
584    */
585   void RemoveDiscCache(int windowID = 0) const;
586   bool AlwaysCache() const;
587
588   void Swap(unsigned int item1, unsigned int item2);
589
590   /*! \brief Update an item in the item list
591    \param item the new item, which we match based on path to an existing item in the list
592    \return true if the item exists in the list (and was thus updated), false otherwise.
593    */
594   bool UpdateItem(const CFileItem *item);
595
596   void AddSortMethod(SortBy sortBy, int buttonLabel, const LABEL_MASKS &labelMasks, SortAttribute sortAttributes = SortAttributeNone);
597   void AddSortMethod(SortBy sortBy, SortAttribute sortAttributes, int buttonLabel, const LABEL_MASKS &labelMasks);
598   void AddSortMethod(SortDescription sortDescription, int buttonLabel, const LABEL_MASKS &labelMasks);
599   bool HasSortDetails() const { return m_sortDetails.size() != 0; };
600   const std::vector<SORT_METHOD_DETAILS> &GetSortDetails() const { return m_sortDetails; };
601
602   /*! \brief Specify whether this list should be sorted with folders separate from files
603    By default we sort with folders listed (and sorted separately) except for those sort modes
604    which should be explicitly sorted with folders interleaved with files (eg SORT_METHOD_FILES).
605    With this set the folder state will be ignored, allowing folders and files to sort interleaved.
606    \param sort whether to ignore the folder state.
607    */
608   void SetSortIgnoreFolders(bool sort) { m_sortIgnoreFolders = sort; };
609   bool GetReplaceListing() const { return m_replaceListing; };
610   void SetReplaceListing(bool replace);
611   void SetContent(const CStdString &content) { m_content = content; };
612   const CStdString &GetContent() const { return m_content; };
613
614   void ClearSortState();
615 private:
616   void Sort(FILEITEMLISTCOMPARISONFUNC func);
617   void FillSortFields(FILEITEMFILLFUNC func);
618   CStdString GetDiscFileCache(int windowID) const;
619
620   /*!
621    \brief stack files in a CFileItemList
622    \sa Stack
623    */
624   void StackFiles();
625
626   /*!
627    \brief stack folders in a CFileItemList
628    \sa Stack
629    */
630   void StackFolders();
631
632   VECFILEITEMS m_items;
633   MAPFILEITEMS m_map;
634   bool m_fastLookup;
635   SortDescription m_sortDescription;
636   bool m_sortIgnoreFolders;
637   CACHE_TYPE m_cacheToDisc;
638   bool m_replaceListing;
639   CStdString m_content;
640
641   std::vector<SORT_METHOD_DETAILS> m_sortDetails;
642
643   CCriticalSection m_lock;
644 };