/// <summary>
        ///     Build an array of recipes using the current item as material.
        /// </summary>
        /// <returns>An array of recipes using the current item as material.</returns>
        private Recipe[] BuildRecipesAsMaterial()
        {
            IXivSheet <Recipe> rSheet = Sheet.Collection.GetSheet <Recipe>();

            return
                (rSheet.Where(
                     recipe =>
                     recipe.Ingredients.Any(ing => ing.Type == RecipeIngredientType.Material && ing.Item == this))
                 .ToArray());
        }
        /// <summary>
        ///     Build an array of sources from which to obtain the current item.
        /// </summary>
        /// <returns>An array of sources from which to obtain the current item.</returns>
        private IItemSource[] BuildSources()
        {
            List <IItemSource> sources = new List <IItemSource>();

            Libra.Item libraRow = null;
            if (Sheet.Collection.IsLibraAvailable)
            {
                libraRow = Sheet.Collection.Libra.Items.FirstOrDefault(i => i.Key == this.Key);
            }

            IXivSheet <Recipe>      recipes      = Sheet.Collection.GetSheet <Recipe>();
            IXivSheet <Quest>       quests       = Sheet.Collection.GetSheet <Quest>();
            IXivSheet <Achievement> achievements = Sheet.Collection.GetSheet <Achievement>();

            Collections.ShopCollection       shops         = Sheet.Collection.Shops;
            IXivSheet <Leve>                 leves         = Sheet.Collection.GetSheet <Leve>();
            IXivSheet <FishingSpot>          fishingSpots  = Sheet.Collection.GetSheet <FishingSpot>();
            IXivSheet <RetainerTask>         retainerTasks = Sheet.Collection.GetSheet <RetainerTask>();
            IXivSheet <CompanyCraftSequence> companyCraft  = Sheet.Collection.GetSheet <CompanyCraftSequence>();

            if (libraRow != null)
            {
                Collections.BNpcCollection  bnpcColl         = Sheet.Collection.BNpcs;
                IXivSheet <InstanceContent> instanceContents = Sheet.Collection.GetSheet <InstanceContent>();

                foreach (long bnpc in libraRow.BNpcs)
                {
                    sources.Add(bnpcColl[bnpc]);
                }
                foreach (int ic in libraRow.InstanceContents)
                {
                    sources.Add(instanceContents[ic]);
                }
            }

            /*sources.AddRange(bnpcColl.Where(i => i.Items.Contains(this)));
             * sources.AddRange(instanceContents.Cast<IItemSource>().Where(i => i.Items.Contains(this)));*/

            // Not using Libra for these because it has a higher likelyhood of being incomplete.
            sources.AddRange(recipes.Where(i => i.ResultItem == this));
            sources.AddRange(quests.Cast <IItemSource>().Where(i => i.Items.Contains(this)));
            sources.AddRange(achievements.Where(i => i.Item == this));
            sources.AddRange(shops.Where(i => i.Items.Contains(this)));

            // Not using Libra for this because it doesn't even have information about it
            sources.AddRange(leves.Where(i => i.Items.Contains(this)));
            sources.AddRange(fishingSpots.Where(i => i.Items.Contains(this)));
            sources.AddRange(retainerTasks.Where(i => i.Items.Contains(this)));
            sources.AddRange(companyCraft.Where(i => i.ResultItem == this));

            return(sources.ToArray());
        }
        /// <summary>
        ///     Build an array of recipes creating the current item.
        /// </summary>
        /// <returns>An array of recipes creating the current item.</returns>
        private Recipe[] BuildRecipesAsResult()
        {
            IXivSheet <Recipe> rSheet = Sheet.Collection.GetSheet <Recipe>();

            return(rSheet.Where(recipe => recipe.ResultItem == this).ToArray());
        }
        /// <summary>
        ///     Build an array of the <see cref="GilShop" />s offering the current item.
        /// </summary>
        /// <returns>An array of the <see cref="GilShop" />s offering the current item.</returns>
        private GilShop[] BuildShops()
        {
            IXivSheet <GilShop> sSheet = Sheet.Collection.GetSheet <GilShop>();

            return(sSheet.Where(shop => shop.Items.Contains(this)).ToArray());
        }