public object Convert(IDataRow row, object rawValue)
        {
            ExCollection coll = row.Sheet.Collection;

            if (!coll.SheetExists(TargetSheet))
            {
                return(null);
            }

            ISheet sheet = coll.GetSheet(TargetSheet);

            int key = System.Convert.ToInt32(rawValue);

            return(!sheet.ContainsRow(key) ? null : sheet[key]);
        }
        public object Convert(IDataRow row, object rawValue)
        {
            if (_tomestoneKeyByRewardIndex == null)
            {
                _tomestoneKeyByRewardIndex = BuildTomestoneRewardIndex(row.Sheet.Collection);
            }

            int key = System.Convert.ToInt32(rawValue);

            if (_tomestoneKeyByRewardIndex.TryGetValue(key, out Item item))
            {
                return(item);
            }

            ISheet items = row.Sheet.Collection.GetSheet("Item");

            return(items.ContainsRow(key) ? items[key] : rawValue);
        }
        public object Convert(IDataRow row, object rawValue)
        {
            if (Targets == null)
            {
                return(null);
            }

            int key = System.Convert.ToInt32(rawValue);

            foreach (string target in Targets)
            {
                ISheet sheet = row.Sheet.Collection.GetSheet(target);
                if (!sheet.Header.DataFileRanges.Any(r => r.Contains(key)))
                {
                    continue;
                }

                if (sheet.ContainsRow(key))
                {
                    return(sheet[key]);
                }
            }
            return(null);
        }