Exemple #1
0
        /// <summary>
        /// Returnes Craft Data	Recipe Colleciton From input File Byte Array
        /// </summary>
        /// <param name="input">file byte array</param>
        /// <returns></returns>
        public static CraftDataRecipe[] RecipesFromFileBytes(byte[] input)
        {
            if (input == null)
            {
                throw new ArgumentNullException("input");
            }

            if (input.Length == 0)
            {
                throw new ArgumentException("Input Array is Empty", "input");
            }

            CraftDataRecipe[] results;

            using (var stream = new MemoryStream(input))
            {
                var craftList = new CraftListData(stream);
                results = craftList.Recipes;
            }

            return(results);
        }
        /// <summary>
        /// Returnes Craft Data	Recipe Colleciton From input File Byte Array
        /// </summary>
        /// <param name="input">file byte array</param>
        /// <returns></returns>
        public static CraftDataRecipe[] RecipesFromFileBytes(byte[] input)
        {
            if (input == null)
                throw new ArgumentNullException("input");

            if (input.Length == 0)
                throw new ArgumentException("Input Array is Empty", "input");

            CraftDataRecipe[] results;

            using (var stream = new MemoryStream(input))
            {
                var craftList = new CraftListData(stream);
                results = craftList.Recipes;
            }

            return results;
        }