예제 #1
0
        public virtual KeyValuePair <int, int> GetMapping(int folderId, int fileId)
        {
            T asset = GetAsset(folderId, fileId);

            if (asset == null || !CharMapValues.ContainsKey(asset))
            {
                return(new KeyValuePair <int, int>(folderId, fileId));
            }
            return(CharMapValues[asset]);
        }
예제 #2
0
        public virtual T Get(int folderId, int fileId)
        {
            T asset = GetAsset(folderId, fileId);

            if (asset == null)
            {
                return(asset);
            }

            if (CharMapValues.ContainsKey(asset))
            {
                KeyValuePair <int, int> mapping = CharMapValues[asset];
                return(Get(mapping.Key, mapping.Value));
            }

            return(SwappedAssets.ContainsKey(asset) ? SwappedAssets[asset] : asset);
        }