void FetchWordsForItems(List<IndexerDictionaryItem> Dictionary)
 {
     IList<Item> items = dao.GetAllItems ();
     foreach (Item i in items) {
         IndexerDictionaryItem x = new IndexerDictionaryItem ();
         x.id = i.ID;
         x.type = "Item";
         x.value = i.Name;
         if (x.Name != null) {
             x.Name = i.Name;
         }
         Dictionary.Add (x);
         if (i.Description != null) {
             string[] descwords = i.Description.Split (sep);
             foreach (string descword in descwords) {
                 IndexerDictionaryItem y = new IndexerDictionaryItem ();
                 y.id = i.ID;
                 y.type = "Item";
                 y.value = descword;
                 if (i.Name != null) {
                     y.Name = i.Name;
                 }
                 Dictionary.Add (y);
             }
         }
         ImageTag tag = dao.GetImageTagById (i.ImageTagId);
         if (tag != null && tag.TagString != null) {
             string[] tags = tag.TagString.Split (sep);
             foreach (string word in tags) {
                 IndexerDictionaryItem z = new IndexerDictionaryItem ();
                 z.id = i.ID;
                 z.type = "Item";
                 z.value = word;
                 if (i.Name != null) {
                     z.Name = i.Name;
                 }
                 Dictionary.Add (z);
             }
         }
     }
 }
 void FetchWordsForLargeObjects(List<IndexerDictionaryItem> Dictionary)
 {
     IList<LagerObject> lagerobjects = dao.GetAllLargeItems ();
     foreach (LagerObject ox in lagerobjects) {
         IndexerDictionaryItem x = new IndexerDictionaryItem ();
         x.id = ox.ID;
         x.type = "LargeObject";
         x.value = ox.Name;
         if (x.Name != null) {
             x.Name = x.Name;
         }
         Dictionary.Add (x);
         if (ox.Description != null) {
             string[] descwords = ox.Description.Split (sep);
             foreach (string descword in descwords) {
                 IndexerDictionaryItem y = new IndexerDictionaryItem ();
                 y.id = ox.ID;
                 y.type = "LargeObject";
                 y.value = descword;
                 if (ox.Name != null) {
                     y.Name = ox.Name;
                 }
                 Dictionary.Add (y);
             }
         }
         ImageTag tag = dao.GetImageTagById (ox.ImageTagId);
         if (tag != null && tag.TagString != null) {
             string[] tags = tag.TagString.Split (sep);
             foreach (string word in tags) {
                 IndexerDictionaryItem z = new IndexerDictionaryItem ();
                 z.id = ox.ID;
                 z.type = "LargeObject";
                 z.value = word;
                 if (ox.Name != null) {
                     z.Name = z.Name;
                 }
                 Dictionary.Add (z);
             }
         }
     }
 }
 void FetchWordsForGalleryObjects(List<IndexerDictionaryItem> Dictionary)
 {
     IList<GalleryObject> gals = dao.GetAllGalleryObjects ();
     foreach (GalleryObject go in gals) {
         IList<ImageTag> tags = dao.GetTagsByGalleryObjectID (go.ID);
         foreach (ImageTag tag in tags) {
             string[] words = tag.TagString.Split (sep);
             foreach (string word in words) {
                 IndexerDictionaryItem x = new IndexerDictionaryItem ();
                 x.id = go.ID;
                 x.type = "GalleryObject";
                 x.value = word;
                 if (go.Name != null) {
                     x.Name = go.Name;
                 }
                 Dictionary.Add (x);
             }
         }
     }
 }